public static JavaTimeZone createTimeZone ( String id ) { java . util . TimeZone jtz = null ; if ( AVAILABLESET . contains ( id ) ) { jtz = java . util . TimeZone . getTimeZone ( id ) ; } if ( jtz == null ) { // Use ICU's canonical ID mapping boolean [ ] isSystemID = new boolean [ 1 ] ; String canonicalID = TimeZone . getCanonicalID ( id , isSystemID ) ; if ( isSystemID [ 0 ] && AVAILABLESET . contains ( canonicalID ) ) { jtz = java . util . TimeZone . getTimeZone ( canonicalID ) ; } } if ( jtz == null ) { return null ; } return new JavaTimeZone ( jtz , id ) ; }
Creates an instance of JavaTimeZone with the given timezone ID .