Code example for SimpleDateFormat

Methods: parse, setTimeZone

0
        } 
        return null; 
    } 
 
    private static Date parseDayDate(final String date) {
        final SimpleDateFormat ISO8601DATEFORMAT = new SimpleDateFormat("yyyy-MM-dd", Locale.US);
        ISO8601DATEFORMAT.setTimeZone(TimeZone.getTimeZone("UTC"));
        final String strippedDate = STRIP_DATE.matcher(date).replaceAll("+0$100");
        try { 
            return ISO8601DATEFORMAT.parse(strippedDate);
        } catch (ParseException e) {
            Log.e("OC11XMLParser.parseDayDate", e);
        } 
        return null; 
    } 
 
    private static CacheSize getCacheSize(final String sizeId) {
        try { 
            int size = Integer.parseInt(sizeId);
 
            switch (size) {