class EppPeriod

This EppPeriod class implements EPP Domain periodType entity.

Inheritance:


Public Fields

[more]static const char UNIT_YEAR
Period unit for year ('y')
[more]static const char UNIT_MONTH
Period unit for month ('m')

Public Methods

[more] EppPeriod()
Creates an EppPeriod object, with default value 1 and unit of 'm'
[more] EppPeriod( int value, char unit )
Creates an EppPeriod object
[more] ~EppPeriod()
Destructor
[more]int getValue()
Gets the value of the period
[more]void setValue( int value )
Sets the value of the period
[more]char getUnit()
Gets the unit of the period
[more]void setUnit( char unit )
Sets the unit of the period, either 'y' for year or 'm' for month
[more]DOM_Element toXML( DOM_Document& doc, const DOMString& tag )
Converts the EppPeriod object into an XML element
[more]static EppPeriod* fromXML( const DOM_Node& root )
Converts an XML element into an EppPeriod object.


Inherited from EppEntity:

Public Methods

ovirtual int getEntityType()
obool instanceOf( const int type )
ovirtual DOMString toString()

Protected Methods

oDOMString toString( const DOMString &tag )


Documentation

This EppPeriod class implements EPP Domain periodType entity.

ostatic const char UNIT_YEAR
Period unit for year ('y')

ostatic const char UNIT_MONTH
Period unit for month ('m')

o EppPeriod()
Creates an EppPeriod object, with default value 1 and unit of 'm'

o EppPeriod( int value, char unit )
Creates an EppPeriod object

o ~EppPeriod()
Destructor

oint getValue()
Gets the value of the period

ovoid setValue( int value )
Sets the value of the period

ochar getUnit()
Gets the unit of the period

ovoid setUnit( char unit )
Sets the unit of the period, either 'y' for year or 'm' for month

oDOM_Element toXML( DOM_Document& doc, const DOMString& tag )
Converts the EppPeriod object into an XML element

Parameters:
doc - the XML DOM_Element object
tag - the tag/element name for the EppPeriod object
Returns:
an DOM_Element object

ostatic EppPeriod* fromXML( const DOM_Node& root )
Converts an XML element into an EppPeriod object. The caller of this method must make sure that the root node is of the EPP Period type.

Parameters:
root - root node for an EppPeriod object in XML format
Returns:
an EppPeriod object, or null if the node is invalid


This class has no child classes.
Author:
Ning Zhang ning.zhang@neustar.com
Version:
$Revision: 1.1 $ $Date: 2001/11/05 20:20:36 $

Alphabetic index HTML hierarchy of classes or Java


Copyright © 2001 NeuStar, Inc. All Rights Reserved.