public static Clock parseClock ( String str ) { if ( str == null || str . length ( ) == 0 ) { return Clock . ZERO ; } String [ ] parts = str . split ( ":" ) ; long [ ] values = new long [ parts . length ] ; for ( int i = 0 ; i < values . length ; i ++ ) { values [ i ] = Long . parseLong ( parts [ i ] ) ; } return new Clock ( values ) ; }
Parses a Clock value from its string representation .