SimpleTimeZone.getDSTSavings() has the following syntax.
public int getDSTSavings()
In the following code shows how to use SimpleTimeZone.getDSTSavings() method.
// w w w . j a v a2 s . c o m import java.util.SimpleTimeZone; public class Main { public static void main( String args[] ){ SimpleTimeZone stobj = new SimpleTimeZone(720,"US"); // check DST saving int dstsaving=stobj.getDSTSavings(); System.out.println("DST saving : " + dstsaving); } }
The code above generates the following result.