Commit 42a242fb authored by mbrodhu's avatar mbrodhu
Browse files

Merge branch 'release/1.1.13'

parents 6f48a84b 8efc014f
......@@ -5,7 +5,7 @@
<groupId>org.classicmayan.tools</groupId>
<artifactId>metsModsMapping</artifactId>
<packaging>jar</packaging>
<version>1.1.12</version>
<version>1.1.13</version>
<name>metsModsMapping</name>
<url>http://maven.apache.org</url>
......
package org.classicmayan.tools;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.TimeZone;
public class MetsModsUtilities {
public static String datestampAsString(String originalDateTimeString) throws ParseException {
SimpleDateFormat tgItemTime = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.S");
Date date = tgItemTime.parse(originalDateTimeString);
SimpleDateFormat outFormatter = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'");
outFormatter.setTimeZone(TimeZone.getTimeZone("UTC"));
String dateOutputAsString = outFormatter.format(date);
return dateOutputAsString;
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment