de.uplanet.lucy.server.dataobjects.impl
Class NowValueHolder

java.lang.Object
  extended by de.uplanet.lucy.server.dataobjects.impl.NowValueHolder
All Implemented Interfaces:
de.uplanet.lucy.server.dataobjects.IDateTimeValueHolder, IValueHolder<java.util.Date>

public final class NowValueHolder
extends java.lang.Object
implements de.uplanet.lucy.server.dataobjects.IDateTimeValueHolder

Version:
$Revision: 70923 $

Constructor Summary
NowValueHolder()
           
 
Method Summary
 java.lang.String getCanonicalLexicalRepresentation()
          Get the canonical lexical representation of this value according to it's datatype.
 java.lang.Object getRawValue()
          Get the current time with fractional seconds in millisecond resolution.
 javax.xml.namespace.QName getType()
          The type of data this value holder holds.
 java.util.Date getValue()
          Get the current time with fractional seconds set to zero.
 boolean hasValue()
          Check if this value holder currently holds data or not.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NowValueHolder

public NowValueHolder()
Method Detail

getType

public javax.xml.namespace.QName getType()
Description copied from interface: IValueHolder
The type of data this value holder holds.

Specified by:
getType in interface IValueHolder<java.util.Date>
Returns:
XSD_TYPE.DATETIME.

getValue

public java.util.Date getValue()
Get the current time with fractional seconds set to zero.

Note that subsequent calls to getValue will return the same value.

Specified by:
getValue in interface IValueHolder<java.util.Date>
Returns:
A java.sql.Timestamp that represents the current time with fractional seconds set to zero.

getRawValue

public java.lang.Object getRawValue()
Get the current time with fractional seconds in millisecond resolution.

Note that subsequent calls to getValue will return the same value.

Specified by:
getRawValue in interface IValueHolder<java.util.Date>
Returns:
A java.sql.Timestamp that represents the current time.

hasValue

public boolean hasValue()
Description copied from interface: IValueHolder
Check if this value holder currently holds data or not.

Specified by:
hasValue in interface IValueHolder<java.util.Date>
Returns:
Always true.

getCanonicalLexicalRepresentation

public java.lang.String getCanonicalLexicalRepresentation()
Description copied from interface: IValueHolder
Get the canonical lexical representation of this value according to it's datatype.

Specified by:
getCanonicalLexicalRepresentation in interface IValueHolder<java.util.Date>
Returns:
The canonical lexical representation of the current date.
See Also:
Convert.getCanonicalLexicalRepresentationDateTime(Date).


Last updated: 2011-01-27
Copyright 2000-2010 United Planet. All Rights Reserved.