public class EPPContact
extends java.lang.Object
EPPContact
is the primary client interface class used for
contact management. An instance of EPPContact
is created with an
initialized EPPSession
, 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 of
EPPResponse
or instances of response classes in the
com.verisign.epp.codec.contact
package. EPPResponse
,
EPPContactCreateResp
,
EPPContactInfoResp
,
EPPContactCheckResp
,
EPPContactTransferResp
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
STAT_CLIENT_DELETE_PROHIBITED
clientDeleteProhibited status
|
static java.lang.String |
STAT_CLIENT_TRANSFER_PROHIBITED
clientTransferProhibited status
|
static java.lang.String |
STAT_CLIENT_UPDATE_PROHIBITED
clientUpdateProhibited status
|
static java.lang.String |
STAT_OK
Status constants
|
static java.lang.String |
STAT_PENDING_DELETE
pendingDelete status
|
static java.lang.String |
STAT_PENDING_TRANSFER
pendingTransfer status
|
static java.lang.String |
STAT_SERVER_DELETE_PROHIBITED
serverDeleteProhibited status
|
static java.lang.String |
STAT_SERVER_TRANSFER_PROHIBITED
serverTransferProhibited status
|
static java.lang.String |
STAT_SERVER_UPDATE_PROHIBITED
serverUpdateProhibited status
|
static java.lang.String |
STAT_STATUS_LINKED
linked status
|
static java.lang.String |
TRANSFER_APPROVE
Transfer approve constant
|
static java.lang.String |
TRANSFER_CANCEL
Transfer cancel constant
|
static java.lang.String |
TRANSFER_QUERY
Transfer query constant
|
static java.lang.String |
TRANSFER_REJECT
Transfer reject constant
|
static java.lang.String |
TRANSFER_REQUEST
Transfer request constant
|
Constructor and Description |
---|
EPPContact(EPPSession aSession)
Constructs an
EPPContact with an initialized
EPPSession instance. |
Modifier and Type | Method and Description |
---|---|
void |
addContactId(java.lang.String newContactId)
This method set the myContactInfo attribute.
|
void |
addExtension(EPPCodecComponent aExtension)
Adds a command extension object.
|
void |
addPostalInfo(EPPContactPostalDefinition newPostalContact)
This is a Setter Method for PostalContact private Attribute This
Attribute maintains This Object Contains Information about the Contact
|
void |
addStatus(java.lang.String aStatus)
Adds a status to the host.
|
void |
addStatus(java.lang.String aStatus,
java.lang.String aDesc,
java.lang.String aLang)
Adds a status to the host with a description.
|
java.util.Vector |
getAddStatus()
This is a Getter Method for AddStatus private Attribute This Attribute
maintains Vector of Add Status for Update Command
|
java.lang.String |
getAuthorizationId()
gets the authorization identifier for transfer operations using the
encodeTransfer method. |
EPPContactDisclose |
getDisclose()
Get disclose information.
|
java.lang.String |
getEmail()
This is a Getter Method for Email private Attribute This Attribute
maintains Email Address
|
java.util.Vector |
getExtensions()
Gets the command extensions.
|
java.lang.String |
getFaxExt()
Gets the fax extension.
|
java.lang.String |
getFaxNumber()
This is a Getter Method for FaxNumber private Attribute This Attribute
maintains Fax Number
|
EPPContactPostalDefinition |
getFirstPostalInfo()
Gets the first postal info object.
|
java.util.Vector |
getPostalInfo()
This is a Getter Method for PostalContact private Attribute This
Attribute maintains This Object Contains Information about the Contact
|
java.util.Vector |
getRemoveStatus()
This is a Getter Method for RemoveStatus private Attribute This Attribute
maintains Vector of Remove Status for Update Command
|
EPPResponse |
getResponse()
Gets the response associated with the last command.
|
java.lang.String |
getTransId()
Getter method for TransID instance variable
|
java.lang.String |
getVoicePhone()
This is a Getter Method for VoicePhone private Attribute This Attribute
maintains Voice Phone Number
|
void |
removeStatus(java.lang.String aStatus)
Removes a status from the host.
|
void |
removeStatus(java.lang.String aStatus,
java.lang.String aDesc,
java.lang.String aLang)
Removes a status from the host with a description.
|
protected void |
resetContact()
Resets the contact instance to its initial state.
|
EPPContactCheckResp |
sendCheck()
Sends a Contact Check Command to the server.
|
EPPResponse |
sendCreate()
Sends a Contact Create Command to the server.
|
EPPResponse |
sendDelete()
Sends a Contact Delete Command to the server.
|
EPPContactInfoResp |
sendInfo()
Sends a Contact Info Command to the server.
|
EPPContactTransferResp |
sendTransfer()
Sends a Contact Transfer Command to the server.
|
EPPResponse |
sendUpdate()
Sends a Contact Update Command to the server.
|
void |
setAuthorizationId(java.lang.String newAuthorizationId)
Sets the authorization identifier for transfer operations using the
encodeTransfer method. |
void |
setDisclose(EPPContactDisclose newDisclose)
Set disclose information.
|
void |
setEmail(java.lang.String newEmail)
This is a Setter Method for Email private Attribute This Attribute
maintains Email Address
|
void |
setExtension(EPPCodecComponent aExtension)
Deprecated.
Replaced by
addExtension(EPPCodecComponent) . This
method will add the extension as is done in
addExtension(EPPCodecComponent) . |
void |
setExtensions(java.util.Vector aExtensions)
Sets the command extension objects.
|
void |
setFaxExt(java.lang.String newFaxExt)
Sets the fax extension number.
|
void |
setFaxNumber(java.lang.String newFaxNumber)
Sets the fax number.
|
void |
setPostalInfo(java.util.Vector newPostalContacts)
Set contact postalInfo.
|
void |
setTransferOpCode(java.lang.String aTransferOpCode)
Sets the transfer operation for a call to
encodeTransfer . |
void |
setTransId(java.lang.String newTransId)
Setter method for TransID instance variable
|
void |
setVoiceExt(java.lang.String newVoiceExt)
Sets the voice extension number.
|
void |
setVoicePhone(java.lang.String newVoicePhone)
Sets the voice phone number.
|
public static final java.lang.String STAT_OK
public static final java.lang.String STAT_PENDING_DELETE
public static final java.lang.String STAT_PENDING_TRANSFER
public static final java.lang.String STAT_CLIENT_DELETE_PROHIBITED
public static final java.lang.String STAT_CLIENT_UPDATE_PROHIBITED
public static final java.lang.String STAT_STATUS_LINKED
public static final java.lang.String STAT_SERVER_DELETE_PROHIBITED
public static final java.lang.String STAT_SERVER_UPDATE_PROHIBITED
public static final java.lang.String STAT_CLIENT_TRANSFER_PROHIBITED
public static final java.lang.String STAT_SERVER_TRANSFER_PROHIBITED
public static final java.lang.String TRANSFER_APPROVE
public static final java.lang.String TRANSFER_CANCEL
public static final java.lang.String TRANSFER_QUERY
public static final java.lang.String TRANSFER_REJECT
public static final java.lang.String TRANSFER_REQUEST
public EPPContact(EPPSession aSession)
EPPContact
with an initialized
EPPSession
instance.aSession
- Session to use to send contact commandspublic void addExtension(EPPCodecComponent aExtension)
aExtension
- command extension object associated with the commandpublic void setExtension(EPPCodecComponent aExtension)
addExtension(EPPCodecComponent)
. This
method will add the extension as is done in
addExtension(EPPCodecComponent)
.aExtension
- command extension object associated with the commandpublic void setExtensions(java.util.Vector aExtensions)
aExtensions
- command extension objects associated with the commandpublic java.util.Vector getExtensions()
Vector
of concrete EPPCodecComponent
associated with the command if exists; null
otherwise.public void setTransferOpCode(java.lang.String aTransferOpCode)
encodeTransfer
.
The transfer code must be set to one of the
EPPContact.TRANSFER_
constants.aTransferOpCode
- One of the EPPContact.TRANSFER_
constantspublic java.util.Vector getPostalInfo()
Vector
of
EPPContactPostalDefinition
objects if set;
null
otherwise.public EPPContactPostalDefinition getFirstPostalInfo()
EPPContactPostalDefinition
) if it exists; null
otherwise.public void setPostalInfo(java.util.Vector newPostalContacts)
newPostalContacts
- java.util.Vectorpublic void addPostalInfo(EPPContactPostalDefinition newPostalContact)
newPostalContact
- DOCUMENT ME!public EPPContactDisclose getDisclose()
null
otherwise;public void setDisclose(EPPContactDisclose newDisclose)
newDisclose
- com.verisign.epp.codec.gen.EPPContactDisclosepublic void setVoicePhone(java.lang.String newVoicePhone)
newVoicePhone
- Voice phone number.public void setVoiceExt(java.lang.String newVoiceExt)
newVoiceExt
- Voice extension numberpublic void setFaxNumber(java.lang.String newFaxNumber)
newFaxNumber
- Fax number.public void setFaxExt(java.lang.String newFaxExt)
newFaxExt
- Fax extension numberpublic void setEmail(java.lang.String newEmail)
newEmail
- DOCUMENT ME!public java.lang.String getVoicePhone()
public java.lang.String getFaxNumber()
public java.lang.String getFaxExt()
null
otherwise.public java.lang.String getEmail()
public void addStatus(java.lang.String aStatus)
aStatus
- One of the STAT_
constantspublic void removeStatus(java.lang.String aStatus)
aStatus
- One of the STAT_
constantspublic void addStatus(java.lang.String aStatus, java.lang.String aDesc, java.lang.String aLang)
aStatus
- One of the STAT_
constantsaDesc
- Description of the rationale for the status changeaLang
- Language of aDesc
Use DEFAULT_LANG
for the default language ("us").public void removeStatus(java.lang.String aStatus, java.lang.String aDesc, java.lang.String aLang)
aStatus
- One of the STAT_
constantsaDesc
- Description of the rationale for the status changeaLang
- Language of aDesc
Use DEFAULT_LANG
for the default language ("us").public java.util.Vector getAddStatus()
public java.util.Vector getRemoveStatus()
public void addContactId(java.lang.String newContactId)
newContactId
- DOCUMENT ME!public void setAuthorizationId(java.lang.String newAuthorizationId)
encodeTransfer
method.newAuthorizationId
- unique daily client codeString
.public void setTransId(java.lang.String newTransId)
newTransId
- DOCUMENT ME!public java.lang.String getTransId()
public java.lang.String getAuthorizationId()
encodeTransfer
method.public EPPResponse getResponse()
public EPPResponse sendCreate() throws EPPCommandException
addContactId
- Sets the contact to update. Only one
contact is valid.setPostalContact
- Set the postal informationsetEmail
- Set the email addresssetAuthString
- Sets the contact authorization string.
setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
setVoicePhone
- Set the voice phonesetFaxNumber
- Set the fax numbersetInterPostalPostalContact
- Set the international
postal informationEPPContactCreateResp
containing the contact create
result.EPPCommandException
- Error executing the update command. Use
getResponse
to get the associated server
error response.public EPPContactCheckResp sendCheck() throws EPPCommandException
addContactName
- Adds a contact to check. More than one
contact can be checked in sendCheck
setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
EPPContactCheckResp
containing the contact check
information.EPPCommandException
- Error executing the check command. Use
getResponse
to get the associated server
error response.public EPPContactInfoResp sendInfo() throws EPPCommandException
addContactId
- Sets the contact to get info for. Only
one contact is valid.setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
EPPContactInfoResp
containing the contact
information.EPPCommandException
- Error executing the info command. Use
getResponse
to get the associated server
error response.public EPPResponse sendUpdate() throws EPPCommandException
addContactId
- Sets the contact to update. Only one
contact is valid.setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
addStatus
- Add statusremoveStatus
- Remove statussetPostalContact
- Set the postal informationsetVoicePhone
- Set the voice phonesetFaxNumber
- Set the fax numbersetEmail
- Set the email addresssetInterPostalPostalContact
- Set the international
postal informationsetAuthString
- Sets the contact authorization string.
EPPResponse
containing the contact update result.EPPCommandException
- Error executing the update command. Use
getResponse
to get the associated server
error response.public EPPContactTransferResp sendTransfer() throws EPPCommandException
addContactId
- Sets the contact for transfer command.
Only one contact is valid.setTransferOpCode
- Sets the contact transfer operation.
setAuthString
- Sets the contact authorization string.
setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
EPPContactTransferResp
containing the contact
transfer result.EPPCommandException
- Error executing the create command. Use
getResponse
to get the associated server
error response.public EPPResponse sendDelete() throws EPPCommandException
addContactId
- Sets the contact to delete. Only one
contact is valid.setTransId
- Sets the client transaction identifiersetExtension
- Command extension to send with command
EPPResponse
containing the delete result
information.EPPCommandException
- Error executing the delete command. Use
getResponse
to get the associated server
error response.protected void resetContact()
Copyright © VeriSign Inc. All Rights Reserved.