code: private long parseDuration(String value) {
  	        long periodMS = 0L;
  	        if (value!=null) {
  	            String[] parts = value.split(":");
  	            for (int i = 0; i < parts.length; i++) {
  	                switch (i) {
  	                    case 0: // hours
  	                        periodMS += (Integer.parseInt(parts[i])) * 3600000L;
  	                        break;
  	                    case 1: // minutes
  	                        periodMS += (Integer.parseInt(parts[i])) * 60000L;
  	                        break;
  	                    case 2: // seconds
  	                        periodMS += (Integer.parseInt(parts[i])) * 1000L;
  	                        break;
  	                    case 3: // ms
  	                        periodMS += (Integer.parseInt(parts[i]));
  	                        break;
  	                    default:
  	                        break;
  	                }
  	            }
  	        }
  	        return periodMS;
  	    }
docs: Parse a duration of the form HH:mm:ss:nnn, whereas only hours are non
  optional.
  
  @param value the input value
  @return the duration in ms.