Java tutorial
//package com.java2s; import org.joda.time.*; import org.joda.time.format.*; public class Main { public static DateTime createTimeUTC(String UTCrepresentation) { DateTimeFormatter UTCformat = null; try { UTCformat = DateTimeFormat.forPattern("YYYYMMdd'T'HHmmssZ"); } catch (IllegalArgumentException e) { e.printStackTrace(); } return UTCformat.parseDateTime(UTCrepresentation); } }