zorba::ItemFactory Class Reference

ItemFactory to create Items. More...

#include <zorba/item_factory.h>

List of all members.

Public Member Functions

virtual Item createAnyURI (const String &aURI)=0
 Creates an AnyURI Item see [http://www.w3.org/TR/xmlschema-2/#anyURI].
virtual Item createBase64Binary (const char *aBinData, size_t aLength)=0
 Creates a Base64Binary Item see [http://www.w3.org/TR/xmlschema-2/#base64Binary].
virtual Item createBoolean (bool aValue)=0
 Creates a Boolean Item see [http://www.w3.org/TR/xmlschema-2/#bool].
virtual Item createByte (char aByte)=0
 Creates a Byte Item see [http://www.w3.org/TR/xmlschema-2/#byte].
virtual Item createDate (short aYear, short aMonth, short aDay)=0
 Creates a Date Item see [http://www.w3.org/TR/xmlschema-2/#date].
virtual Item createDate (const String &aDate)=0
 Creates a Date Item see [http://www.w3.org/TR/xmlschema-2/#date].
virtual Item createDateTime (const String &aDateTimeValue)=0
 Creates a DateTime Item see [http://www.w3.org/TR/xmlschema-2/#dateTime].
virtual Item createDateTime (short aYear, short aMonth, short aDay, short aHour, short aMinute, double aSecond, short aTimeZone_hours)=0
 Creates a DateTime Item see [http://www.w3.org/TR/xmlschema-2/#dateTime].
virtual Item createDecimal (const String &aValue)=0
 Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].
virtual Item createDecimalFromDouble (double aValue)=0
 Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].
virtual Item createDecimalFromLong (unsigned long aValue)=0
 Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].
virtual Item createDouble (const String &aValue)=0
 Creates a Double Item see [http://www.w3.org/TR/xmlschema-2/#double].
virtual Item createDouble (double aValue)=0
 Creates a Double Item see [http://www.w3.org/TR/xmlschema-2/#double].
virtual Item createDuration (short aYear, short aMonths, short aDays, short aHours, short aMinutes, double aSeconds)=0
 Creates a Duration Item see [http://www.w3.org/TR/xmlschema-2/#duration].
virtual Item createDuration (const String &aValue)=0
 Creates a Duration Item see [http://www.w3.org/TR/xmlschema-2/#duration].
virtual Item createFloat (float aValue)=0
 creates a float item see [http://www.w3.org/tr/xmlschema-2/#float]
virtual Item createFloat (const String &aValue)=0
 creates a float item see [http://www.w3.org/tr/xmlschema-2/#float]
virtual Item createGDay (short aDay)=0
 Creates a gDay Item see [http://www.w3.org/TR/xmlschema-2/#gDay].
virtual Item createGDay (const String &aValue)=0
 Creates a gDay Item see [http://www.w3.org/TR/xmlschema-2/#gDay].
virtual Item createGMonth (short aMonth)=0
 Creates a gMonth Item see [http://www.w3.org/TR/xmlschema-2/#gMonth].
virtual Item createGMonth (const String &aValue)=0
 Creates a gMonth Item see [http://www.w3.org/TR/xmlschema-2/#gMonth].
virtual Item createGMonthDay (short aMonth, short aDay)=0
 Creates a gMonthDay Item see [http://www.w3.org/TR/xmlschema-2/#gMonthDay].
virtual Item createGMonthDay (const String &aValue)=0
 Creates a gMonthDay Item see [http://www.w3.org/TR/xmlschema-2/#gMonthDay].
virtual Item createGYear (short aYear)=0
 Creates a gYear Item see [http://www.w3.org/TR/xmlschema-2/#gYear].
virtual Item createGYear (const String &aValue)=0
 Creates a gYear Item see [http://www.w3.org/TR/xmlschema-2/#gYear].
virtual Item createGYearMonth (short aYear, short aMonth)=0
 Creates a gYearMonth Item see [http://www.w3.org/TR/xmlschema-2/#gYearMonth].
virtual Item createGYearMonth (const String &aValue)=0
 Creates a gYearMonth Item see [http://www.w3.org/TR/xmlschema-2/#gYearMonth].
virtual Item createHexBinary (const char *aHexData, size_t aSize)=0
 Creates a HexBinary Item see [http://www.w3.org/TR/xmlschema-2/#hexBinary].
virtual Item createInt (int aInt)=0
 Creates a Int Item see [http://www.w3.org/TR/xmlschema-2/#int].
virtual Item createInteger (const String &aInteger)=0
 Creates an Integer Item see [http://www.w3.org/TR/xmlschema-2/#integer].
virtual Item createInteger (long long aInteger)=0
 Creates an Integer Item see [http://www.w3.org/TR/xmlschema-2/#integer].
virtual Item createLong (long long aLong)=0
 Creates a Long Item see [http://www.w3.org/TR/xmlschema-2/#long].
virtual Item createNCName (const String &aValue)=0
 Creates a NCName Item see [http://www.w3.org/TR/xmlschema-2/#NCName].
virtual Item createNegativeInteger (long long aValue)=0
 Creates a negativeInteger Item see [http://www.w3.org/TR/xmlschema-2/#negativeInteger].
virtual Item createNonNegativeInteger (unsigned long long aValue)=0
 Creates a nonNegativeInteger Item see [http://www.w3.org/TR/xmlschema-2/#nonNegativeInteger].
virtual Item createNonPositiveInteger (long long aValue)=0
 Creates a nonPositiveInteger Item see [http://www.w3.org/TR/xmlschema-2/#nonPositiveInteger].
virtual Item createPositiveInteger (unsigned long long aValue)=0
 Creates a positiveInteger\ Item see [http://www.w3.org/TR/xmlschema-2/#positiveInteger].
virtual Item createQName (const String &aNamespace, const String &aLocalname)=0
 Creates a QName Item see [http://www.w3.org/TR/xmlschema-2/#QName].
virtual Item createQName (const String &aNamespace, const String &aPrefix, const String &aLocalname)=0
 Creates a QName Item see [http://www.w3.org/TR/xmlschema-2/#QName].
virtual Item createShort (short aShort)=0
 Creates a Short Item see [http://www.w3.org/TR/xmlschema-2/#short].
virtual Item createString (const String &aString)=0
 Creates a String Item see [http://www.w3.org/TR/xmlschema-2/#string].
virtual Item createTime (short aHour, short aMinute, double aSecond, short aTimeZone_hours)=0
 Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].
virtual Item createTime (short aHour, short aMinute, double aSecond)=0
 Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].
virtual Item createTime (const String &aValue)=0
 Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].
virtual Item createUnsignedByte (const unsigned char aValue)=0
 Creates an Unsigned Byte Item see [http://www.w3.org/TR/xmlschema-2/#unsignedByte].
virtual Item createUnsignedInt (unsigned int aValue)=0
 Creates an unsigned int Item see [http://www.w3.org/TR/xmlschema-2/#unsignedInt].
virtual Item createUnsignedLong (unsigned long long aValue)=0
 Creates an unsignedLong Item see [http://www.w3.org/TR/xmlschema-2/#unsignedLong].
virtual Item createUnsignedShort (unsigned short aValue)=0
 Creates a unsignedShort Item see [http://www.w3.org/TR/xmlschema-2/#unsignedShort].
virtual ~ItemFactory ()
 Destructor.


Detailed Description

ItemFactory to create Items.

An instance of this class can be obtained by calling getItemFactory on the Zorba object.

Each createXXX function of this class creates an Item of an XML Schema item. If an isNull() call on an Item created by this function returns true the given Item could not be created.

Examples:

context.cpp.

Definition at line 31 of file item_factory.h.


Constructor & Destructor Documentation

virtual zorba::ItemFactory::~ItemFactory (  )  [inline, virtual]

Destructor.

Definition at line 36 of file item_factory.h.


Member Function Documentation

virtual Item zorba::ItemFactory::createAnyURI ( const String aURI  )  [pure virtual]

Creates an AnyURI Item see [http://www.w3.org/TR/xmlschema-2/#anyURI].

Parameters:
aURI String representation of the AnyURI.
Returns:
The AnyURI Item.
Examples:
datamanager.cpp.

virtual Item zorba::ItemFactory::createBase64Binary ( const char *  aBinData,
size_t  aLength 
) [pure virtual]

Creates a Base64Binary Item see [http://www.w3.org/TR/xmlschema-2/#base64Binary].

Parameters:
aBinData a pointer to the base64 binary data.
aLength the length of the base64 binary data.
Returns:
The Base64Binary Item.

virtual Item zorba::ItemFactory::createBoolean ( bool  aValue  )  [pure virtual]

Creates a Boolean Item see [http://www.w3.org/TR/xmlschema-2/#bool].

Parameters:
aValue bool representation of the Boolean.
Returns:
The Boolean Item.

virtual Item zorba::ItemFactory::createByte ( char  aByte  )  [pure virtual]

Creates a Byte Item see [http://www.w3.org/TR/xmlschema-2/#byte].

Parameters:
aByte char representation of the Byte.
Returns:
The Byte Item.

virtual Item zorba::ItemFactory::createDate ( short  aYear,
short  aMonth,
short  aDay 
) [pure virtual]

Creates a Date Item see [http://www.w3.org/TR/xmlschema-2/#date].

Parameters:
aYear short-valued representation of the year.
aMonth short-valued representation of the month.
aDay short-valued representation of the day.
Returns:
The Date Item.

virtual Item zorba::ItemFactory::createDate ( const String aDate  )  [pure virtual]

Creates a Date Item see [http://www.w3.org/TR/xmlschema-2/#date].

Parameters:
aDate String representation of the Date (e.g. 2002-10-10).
Returns:
The Date Item.

virtual Item zorba::ItemFactory::createDateTime ( const String aDateTimeValue  )  [pure virtual]

Creates a DateTime Item see [http://www.w3.org/TR/xmlschema-2/#dateTime].

Parameters:
aDateTimeValue String representation of the datetime value (for example, 2002-10-10T12:00:00-05:00).
Returns:
The DateTime Item.

virtual Item zorba::ItemFactory::createDateTime ( short  aYear,
short  aMonth,
short  aDay,
short  aHour,
short  aMinute,
double  aSecond,
short  aTimeZone_hours 
) [pure virtual]

Creates a DateTime Item see [http://www.w3.org/TR/xmlschema-2/#dateTime].

Parameters:
aYear short-valued representation of the year.
aMonth short-valued representation of the month.
aDay short-valued representation of the day.
aHour short-valued representation of the hour.
aMinute short-valued representation of the minute.
aSecond double-valued representation of the seconds and fractional seconds.
aTimeZone_hours short-valued representation of the difference in hours to UTC.
Returns:
The DateTime Item.
Examples:
context.cpp.

virtual Item zorba::ItemFactory::createDecimal ( const String aValue  )  [pure virtual]

Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].

Parameters:
aValue String representation of the Decimal (e.g. 12678967.543233).
Returns:
The Decimal Item.

virtual Item zorba::ItemFactory::createDecimalFromDouble ( double  aValue  )  [pure virtual]

Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].

Parameters:
aValue double representation of the Decimal.
Returns:
The Decimal Item.

virtual Item zorba::ItemFactory::createDecimalFromLong ( unsigned long  aValue  )  [pure virtual]

Creates a Decimal Item see [http://www.w3.org/TR/xmlschema-2/#decimal].

Parameters:
aValue unsigned long representation of the Decimal.
Returns:
The Decimal Item.

virtual Item zorba::ItemFactory::createDouble ( const String aValue  )  [pure virtual]

Creates a Double Item see [http://www.w3.org/TR/xmlschema-2/#double].

Parameters:
aValue String representation of the Double.
Returns:
The Double Item.

virtual Item zorba::ItemFactory::createDouble ( double  aValue  )  [pure virtual]

Creates a Double Item see [http://www.w3.org/TR/xmlschema-2/#double].

Parameters:
aValue double representation of the Double.
Returns:
The Double Item.

virtual Item zorba::ItemFactory::createDuration ( short  aYear,
short  aMonths,
short  aDays,
short  aHours,
short  aMinutes,
double  aSeconds 
) [pure virtual]

Creates a Duration Item see [http://www.w3.org/TR/xmlschema-2/#duration].

Parameters:
aYear short-valued representation of the years.
aMonths short-valued representation of the months.
aDays short-valued representation of the days.
aHours short-valued representation of the hours.
aMinutes short-valued representation of the minutes.
aSeconds double-valued representation of the seconds and fractional seconds.
Returns:
The Duration Item.

virtual Item zorba::ItemFactory::createDuration ( const String aValue  )  [pure virtual]

Creates a Duration Item see [http://www.w3.org/TR/xmlschema-2/#duration].

Parameters:
aValue String representation of the NCName.
Returns:
The Duration Item.

virtual Item zorba::ItemFactory::createFloat ( float  aValue  )  [pure virtual]

creates a float item see [http://www.w3.org/tr/xmlschema-2/#float]

Parameters:
aValue float representation of the float.
Returns:
the float item.

virtual Item zorba::ItemFactory::createFloat ( const String aValue  )  [pure virtual]

creates a float item see [http://www.w3.org/tr/xmlschema-2/#float]

Parameters:
aValue string representation of the float.
Returns:
the float item.

virtual Item zorba::ItemFactory::createGDay ( short  aDay  )  [pure virtual]

Creates a gDay Item see [http://www.w3.org/TR/xmlschema-2/#gDay].

Parameters:
aDay short representation of the gDay.
Returns:
The gDay Item.

virtual Item zorba::ItemFactory::createGDay ( const String aValue  )  [pure virtual]

Creates a gDay Item see [http://www.w3.org/TR/xmlschema-2/#gDay].

Parameters:
aValue String representation of the gDay.
Returns:
The gDay Item.

virtual Item zorba::ItemFactory::createGMonth ( short  aMonth  )  [pure virtual]

Creates a gMonth Item see [http://www.w3.org/TR/xmlschema-2/#gMonth].

Parameters:
aMonth short representation of the gMonth.
Returns:
The gMonth Item.

virtual Item zorba::ItemFactory::createGMonth ( const String aValue  )  [pure virtual]

Creates a gMonth Item see [http://www.w3.org/TR/xmlschema-2/#gMonth].

Parameters:
aValue String representation of the gMonth.
Returns:
The gMonth Item.

virtual Item zorba::ItemFactory::createGMonthDay ( short  aMonth,
short  aDay 
) [pure virtual]

Creates a gMonthDay Item see [http://www.w3.org/TR/xmlschema-2/#gMonthDay].

Parameters:
aMonth short representation of the month.
aDay short representation of the day.
Returns:
The gMonthDay Item.

virtual Item zorba::ItemFactory::createGMonthDay ( const String aValue  )  [pure virtual]

Creates a gMonthDay Item see [http://www.w3.org/TR/xmlschema-2/#gMonthDay].

Parameters:
aValue String representation of the gMonthDay.
Returns:
The gMonthDay Item.

virtual Item zorba::ItemFactory::createGYear ( short  aYear  )  [pure virtual]

Creates a gYear Item see [http://www.w3.org/TR/xmlschema-2/#gYear].

Parameters:
aYear short representation of the gYear.
Returns:
The gYear Item.

virtual Item zorba::ItemFactory::createGYear ( const String aValue  )  [pure virtual]

Creates a gYear Item see [http://www.w3.org/TR/xmlschema-2/#gYear].

Parameters:
aValue String representation of the gYear.
Returns:
The gYear Item.

virtual Item zorba::ItemFactory::createGYearMonth ( short  aYear,
short  aMonth 
) [pure virtual]

Creates a gYearMonth Item see [http://www.w3.org/TR/xmlschema-2/#gYearMonth].

Parameters:
aYear short representation of the year.
aMonth short representation of the month.
Returns:
The gYearMonth Item.

virtual Item zorba::ItemFactory::createGYearMonth ( const String aValue  )  [pure virtual]

Creates a gYearMonth Item see [http://www.w3.org/TR/xmlschema-2/#gYearMonth].

Parameters:
aValue String representation of the gYearMonth.
Returns:
The gYearMonth Item.

virtual Item zorba::ItemFactory::createHexBinary ( const char *  aHexData,
size_t  aSize 
) [pure virtual]

Creates a HexBinary Item see [http://www.w3.org/TR/xmlschema-2/#hexBinary].

Parameters:
aHexData pointer to the hexdata.
aSize size of the hexdata.
Returns:
The HexBinary Item.

virtual Item zorba::ItemFactory::createInt ( int  aInt  )  [pure virtual]

Creates a Int Item see [http://www.w3.org/TR/xmlschema-2/#int].

Parameters:
aInt int representation of the Int.
Returns:
The NCName Item.

virtual Item zorba::ItemFactory::createInteger ( const String aInteger  )  [pure virtual]

Creates an Integer Item see [http://www.w3.org/TR/xmlschema-2/#integer].

Parameters:
aInteger String representation of the Integer.
Returns:
The Integer Item.

virtual Item zorba::ItemFactory::createInteger ( long long  aInteger  )  [pure virtual]

Creates an Integer Item see [http://www.w3.org/TR/xmlschema-2/#integer].

Parameters:
aInteger unsigned long representation of the Integer.
Returns:
The Integer Item.
Examples:
context.cpp, and simple.cpp.

virtual Item zorba::ItemFactory::createLong ( long long  aLong  )  [pure virtual]

Creates a Long Item see [http://www.w3.org/TR/xmlschema-2/#long].

Parameters:
aLong long long representation of the Long.
Returns:
The Long Item.

virtual Item zorba::ItemFactory::createNCName ( const String aValue  )  [pure virtual]

Creates a NCName Item see [http://www.w3.org/TR/xmlschema-2/#NCName].

Parameters:
aValue String representation of the NCName.
Returns:
The NCName Item.

virtual Item zorba::ItemFactory::createNegativeInteger ( long long  aValue  )  [pure virtual]

Creates a negativeInteger Item see [http://www.w3.org/TR/xmlschema-2/#negativeInteger].

Parameters:
aValue long long representation of the negativeInteger.
Returns:
The negativeInteger Item.

virtual Item zorba::ItemFactory::createNonNegativeInteger ( unsigned long long  aValue  )  [pure virtual]

Creates a nonNegativeInteger Item see [http://www.w3.org/TR/xmlschema-2/#nonNegativeInteger].

Parameters:
aValue unsigned long representation of the nonNegativeInteger.
Returns:
The nonNegativeInteger Item.

virtual Item zorba::ItemFactory::createNonPositiveInteger ( long long  aValue  )  [pure virtual]

Creates a nonPositiveInteger Item see [http://www.w3.org/TR/xmlschema-2/#nonPositiveInteger].

Parameters:
aValue long long representation of the NCName.
Returns:
The nonPositiveInteger Item.

virtual Item zorba::ItemFactory::createPositiveInteger ( unsigned long long  aValue  )  [pure virtual]

Creates a positiveInteger\ Item see [http://www.w3.org/TR/xmlschema-2/#positiveInteger].

Parameters:
aValue unsigned long representation of the positiveInteger.
Returns:
The positiveInteger Item.

virtual Item zorba::ItemFactory::createQName ( const String aNamespace,
const String aLocalname 
) [pure virtual]

Creates a QName Item see [http://www.w3.org/TR/xmlschema-2/#QName].

Parameters:
aNamespace String representation of the namespace.
aLocalname String representation of the localname. *
Returns:
The QName Item.

virtual Item zorba::ItemFactory::createQName ( const String aNamespace,
const String aPrefix,
const String aLocalname 
) [pure virtual]

Creates a QName Item see [http://www.w3.org/TR/xmlschema-2/#QName].

Parameters:
aNamespace String representation of the namespace.
aPrefix String representation of the prefix.
aLocalname String representation of the localname.
Returns:
The QName Item.

virtual Item zorba::ItemFactory::createShort ( short  aShort  )  [pure virtual]

Creates a Short Item see [http://www.w3.org/TR/xmlschema-2/#short].

Parameters:
aShort short representation of the Short.
Returns:
The Short Item.

virtual Item zorba::ItemFactory::createString ( const String aString  )  [pure virtual]

Creates a String Item see [http://www.w3.org/TR/xmlschema-2/#string].

Parameters:
aString String representation of the String Item.
Returns:
The String Item

virtual Item zorba::ItemFactory::createTime ( short  aHour,
short  aMinute,
double  aSecond,
short  aTimeZone_hours 
) [pure virtual]

Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].

Parameters:
aHour short representation of the hour.
aMinute short representation of the minute.
aSecond double representation of the seconds and fractional seconds.
aTimeZone_hours short representation of the timezone difference in hours to UTC.
Returns:
The Time Item.

virtual Item zorba::ItemFactory::createTime ( short  aHour,
short  aMinute,
double  aSecond 
) [pure virtual]

Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].

Parameters:
aHour short representation of the hour.
aMinute short representation of the minute.
aSecond double representation of the seconds and fractional seconds.
Returns:
The Time Item.

virtual Item zorba::ItemFactory::createTime ( const String aValue  )  [pure virtual]

Creates a Time Item see [http://www.w3.org/TR/xmlschema-2/#time].

Parameters:
aValue String representation of the Time.
Returns:
The Time Item

virtual Item zorba::ItemFactory::createUnsignedByte ( const unsigned char  aValue  )  [pure virtual]

Creates an Unsigned Byte Item see [http://www.w3.org/TR/xmlschema-2/#unsignedByte].

Parameters:
aValue unsignedByte unsigned char representation of the unsigned byte.
Returns:
The Unsigned Byte Item.

virtual Item zorba::ItemFactory::createUnsignedInt ( unsigned int  aValue  )  [pure virtual]

Creates an unsigned int Item see [http://www.w3.org/TR/xmlschema-2/#unsignedInt].

Parameters:
aValue unsigned int representation of the unsignedInt.
Returns:
The unsignedInt Item.

virtual Item zorba::ItemFactory::createUnsignedLong ( unsigned long long  aValue  )  [pure virtual]

Creates an unsignedLong Item see [http://www.w3.org/TR/xmlschema-2/#unsignedLong].

Parameters:
aValue unsignedLong long long representation of the unsignedLong.
Returns:
The unsignedLong Item.

virtual Item zorba::ItemFactory::createUnsignedShort ( unsigned short  aValue  )  [pure virtual]

Creates a unsignedShort Item see [http://www.w3.org/TR/xmlschema-2/#unsignedShort].

Parameters:
aValue unsigned short representation of the unsignedShort.
Returns:
The unsignedShort Item.


The documentation for this class was generated from the following file: