Package com.verisign.epp.codec.gen
Class EPPGreeting
java.lang.Object
com.verisign.epp.codec.gen.EPPGreeting
- All Implemented Interfaces:
EPPCodecComponent,EPPMessage,Serializable,Cloneable
Represents an EPP Greeting message, which an EPP server uses in response to a
successful connection from an EPP client. The EPP Greeting contains the
following elements:
- A <greeting> element that identifies the start of the greeting.
- A <svID> element that contains the name of the server. Use
getServerandsetServerto get and set the element. - A <svDate> element that contains the server's current date and time
in UTC. Use
getServerDateandsetServerDatato get and set the element. - A <svcMenu> element that identifies the features supported by the
server. Use
getServiceMenuandsetServiceMenuto get and set the element.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final shortMaximum length of the server attribute.static final shortMinimum length of the server attribute. -
Constructor Summary
ConstructorsConstructorDescriptionAllocates a newEPPGreetingwith default attribute values.EPPGreeting(String aServer, Date aServerDate, EPPServiceMenu aServiceMenu) Allocates a newEPPGreetingand sets all of the instance attributes with the arguments.EPPGreeting(String aServer, Date aServerDate, EPPServiceMenu aServiceMenu, EPPDcp aDcp) Allocates a newEPPGreetingand sets the name and service menu instance attributes with the arguments. -
Method Summary
Modifier and TypeMethodDescriptionclone()CloneEPPGreeting.voiddecodeEPPGreetingfrom a DOM element tree.encodeEPPGreetinginto a DOM element tree.booleanimplements a deepEPPGreetingcompare.getDcp()Gets the DataCollection policy associated with the serverGets the associated EPP namespace.Gets the name of the server.Gets the server current date and time.Gets the service menu associated with the greeting, which defines the features supported by the server.booleanhasExtensionService(String aNamespaceURI) Does the greeting extension services include a specified extension service based on the Namespace URI?booleanhasService(String aNamespaceURI) Does the greeting include a specified service based on the Namespace URI?voidSets the DataCollectionPolciy associated with the greeting, which defines the access and statement supported by the server.voidSets the name of the server.voidsetServerDate(Date aServerDate) Sets the server current date and time.voidsetServiceMenu(EPPServiceMenu aServiceMenu) Sets the service menu associated with the greeting, which defines the features supported by the server.toString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.
-
Field Details
-
MIN_SERVER_LEN
public static final short MIN_SERVER_LENMinimum length of the server attribute.- See Also:
-
MAX_SERVER_LEN
public static final short MAX_SERVER_LENMaximum length of the server attribute.- See Also:
-
-
Constructor Details
-
EPPGreeting
public EPPGreeting()Allocates a newEPPGreetingwith default attribute values. The defaults include the following:
- server is set to
null - server date is set to now
- service menu is allocated with the default
EPPServiceMenuconstructor
setServerneeds to be called beforeencodewhen using this constructor. - server is set to
-
EPPGreeting
Allocates a newEPPGreetingand sets the name and service menu instance attributes with the arguments. The server date is defaulted to now.- Parameters:
aServer- name of the serveraServerDate- current server date and timeaServiceMenu- service menu instance associated with the greetingaDcp- Dcp instance associated with the greeting
-
EPPGreeting
Allocates a newEPPGreetingand sets all of the instance attributes with the arguments.- Parameters:
aServer- name of the serveraServerDate- current server date and timeaServiceMenu- service menu instance associated with the greeting
-
-
Method Details
-
getNamespace
Gets the associated EPP namespace. The general EPP namespace is returned, which is defined asEPPCodec.NS.- Specified by:
getNamespacein interfaceEPPCodecComponent- Specified by:
getNamespacein interfaceEPPMessage- Returns:
- namespace URI
-
getServer
Gets the name of the server. The server length is >=MIN_SERVER_LENand <=MAX_SERVER_LEN.- Returns:
- server
Stringinstance if defined; null otherwise.
-
setServer
Sets the name of the server. The server must be >=MIN_SERVER_LENand <=MAX_SERVER_LEN.- Parameters:
aServer- unique server name.
-
getServerDate
Gets the server current date and time.- Returns:
- Current server data and time.
-
setServerDate
Sets the server current date and time.- Parameters:
aServerDate- Current server data and time.
-
getServiceMenu
Gets the service menu associated with the greeting, which defines the features supported by the server.- Returns:
- service menu instance associated with the greeting.
-
hasService
Does the greeting include a specified service based on the Namespace URI?- Parameters:
aNamespaceURI- Service Namespace URI to search for- Returns:
trueif the greeting includes the service Namespace URI;falseotherwise.
-
hasExtensionService
Does the greeting extension services include a specified extension service based on the Namespace URI?- Parameters:
aNamespaceURI- Extension service Namespace URI to search for- Returns:
trueif the greeting extension services include the extension service Namespace URI;falseotherwise.
-
setServiceMenu
Sets the service menu associated with the greeting, which defines the features supported by the server.- Parameters:
aServiceMenu- service menu instance to associate with the greeting.
-
setDcp
Sets the DataCollectionPolciy associated with the greeting, which defines the access and statement supported by the server.- Parameters:
aDcp- service menu instance to associate with the greeting.
-
getDcp
Gets the DataCollection policy associated with the server- Returns:
- DataCollectionPolicy instance associated with the greeting.
-
encode
encodeEPPGreetinginto a DOM element tree. The <greeting> element is created and the attribute nodes are appended as children.- Specified by:
encodein interfaceEPPCodecComponent- Parameters:
aDocument- DOM Document to create elements from- Returns:
- <greeting> root element tree.
- Throws:
EPPEncodeException- Error encoding the DOM element tree.
-
decode
decodeEPPGreetingfrom a DOM element tree. The "greeting" element needs to be the value of theaElementargument.- Specified by:
decodein interfaceEPPCodecComponent- Parameters:
aElement- <greeting> root element tree.- Throws:
EPPDecodeException- Error decoding the DOM element tree.
-
equals
implements a deepEPPGreetingcompare. -
clone
CloneEPPGreeting.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classObject- Returns:
- clone of
EPPGreeting - Throws:
CloneNotSupportedException- standard Object.clone exception
-
toString
Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.
-