net.sf.saxon.value

Class GYearValue

public class GYearValue extends DateValue

Implementation of the xs:gYear data type
Constructor Summary
GYearValue()
GYearValue(CharSequence value)
GYearValue(int year, int tz)
Method Summary
AtomicValueconvertPrimitive(BuiltInAtomicType requiredType, boolean validate, XPathContext context)
Convert to target data type
CalendarValuecopy()
Make a copy of this date, time, or dateTime value
ItemTypegetItemType(TypeHierarchy th)
Determine the data type of the expression
CharSequencegetStringValueCS()

Constructor Detail

GYearValue

public GYearValue()

GYearValue

public GYearValue(CharSequence value)

GYearValue

public GYearValue(int year, int tz)

Method Detail

convertPrimitive

public AtomicValue convertPrimitive(BuiltInAtomicType requiredType, boolean validate, XPathContext context)
Convert to target data type

Parameters: requiredType an integer identifying the required atomic type context

Returns: an AtomicValue, a value of the required type; or an ErrorValue

copy

public CalendarValue copy()
Make a copy of this date, time, or dateTime value

getItemType

public ItemType getItemType(TypeHierarchy th)
Determine the data type of the expression

Parameters: th

Returns: Type.G_YEAR_TYPE,

getStringValueCS

public CharSequence getStringValueCS()