XmpDate

Inheritance: java.lang.Object, com.groupdocs.metadata.core.PropertyValue, com.groupdocs.metadata.core.XmpValueBase

public final class XmpDate extends XmpValueBase

Represents Date in XMP packet.


A date-time value is represented using a subset of the formats as defined in Date and Time Formats: YYYY YYYY-MM YYYY-MM-DD YYYY-MM-DDThh:mmTZD YYYY-MM-DDThh:mm:ssTZD YYYY-MM-DDThh:mm:ss.sTZD

Constructors

Constructor Description
XmpDate(Date dateTime) Initializes a new instance of the XmpDate class.
XmpDate(String dateString) Initializes a new instance of the XmpDate class.

Fields

Field Description
Iso8601Format The ISO 8601 (roundtrip) format string.

Methods

Method Description
getValue() Gets the value.
getFormat() Gets format string for current value.
getXmpRepresentation() Returns string contained value in XMP format.

XmpDate(Date dateTime)

public XmpDate(Date dateTime)

Initializes a new instance of the XmpDate class.

Parameters:

Parameter Type Description
dateTime java.util.Date DateTime value.

XmpDate(String dateString)

public XmpDate(String dateString)

Initializes a new instance of the XmpDate class.

Parameters:

Parameter Type Description
dateString java.lang.String Date in string representation.

Iso8601Format

public static final String Iso8601Format

The ISO 8601 (roundtrip) format string.


See more: https://en.wikipedia.org/wiki/ISO_8601.

getValue()

public final Date getValue()

Gets the value.

Returns: java.util.Date - DateTime value.

getFormat()

public final String getFormat()

Gets format string for current value.

Returns: java.lang.String - XMP date format string.

getXmpRepresentation()

public String getXmpRepresentation()

Returns string contained value in XMP format.

Returns: java.lang.String - string contained XMP representation.