List of usage examples for java.util SimpleTimeZone hasSameRules
public boolean hasSameRules(TimeZone other)
true
if this zone has the same rules and offset as another zone. From source file:Main.java
public static void main(String args[]) { // create two simple time zone object SimpleTimeZone stobj1 = new SimpleTimeZone(820, "US"); SimpleTimeZone stobj2 = new SimpleTimeZone(820, "GMT"); // check rules for both objects boolean samerule = stobj1.hasSameRules(stobj2); // checking the value System.out.println("Hash same rule : " + samerule); }