|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.knipp.rritoolkit.DomainData
public class DomainData
class that holds domain data, both for requests and responses
Nested Class Summary | |
---|---|
static class |
DomainData.DomainState
enumeration for the different states of the domain |
static class |
DomainData.Ref
class that represents a reference to a contact. |
static class |
DomainData.Role
enumeration for the different contact roles within the domain |
Field Summary | |
---|---|
private java.util.Date |
authInfo1ExpireDate
the date AuthInfo 1 expires ( null if not set or unknown) |
private java.util.Date |
authInfo2ExpireDate
the date AuthInfo 2 expires ( null if not set or unknown) |
private boolean |
authInfosSet
flag whether either AuthInfo 1 or AuthInfo 2 is set |
private java.util.Date |
changeDate
the last change date |
private java.lang.String |
changeProvAuthInfo
the AuthInfo text for the change provider operation |
private java.util.List<DomainData.Ref> |
contacts
the list of contacts |
private static boolean[] |
contactSectionFromDescr
the "from description" flags for the sections, order must be synchronized with contactSectionNames |
private static java.lang.String[] |
contactSectionNames
the names of the contact sections |
private static DomainData.Role[] |
contactSectionRoles
the types of the contact sections; order must be synchronized with contactSectionNames |
private java.util.List<DnsEntry> |
dns
the DNS related data |
private java.lang.String |
domainName
the domain name |
private DomainData.DomainState |
domainState
the domain state |
private java.lang.String |
encodedDomainName
the encoded domain name |
private java.util.Date |
expireDate
expire date |
private boolean |
inDispute
flag whether domain is in dispute |
private java.lang.String |
provider
the provider |
Constructor Summary | |
---|---|
DomainData()
constructor |
|
DomainData(DomainData other,
boolean deepCopy)
copy constructor |
Method Summary | |
---|---|
void |
addContact(DomainData.Ref ref)
add a single contact |
void |
addContact(DomainData.Role role,
ContactData contact)
add a single contact |
void |
addContacts(java.util.Collection<DomainData.Ref> refs)
add all given contacts |
void |
addContacts(DomainData.Ref... refs)
add all given contacts |
void |
addContacts(DomainData.Role role,
ContactData... theContacts)
add all given contacts |
void |
addDnsEntries(java.util.Collection<? extends DnsEntry> entries)
add all entries to the DNS configuration |
void |
addDnsEntries(DnsEntry... entries)
add all entries to the DNS configuration |
void |
addDnsEntry(DnsEntry entry)
add an entry to the DNS configuration |
void |
clearContacts()
clear all contact references |
void |
clearContacts(DomainData.Role role)
clear all contact references with the given role |
void |
clearDnsEntries()
clear all DNS entries |
void |
fromList(KVMultiList list)
parse the given key-value list. |
void |
fromXml(org.w3c.dom.Element node)
parse the given XML subtree |
java.util.Date |
getAuthInfo1ExpireDate()
return the expire date for the AuthInfo 1 |
java.util.Date |
getAuthInfo2ExpireDate()
return the expire date for the AuthInfo 2 |
java.util.Date |
getChangeDate()
return the change date |
java.lang.String |
getChangeProvAuthInfo()
return the AuthInfo that shall be used for the change provider operation |
java.util.List<DomainData.Ref> |
getContactRefs()
returns the list of contact references |
java.util.List<ContactData> |
getContacts(DomainData.Role role)
return a list of contacts with the given role |
java.util.List<DnsEntry> |
getDnsEntries()
return the DNS entries |
java.lang.String |
getDomainName()
return the domain name |
DomainData.DomainState |
getDomainState()
return the domain state |
java.lang.String |
getEncodedDomainName()
return the encoded domain name |
java.util.Date |
getExpireDate()
return the expiration date |
ContactData |
getFirstContact(DomainData.Role role)
return the first contact of the given role |
java.lang.String |
getProvider()
return the provider |
boolean |
hasAnyAuthInfos()
return whether any of the two AutInfos are valid; if the extended info response (own domain or "with provider" flag) is retrieved, which does not contain the flag, the value is set to true
if at least one of the two expire dates is given. |
void |
setChangeProvAuthInfo(java.lang.String authInfo)
set the AuthInfo that shall be used for the change provider operation |
void |
setDomainName(java.lang.String theDomainName)
set the domain name. |
void |
setDomainName(java.lang.String theDomainName,
java.lang.String theEncodedDomainName)
set the domain name |
void |
toList(KVList list,
boolean addDns)
convert the object to a KV list as part of a domain request (create, update, chholder, chprov, delete) |
java.lang.String |
toString()
convert the object to a string (for debugging purposes) |
void |
toXml(org.w3c.dom.Node node,
boolean addDns)
convert the object to XML as part of a domain request (create, update, chholder, chprov, delete) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private java.lang.String domainName
private java.lang.String encodedDomainName
private DomainData.DomainState domainState
private java.lang.String provider
private java.util.List<DomainData.Ref> contacts
private java.util.List<DnsEntry> dns
private java.util.Date changeDate
private java.util.Date expireDate
private boolean inDispute
private java.lang.String changeProvAuthInfo
private java.util.Date authInfo1ExpireDate
null
if not set or unknown)
private java.util.Date authInfo2ExpireDate
null
if not set or unknown)
private boolean authInfosSet
private static final java.lang.String[] contactSectionNames
private static final DomainData.Role[] contactSectionRoles
contactSectionNames
private static final boolean[] contactSectionFromDescr
contactSectionNames
Constructor Detail |
---|
public DomainData()
public DomainData(DomainData other, boolean deepCopy)
other
- the instance to copy fromdeepCopy
- if true
, a deep copy is
performed, i.e. copies from referenced
mutable objects are also createdMethod Detail |
---|
public void toList(KVList list, boolean addDns) throws EncodeException
list
- the listaddDns
- if true
, DNS data is added
EncodeException
- on encoding exceptionspublic void fromList(KVMultiList list) throws ResponseParseException
list
- the list to parse
ResponseParseException
- if the parsing failedpublic void toXml(org.w3c.dom.Node node, boolean addDns) throws org.w3c.dom.DOMException, EncodeException
node
- the node to add the contents toaddDns
- if true
, DNS data is added
org.w3c.dom.DOMException
- on DOM exceptions
EncodeException
- on encode exceptionspublic void fromXml(org.w3c.dom.Element node) throws org.w3c.dom.DOMException, ResponseParseException
node
- the node containing the contact data
(infoDataType)
org.w3c.dom.DOMException
- on DOM exceptions
ResponseParseException
- if the parsing failedpublic java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String getDomainName()
public java.lang.String getEncodedDomainName()
public void setDomainName(java.lang.String theDomainName)
theDomainName
- the domain namepublic void setDomainName(java.lang.String theDomainName, java.lang.String theEncodedDomainName)
theDomainName
- the domain nametheEncodedDomainName
- the encoded domain namepublic DomainData.DomainState getDomainState()
public java.lang.String getProvider()
null
)public java.lang.String getChangeProvAuthInfo()
null
if none is availablepublic void setChangeProvAuthInfo(java.lang.String authInfo)
authInfo
- the AuthInfo or null
if none
is availablepublic java.util.Date getAuthInfo1ExpireDate()
null
if it is not set
or not provided by the registry, i.e. if the
domain is not managed by the registrar and the
"with provider" flag has not been set in the requestpublic java.util.Date getAuthInfo2ExpireDate()
null
if it is not set
or not provided by the registry, i.e. if the
domain is not managed by the registrar and the
"with provider" flag has not been set in the requestpublic boolean hasAnyAuthInfos()
true
if at least one of the two expire dates is given.
true
if the domain has valid AuthInfospublic java.util.List<DomainData.Ref> getContactRefs()
public java.util.List<ContactData> getContacts(DomainData.Role role)
role
- the role
public ContactData getFirstContact(DomainData.Role role)
role
- the role
null
if
there are no contacts of that rolepublic void clearContacts()
public void clearContacts(DomainData.Role role)
role
- the role to clearpublic void addContact(DomainData.Role role, ContactData contact)
role
- the rolecontact
- the contactpublic void addContacts(DomainData.Role role, ContactData... theContacts)
role
- the roletheContacts
- the contactspublic void addContact(DomainData.Ref ref)
ref
- the referencepublic void addContacts(DomainData.Ref... refs)
refs
- the referencespublic void addContacts(java.util.Collection<DomainData.Ref> refs)
refs
- the referencespublic java.util.List<DnsEntry> getDnsEntries()
public void clearDnsEntries()
public void addDnsEntry(DnsEntry entry)
entry
- the entry to addpublic void addDnsEntries(DnsEntry... entries)
entries
- the entries to addpublic void addDnsEntries(java.util.Collection<? extends DnsEntry> entries)
entries
- the entriespublic java.util.Date getExpireDate()
null
if the domain does not expirepublic java.util.Date getChangeDate()
null
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |