com.esri.core.map.popup
Class PopupDateFormatValue

java.lang.Object
  extended by com.esri.core.map.popup.PopupFormatValue
      extended by com.esri.core.map.popup.PopupDateFormatValue

public class PopupDateFormatValue
extends PopupFormatValue

The PopupDateFormatValue class extends PopupFormatValue and represents the date format.


Nested Class Summary
static class PopupDateFormatValue.DATE_FORMAT
          Enumeration of all the date formats that are supported by a popup.
 
Constructor Summary
PopupDateFormatValue()
          Default constructor for PopupDateFormatValue
PopupDateFormatValue(PopupDateFormatValue.DATE_FORMAT format)
          Constructor for PopupDateFormatValue that sets an initial PopupDateFormatValue.DATE_FORMAT.
 
Method Summary
 String formattedValue(Object value)
          Formats a given date object into a string.
 SimpleDateFormat getFormat()
          Returns the SimpleDateFormat of this PopupDateFormatValue.
 void setFormat(PopupDateFormatValue.DATE_FORMAT format)
          Sets the date format using a PopupDateFormatValue.DATE_FORMAT.
 void setFormat(SimpleDateFormat format)
          Sets the date format according to the given SimpleDateFormat object.
 
Methods inherited from class com.esri.core.map.popup.PopupFormatValue
fromJson
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PopupDateFormatValue

public PopupDateFormatValue()
Default constructor for PopupDateFormatValue


PopupDateFormatValue

public PopupDateFormatValue(PopupDateFormatValue.DATE_FORMAT format)
Constructor for PopupDateFormatValue that sets an initial PopupDateFormatValue.DATE_FORMAT.

Parameters:
format - A PopupDateFormatValue.DATE_FORMAT.
Method Detail

getFormat

public SimpleDateFormat getFormat()
Returns the SimpleDateFormat of this PopupDateFormatValue.

Returns:
A SimpleDateFormat object.

setFormat

public void setFormat(SimpleDateFormat format)
Sets the date format according to the given SimpleDateFormat object. The SimpleDateFormat will be mapped to a PopupDateFormatValue.DATE_FORMAT.

Parameters:
format - The format as a SimpleDateFormat

setFormat

public void setFormat(PopupDateFormatValue.DATE_FORMAT format)
Sets the date format using a PopupDateFormatValue.DATE_FORMAT.

Parameters:
format - The format as a PopupDateFormatValue.DATE_FORMAT

formattedValue

public String formattedValue(Object value)
Formats a given date object into a string. Examples of date objects are a date value expressed in milliseconds and a Date object.

Specified by:
formattedValue in class PopupFormatValue
Parameters:
value - The value to be formatted
Returns:
The value formatted as a Date, represented as a String.


Copyright © 2012. All Rights Reserved.