com.crystaldecisions.reports.common.value
Class DateValue

java.lang.Object
  extended by CrystalValue
      extended by com.crystaldecisions.reports.common.value.FormulaValue
          extended by com.crystaldecisions.reports.common.value.DateValue
All Implemented Interfaces:
java.lang.Comparable

public final class DateValue
extends FormulaValue
implements java.lang.Comparable


Field Summary
static int nullCRDate
           
 
Method Summary
 DateValue addNumberToDate(int n)
           
 FormulaValue coerceToDate()
           
 FormulaValue coerceToDateTime()
           
 int compareTo(java.lang.Object obj)
           
 int compareTo(java.lang.Object obj, java.util.Comparator stringComparator)
           
 boolean equals(java.lang.Object obj, boolean caseInsensitive)
           
static DateValue From1900Format(int inputDate)
           
static DateValue fromCalendar(java.util.Calendar calendar)
           
static DateValue fromCRDate(int CRDate)
           
static DateValue fromOleDate(double OleDate)
           
static DateValue fromYMD(int year, int month, int day)
           
 int getCRDate()
           
static int getCRDate(DateValue date)
           
 RangeValue getDateTimeRangeValue()
           
 int getDay()
           
static int getDay(DateValue date)
           
 int getEncodedSize(ValueType type)
           
 int getEncodedSizeForArchive(ValueType type)
           
 DateTimeValue getEndOfDayDateTimeValue()
           
 java.util.Date getJavaDate()
           
static int GetMaxEncodedSize()
           
 int getMonth()
           
static int getMonth(DateValue date)
           
 double getOleDate()
           
 DateTimeValue getStartOfDayDateTimeValue()
           
 ValueType getValueType()
           
 int getYear()
           
static int getYear(DateValue date)
           
 int hashCode(boolean caseInsensitive)
           
static boolean isValidOleDate(double OleDate)
           
static DateValue Load(java.io.DataInput in)
           
static DateValue LoadFromArchive(IInputArchive ar)
           
static DateValue now()
           
 void store(ValueType type, ExtendedDataOutput out)
           
 void storeToArchive(ValueType type, IOutputArchive ar)
           
static double To1900Format(DateValue date)
           
 java.lang.String toString()
           
 
Methods inherited from class com.crystaldecisions.reports.common.value.FormulaValue
coerce, coerceToArray, coerceToArray, coerceToBoolean, coerceToBoolean, coerceToCurrency, coerceToCurrency, coerceToDate, coerceToDateTime, coerceToNumber, coerceToNumber, coerceToRange, coerceToRange, coerceToRangeArray, coerceToRangeArray, coerceToString, coerceToString, coerceToTime, coerceToTime, getFormulaValueType, Load, LoadFromArchive, makeZeroValue
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

nullCRDate

public static final int nullCRDate
See Also:
Constant Field Values
Method Detail

now

public static DateValue now()

store

public void store(ValueType type,
                  ExtendedDataOutput out)
           throws java.io.IOException
Throws:
java.io.IOException

storeToArchive

public void storeToArchive(ValueType type,
                           IOutputArchive ar)
                    throws ArchiveException
Throws:
ArchiveException

LoadFromArchive

public static DateValue LoadFromArchive(IInputArchive ar)
                                 throws ArchiveException
Throws:
ArchiveException

Load

public static DateValue Load(java.io.DataInput in)
                      throws java.io.IOException
Throws:
java.io.IOException

GetMaxEncodedSize

public static int GetMaxEncodedSize()

getEncodedSizeForArchive

public int getEncodedSizeForArchive(ValueType type)

getEncodedSize

public int getEncodedSize(ValueType type)

fromCRDate

public static DateValue fromCRDate(int CRDate)

fromYMD

public static DateValue fromYMD(int year,
                                int month,
                                int day)

fromCalendar

public static DateValue fromCalendar(java.util.Calendar calendar)

fromOleDate

public static DateValue fromOleDate(double OleDate)

isValidOleDate

public static boolean isValidOleDate(double OleDate)

getOleDate

public double getOleDate()

getCRDate

public static int getCRDate(DateValue date)

getYear

public static int getYear(DateValue date)

getMonth

public static int getMonth(DateValue date)

getDay

public static int getDay(DateValue date)

getCRDate

public int getCRDate()

getYear

public int getYear()

getMonth

public int getMonth()

getDay

public int getDay()

getValueType

public ValueType getValueType()

coerceToDate

public FormulaValue coerceToDate()
Overrides:
coerceToDate in class FormulaValue

coerceToDateTime

public FormulaValue coerceToDateTime()
Overrides:
coerceToDateTime in class FormulaValue

getStartOfDayDateTimeValue

public DateTimeValue getStartOfDayDateTimeValue()

getEndOfDayDateTimeValue

public DateTimeValue getEndOfDayDateTimeValue()

getDateTimeRangeValue

public RangeValue getDateTimeRangeValue()

hashCode

public int hashCode(boolean caseInsensitive)

equals

public boolean equals(java.lang.Object obj,
                      boolean caseInsensitive)

compareTo

public int compareTo(java.lang.Object obj,
                     java.util.Comparator stringComparator)

compareTo

public int compareTo(java.lang.Object obj)
Specified by:
compareTo in interface java.lang.Comparable

addNumberToDate

public DateValue addNumberToDate(int n)

toString

public java.lang.String toString()

To1900Format

public static double To1900Format(DateValue date)

From1900Format

public static DateValue From1900Format(int inputDate)

getJavaDate

public java.util.Date getJavaDate()