TimeZone.getAvailableIDs() has the following syntax.
public static String [] getAvailableIDs()
In the following code shows how to use TimeZone.getAvailableIDs() method.
import java.util.TimeZone; // w ww .ja v a 2 s .co m public class Main { public static void main(String[] args) { String[] ids = TimeZone.getAvailableIDs(); for(String id: ids){ System.out.println(id); } } }
The output: