Package com.verisign.epp.interfaces
Class EPPDomain
- java.lang.Object
-
- com.verisign.epp.interfaces.EPPDomain
-
- Direct Known Subclasses:
EPPRelatedDomain
public class EPPDomain extends java.lang.ObjectEPPDomainis the primary client interface class used for domain management. An instance ofEPPDomainis created with an initializedEPPSession, and can be used for more than one request within a single thread. A set of setter methods are provided to set the attributes before a call to one of the send action methods. The responses returned from the send action methods are either instances ofEPPResponseor instances of response classes in thecom.verisign.epp.codec.domainpackage.
-
-
Field Summary
Fields Modifier and Type Field Description static intADDUsed to specify the addition of an attribute withsetUpdateAttrib.static intCHANGEUsed to specify the change of an attribute withsetUpdateAttrib.static intCONTACTUsed to specify a contact update withsetUpdateAttrib.static java.lang.StringCONTACT_ADMINISTRATIVEAdministrative contact constant used with @link{#addContact(String, String)}static java.lang.StringCONTACT_BILLINGBilling contact constant used with @link{#addContact(String, String)}static java.lang.StringCONTACT_TECHNICALTechnical contact constant used with @link{#addContact(String, String)}static intHOSTUsed to specify a host update withsetUpdateAttrib.static java.lang.StringHOSTS_ALLConstant on a call tosetHoststo get information on all hosts (delegated and subordinate).static java.lang.StringHOSTS_DELEGATEDConstant on a call tosetHoststo get information on just the delegated hosts.static java.lang.StringHOSTS_SUBORDINATEConstant on a call tosetHoststo get information on just the subordinate hosts.static java.lang.StringPERIOD_MONTHPeriod month unit contant.static java.lang.StringPERIOD_YEARPeriod year unit constant.static intREMOVEUsed to specify the removal of an attribute withsetUpdateAttrib.static intSTATUSUsed to specify a status update withsetUpdateAttrib.static java.lang.StringSTATUS_CLIENT_DELETE_PROHIBITEDclientDeleteProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.static java.lang.StringSTATUS_CLIENT_HOLDclientHoldconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.static java.lang.StringSTATUS_CLIENT_RENEW_PROHIBITEDclientRenewProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.static java.lang.StringSTATUS_CLIENT_TRANSFER_PROHIBITEDclientTransferProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.static java.lang.StringSTATUS_CLIENT_UPDATE_PROHIBITEDclientUpdateProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.static java.lang.StringSTATUS_INACTIVEinactiveconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_OKokconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_PENDING_CREATEpendingCreateconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_PENDING_DELETEpendingDeleteconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_PENDING_RENEWpendingRenewconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_PENDING_TRANSFERpendingTransferconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_PENDING_UPDATEpendingUpdateconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_SERVER_DELETE_PROHIBITEDserverDeleteProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_SERVER_HOLDserverHoldconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_SERVER_RENEW_PROHIBITEDserverRenewProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_SERVER_TRANSFER_PROHIBITEDserverTransferProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringSTATUS_SERVER_UPDATE_PROHIBITEDserverUpdateProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.static java.lang.StringTRANSFER_APPROVETransfer approve operation constant used with @link{#setTransferOpCode(String)}static java.lang.StringTRANSFER_CANCELTransfer cancel operation constant used with @link{#setTransferOpCode(String)}static java.lang.StringTRANSFER_QUERYTransfer query operation constant used with @link{#setTransferOpCode(String)}static java.lang.StringTRANSFER_REJECTTransfer reject operation constant used with @link{#setTransferOpCode(String)}static java.lang.StringTRANSFER_REQUESTTransfer request operation constant used with @link{#setTransferOpCode(String)}
-
Constructor Summary
Constructors Constructor Description EPPDomain(EPPSession aSession)Constructs anEPPDomaingiven an initialized EPP session.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddContact(java.lang.String aName, java.lang.String aType)Will add a new contact which includes a name and a type.voidaddDomainName(java.lang.String aDomain)Adds a domain name for use with asendmethod.voidaddExtension(EPPCodecComponent aExtension)Adds a command extension object.voidaddHostAttr(EPPHostAttr aHostAttr)Adds a host attribute name for use as a Domain delegating host.voidaddHostName(java.lang.String aHost)Adds a host name for use as a Domain delegating host.EPPAuthInfogetAuthInfo()Gets the set authorization information if defined.java.lang.StringgetAuthRoid()Sets the authorization roid that is used to identify the registrant or contact object if and only if the value of authInfo, set bysetAuthString(String), is associated with the registrant or contact object.java.lang.StringgetAuthString()Sets the authorization string associated with ansendCreateandsendTransfer.java.util.DategetExpirationDate()Gets the Domain expiration date.java.util.VectorgetExtensions()Gets the command extensions.java.lang.StringgetHosts()Sets the desired level of host information.intgetPeriodLength()Gets the registration period.java.lang.StringgetPeriodUnit()Gets the registration period unit.java.lang.StringgetRegistrant()Gets the Domain Registrant Contact Identifier.EPPResponsegetResponse()Gets the response associated with the last command.protected voidresetDomain()Resets the domain instance to its initial state.EPPDomainCheckRespsendCheck()Sends a Domain Name Check Command to the server.
The required attributes have been set with the following methods:
addDomainName- Adds a domain name to check.EPPDomainCreateRespsendCreate()Sends a Domain Name Create Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to create.EPPResponsesendDelete()Sends a Domain Name Delete Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to delete.EPPDomainInfoRespsendInfo()Sends a Domain Name Info Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to get info for.EPPDomainRenewRespsendRenew()Sends a Domain Name Renew Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to renew.EPPDomainTransferRespsendTransfer()Sends a Domain Name Transfer Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name for transfer command.EPPResponsesendUpdate()Sends a Domain Name Update Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to update.voidsetAuthInfo(EPPAuthInfo aAuthInfo)Sets the authorization information using theEPPAuthInfoobject.voidsetAuthRoid(java.lang.String aAuthRoid)Gets the authorization roid that is used to identify the registrant or contact object if and only if the value of authInfo, set bysetAuthString(String), is associated with the registrant or contact object.voidsetAuthString(java.lang.String aAuthString)Sets the authorization string associated with ansendCreateandsendTransferand optionallysendInfo.voidsetExpirationDate(java.util.Date aExpirationDate)Sets the Domain expiration date.voidsetExtension(EPPCodecComponent aExtension)Deprecated.Replaced byaddExtension(EPPCodecComponent).voidsetExtensions(java.util.Vector aExtensions)Sets the command extension objects.voidsetHosts(java.lang.String aHosts)Sets the desired level of host information.voidsetPeriodLength(int aPeriodLength)Sets the registration period.voidsetPeriodUnit(java.lang.String aPeriodUnit)Sets the registration period unit to eitherPERIOD_MONTHorPERIOD_YEAR.voidsetRegistrant(java.lang.String aRegistrant)Sets the Domain Registrant Contact Identifier.voidsetTransferOpCode(java.lang.String aTransferOpCode)Sets the transfer operation for a call toencodeTransfer.voidsetTransId(java.lang.String aTransId)Sets the client transaction identifier.voidsetUpdateAttrib(int aType, EPPDomainStatus aName, int aOp)Sets an update to a domain status.voidsetUpdateAttrib(int aType, java.lang.String aName, int aOp)Sets an update to a string list value, which currently can only be used for domain hosts.voidsetUpdateAttrib(int aType, java.lang.String aVal, java.lang.String aValType, int aOp)Sets an update to a domain contact.
-
-
-
Field Detail
-
HOST
public static final int HOST
Used to specify a host update withsetUpdateAttrib.- See Also:
- Constant Field Values
-
CONTACT
public static final int CONTACT
Used to specify a contact update withsetUpdateAttrib.- See Also:
- Constant Field Values
-
STATUS
public static final int STATUS
Used to specify a status update withsetUpdateAttrib.- See Also:
- Constant Field Values
-
ADD
public static final int ADD
Used to specify the addition of an attribute withsetUpdateAttrib.- See Also:
- Constant Field Values
-
REMOVE
public static final int REMOVE
Used to specify the removal of an attribute withsetUpdateAttrib.- See Also:
- Constant Field Values
-
CHANGE
public static final int CHANGE
Used to specify the change of an attribute withsetUpdateAttrib.- See Also:
- Constant Field Values
-
STATUS_OK
public static final java.lang.String STATUS_OK
okconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_SERVER_HOLD
public static final java.lang.String STATUS_SERVER_HOLD
serverHoldconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_SERVER_RENEW_PROHIBITED
public static final java.lang.String STATUS_SERVER_RENEW_PROHIBITED
serverRenewProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_SERVER_TRANSFER_PROHIBITED
public static final java.lang.String STATUS_SERVER_TRANSFER_PROHIBITED
serverTransferProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_SERVER_UPDATE_PROHIBITED
public static final java.lang.String STATUS_SERVER_UPDATE_PROHIBITED
serverUpdateProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_SERVER_DELETE_PROHIBITED
public static final java.lang.String STATUS_SERVER_DELETE_PROHIBITED
serverDeleteProhibitedconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_INACTIVE
public static final java.lang.String STATUS_INACTIVE
inactiveconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_PENDING_CREATE
public static final java.lang.String STATUS_PENDING_CREATE
pendingCreateconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_PENDING_DELETE
public static final java.lang.String STATUS_PENDING_DELETE
pendingDeleteconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_PENDING_RENEW
public static final java.lang.String STATUS_PENDING_RENEW
pendingRenewconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_PENDING_TRANSFER
public static final java.lang.String STATUS_PENDING_TRANSFER
pendingTransferconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_PENDING_UPDATE
public static final java.lang.String STATUS_PENDING_UPDATE
pendingUpdateconstant used with @link{com.verisign.epp.codec.domain.EPPDomainInfoResp.getStatuses()}.- See Also:
- Constant Field Values
-
STATUS_CLIENT_HOLD
public static final java.lang.String STATUS_CLIENT_HOLD
clientHoldconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.- See Also:
- Constant Field Values
-
STATUS_CLIENT_RENEW_PROHIBITED
public static final java.lang.String STATUS_CLIENT_RENEW_PROHIBITED
clientRenewProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.- See Also:
- Constant Field Values
-
STATUS_CLIENT_TRANSFER_PROHIBITED
public static final java.lang.String STATUS_CLIENT_TRANSFER_PROHIBITED
clientTransferProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.- See Also:
- Constant Field Values
-
STATUS_CLIENT_UPDATE_PROHIBITED
public static final java.lang.String STATUS_CLIENT_UPDATE_PROHIBITED
clientUpdateProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.- See Also:
- Constant Field Values
-
STATUS_CLIENT_DELETE_PROHIBITED
public static final java.lang.String STATUS_CLIENT_DELETE_PROHIBITED
clientDeleteProhibitedconstant used with @link{#setUpdateAttrib(int, EPPDomainStatus, int)}.- See Also:
- Constant Field Values
-
TRANSFER_APPROVE
public static final java.lang.String TRANSFER_APPROVE
Transfer approve operation constant used with @link{#setTransferOpCode(String)}- See Also:
- Constant Field Values
-
TRANSFER_CANCEL
public static final java.lang.String TRANSFER_CANCEL
Transfer cancel operation constant used with @link{#setTransferOpCode(String)}- See Also:
- Constant Field Values
-
TRANSFER_QUERY
public static final java.lang.String TRANSFER_QUERY
Transfer query operation constant used with @link{#setTransferOpCode(String)}- See Also:
- Constant Field Values
-
TRANSFER_REJECT
public static final java.lang.String TRANSFER_REJECT
Transfer reject operation constant used with @link{#setTransferOpCode(String)}- See Also:
- Constant Field Values
-
TRANSFER_REQUEST
public static final java.lang.String TRANSFER_REQUEST
Transfer request operation constant used with @link{#setTransferOpCode(String)}- See Also:
- Constant Field Values
-
CONTACT_ADMINISTRATIVE
public static final java.lang.String CONTACT_ADMINISTRATIVE
Administrative contact constant used with @link{#addContact(String, String)}- See Also:
- Constant Field Values
-
CONTACT_BILLING
public static final java.lang.String CONTACT_BILLING
Billing contact constant used with @link{#addContact(String, String)}- See Also:
- Constant Field Values
-
CONTACT_TECHNICAL
public static final java.lang.String CONTACT_TECHNICAL
Technical contact constant used with @link{#addContact(String, String)}- See Also:
- Constant Field Values
-
PERIOD_MONTH
public static final java.lang.String PERIOD_MONTH
Period month unit contant.- See Also:
- Constant Field Values
-
PERIOD_YEAR
public static final java.lang.String PERIOD_YEAR
Period year unit constant. This is the default unit.- See Also:
- Constant Field Values
-
HOSTS_ALL
public static final java.lang.String HOSTS_ALL
Constant on a call tosetHoststo get information on all hosts (delegated and subordinate). This is the default settings.- See Also:
- Constant Field Values
-
HOSTS_DELEGATED
public static final java.lang.String HOSTS_DELEGATED
Constant on a call tosetHoststo get information on just the delegated hosts.- See Also:
- Constant Field Values
-
HOSTS_SUBORDINATE
public static final java.lang.String HOSTS_SUBORDINATE
Constant on a call tosetHoststo get information on just the subordinate hosts.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EPPDomain
public EPPDomain(EPPSession aSession)
Constructs anEPPDomaingiven an initialized EPP session.- Parameters:
aSession- Server session to use.
-
-
Method Detail
-
addExtension
public void addExtension(EPPCodecComponent aExtension)
Adds a command extension object.- Parameters:
aExtension- command extension object associated with the command
-
setExtension
@Deprecated public void setExtension(EPPCodecComponent aExtension)
Deprecated.Replaced byaddExtension(EPPCodecComponent). This method will add the extension as is done inaddExtension(EPPCodecComponent).Sets a command extension object.- Parameters:
aExtension- command extension object associated with the command
-
setExtensions
public void setExtensions(java.util.Vector aExtensions)
Sets the command extension objects.- Parameters:
aExtensions- command extension objects associated with the command
-
getExtensions
public java.util.Vector getExtensions()
Gets the command extensions.- Returns:
Vectorof concreteEPPCodecComponentassociated with the command if exists;nullotherwise.
-
addDomainName
public void addDomainName(java.lang.String aDomain)
Adds a domain name for use with asendmethod. Adding more than one domain name is only supported bysendCheck.- Parameters:
aDomain- Domain name to add
-
addHostName
public void addHostName(java.lang.String aHost)
Adds a host name for use as a Domain delegating host.- Parameters:
aHost- Host name to add
-
addHostAttr
public void addHostAttr(EPPHostAttr aHostAttr)
Adds a host attribute name for use as a Domain delegating host. Calls toaddHostAttrcan not be mixed with calls toaddHostName.- Parameters:
aHostAttr- aHostAttr Host attribute
-
addContact
public void addContact(java.lang.String aName, java.lang.String aType)Will add a new contact which includes a name and a type.- Parameters:
aName- Contact NameaType- Contact Type, which should be aEPPDomain.CONTACT_constant.
-
setExpirationDate
public void setExpirationDate(java.util.Date aExpirationDate)
Sets the Domain expiration date.- Parameters:
aExpirationDate- Domain expiration date
-
getExpirationDate
public java.util.Date getExpirationDate()
Gets the Domain expiration date.- Returns:
- Domain expiration date
-
setTransferOpCode
public void setTransferOpCode(java.lang.String aTransferOpCode)
Sets the transfer operation for a call toencodeTransfer. The transfer code must be set to one of theEPPDomain.TRANSFER_constants.- Parameters:
aTransferOpCode- One of theEPPDomain.TRANSFER_constants
-
setTransId
public void setTransId(java.lang.String aTransId)
Sets the client transaction identifier.- Parameters:
aTransId- Client transaction identifier
-
setAuthString
public void setAuthString(java.lang.String aAuthString)
Sets the authorization string associated with ansendCreateandsendTransferand optionallysendInfo.- Parameters:
aAuthString- Authorization string
-
getAuthRoid
public java.lang.String getAuthRoid()
Sets the authorization roid that is used to identify the registrant or contact object if and only if the value of authInfo, set bysetAuthString(String), is associated with the registrant or contact object. This can be used withsendTransferandsendInfoalong with setting the authInfo with thesetAuthString(String)method.- Returns:
- Roid of registrant or contact object if defined;
nullotherwise.
-
setAuthRoid
public void setAuthRoid(java.lang.String aAuthRoid)
Gets the authorization roid that is used to identify the registrant or contact object if and only if the value of authInfo, set bysetAuthString(String), is associated with the registrant or contact object. This can be used withsendTransferandsendInfoalong with setting the authInfo with thesetAuthString(String)method.- Parameters:
aAuthRoid- Roid of registrant or contact object
-
getAuthString
public java.lang.String getAuthString()
Sets the authorization string associated with ansendCreateandsendTransfer.- Returns:
- Authorization string if defined;
nullotherwise.
-
getAuthInfo
public EPPAuthInfo getAuthInfo()
Gets the set authorization information if defined.- Returns:
- The authorization information if defined;
nullotherwise.
-
setAuthInfo
public void setAuthInfo(EPPAuthInfo aAuthInfo)
Sets the authorization information using theEPPAuthInfoobject.- Parameters:
aAuthInfo- The authorization information to set.
-
setHosts
public void setHosts(java.lang.String aHosts)
Sets the desired level of host information. The default isHOSTS_ALL.- Parameters:
aHosts- Should be one of theHOSTS_constants.
-
getHosts
public java.lang.String getHosts()
Sets the desired level of host information.- Returns:
- Should be one of the
HOSTS_constants.
-
getRegistrant
public java.lang.String getRegistrant()
Gets the Domain Registrant Contact Identifier.- Returns:
- Domain Registrant Contact Identifier if defined;
nullotherwise.
-
setRegistrant
public void setRegistrant(java.lang.String aRegistrant)
Sets the Domain Registrant Contact Identifier.- Parameters:
aRegistrant- Domain Registrant Contact Identifier.
-
sendCreate
public EPPDomainCreateResp sendCreate() throws EPPCommandException
Sends a Domain Name Create Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to create. Only one domain name is valid.setAuthString- Sets the domain name authorization string.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifiersetPeriodLength- Sets the registration period (default = 1)setPeriodUnit- Sets the registration period unit (default =PERIOD_YEAR)setRegistrant- Sets the Registrant for the domain. This is required for thick registries.addContact- Add domain contactaddHostName- Add domain delegation host
- Returns:
EPPDomainCreateRespcontaining the Domain create result.- Throws:
EPPCommandException- Error executing the create command. UsegetResponseto get the associated server error response.
-
sendUpdate
public EPPResponse sendUpdate() throws EPPCommandException
Sends a Domain Name Update Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to update. Only one domain name is valid.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifiersetUpdateAttrib(int,String,int)- Adds/removes hostssetUpdateAttrib(int,DomainStatus,int)- Adds/removes statusessetUpdateAttrib(int,String,String,int)- Adds/removes contactssetRegistrant- Sets the Registrant for the domain.setAuthString- Sets the domain name authorization string.
- Returns:
EPPResponsecontaining the Domain update result.- Throws:
EPPCommandException- Error executing the update command. UsegetResponseto get the associated server error response.
-
sendTransfer
public EPPDomainTransferResp sendTransfer() throws EPPCommandException
Sends a Domain Name Transfer Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name for transfer command. Only one domain name is valid.setTransferOpCode- Sets the domain transfer operation.setAuthString- Sets the domain name authorization string.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifiersetPeriodLength- Sets the registration period (default = 1)setPeriodUnit- Sets the registration period unit (default =PERIOD_YEAR)
- Returns:
EPPDomainTransferRespcontaining the Domain transfer result.- Throws:
EPPCommandException- Error executing the create command. UsegetResponseto get the associated server error response.
-
sendRenew
public EPPDomainRenewResp sendRenew() throws EPPCommandException
Sends a Domain Name Renew Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to renew. Only one domain name is valid.setExpirationDate- Sets current expiration date.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifiersetPeriodLength- Sets the registration period (default = 1)setPeriodUnit- Sets the registration period unit (default =PERIOD_YEAR)
- Returns:
EPPDomainRenewRespcontaining the Domain renew result.- Throws:
EPPCommandException- Error executing the renew command. UsegetResponseto get the associated server error response.
-
sendInfo
public EPPDomainInfoResp sendInfo() throws EPPCommandException
Sends a Domain Name Info Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to get info for. Only one domain name is valid.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifiersetAuthString- Sets the Authorization stringsetHosts- Sets the desired hosts to one of theHOSTS_constantsHOSTS_ALL,HOSTS_DELEGATED, orHOSTS_SUBORDINATE.HOSTS_ALLis the default.
- Returns:
EPPDomainInfoRespcontaining the Domain information.- Throws:
EPPCommandException- Error executing the info command. UsegetResponseto get the associated server error response.
-
sendCheck
public EPPDomainCheckResp sendCheck() throws EPPCommandException
Sends a Domain Name Check Command to the server.
The required attributes have been set with the following methods:
addDomainName- Adds a domain name to check. More than one domain name can be checked insendCheck
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifier
- Returns:
EPPDomainCheckRespcontaining the Domain check information.- Throws:
EPPCommandException- Error executing the check command. UsegetResponseto get the associated server error response.
-
sendDelete
public EPPResponse sendDelete() throws EPPCommandException
Sends a Domain Name Delete Command to the server.
The required attributes have been set with the following methods:
addDomainName- Sets the domain name to delete. Only one domain name is valid.
The optional attributes have been set with the following:
setTransId- Sets the client transaction identifier
- Returns:
EPPResponsecontaining the delete result information.- Throws:
EPPCommandException- Error executing the delete command. UsegetResponseto get the associated server error response.
-
resetDomain
protected void resetDomain()
Resets the domain instance to its initial state.
-
setUpdateAttrib
public void setUpdateAttrib(int aType, java.lang.String aName, int aOp) throws EPPCommandExceptionSets an update to a string list value, which currently can only be used for domain hosts. Domain hosts can only be added or removed.- Parameters:
aType- Must be set toHOSTaName- Name of hostaOp- EitherADDorREMOVE- Throws:
EPPCommandException- Invalid type or operation
-
setUpdateAttrib
public void setUpdateAttrib(int aType, EPPDomainStatus aName, int aOp) throws EPPCommandExceptionSets an update to a domain status. Domain statuses can be either added or removed.- Parameters:
aType- Must be set toSTATUSaName- Name of status, which can use one of theSTATUS_constantsaOp- EitherADDorREMOVE- Throws:
EPPCommandException- Invalid type or operation
-
setUpdateAttrib
public void setUpdateAttrib(int aType, java.lang.String aVal, java.lang.String aValType, int aOp) throws EPPCommandExceptionSets an update to a domain contact. Domain contacts can be either added or removed.- Parameters:
aType- Must be set toCONTACTaVal- Contact IdentifieraValType- Contact Type, which should be one of theCONTACT_constants.aOp- EitherADDorREMOVE- Throws:
EPPCommandException- Invalid type or operation
-
getResponse
public EPPResponse getResponse()
Gets the response associated with the last command. This method can be used to retrieve the server error response in the catch block of EPPCommandException.- Returns:
- Response associated with the last command
-
getPeriodLength
public int getPeriodLength()
Gets the registration period.- Returns:
- Registration period;
nullotherwise.
-
setPeriodLength
public void setPeriodLength(int aPeriodLength)
Sets the registration period.- Parameters:
aPeriodLength- Registration period
-
getPeriodUnit
public java.lang.String getPeriodUnit()
Gets the registration period unit.- Returns:
- Registration period unit if defined;
nullotherwise.
-
setPeriodUnit
public void setPeriodUnit(java.lang.String aPeriodUnit)
Sets the registration period unit to eitherPERIOD_MONTHorPERIOD_YEAR.- Parameters:
aPeriodUnit- Registration period unit
-
-