|
EPP RTK for Java v 0.7.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.omg.CORBA.portable.ObjectImpl | +--com.tucows.oxrs.epp0705.rtk.RTKBase | +--com.tucows.oxrs.epp0705.rtk.xml.EPPXMLBase
Top-level abstract class for all RTK classes that deal with XML data.
Field Summary | |
protected static java.util.Hashtable |
auth_type_string_to_type_hash_
Hashtable to allow for conversion from String auth id type to epp_AuthInfoType. |
protected static java.util.Hashtable |
transfer_status_to_type_hash_
Hashtable to allow for conversion from String transfer status to epp_TransferStatusType. |
protected java.lang.String |
xml_
Holder of the response XML String |
Fields inherited from class com.tucows.oxrs.epp0705.rtk.RTKBase |
CRLF, DATE_FMT, DEBUG_LEVEL_ONE, DEBUG_LEVEL_THREE, DEBUG_LEVEL_TWO, DEBUG_NONE, RTK_VERSION, UTC_FMT |
Constructor Summary | |
protected |
EPPXMLBase()
Default constructor |
protected |
EPPXMLBase(java.lang.String xml)
Constructor with XML String |
Method Summary | |
protected org.w3c.dom.Element |
addXMLElement(org.w3c.dom.Document doc,
org.w3c.dom.Element containing_element,
java.lang.String tag_name,
java.lang.String value)
Creates an Element for the given tag name and appends it to the given containing Element. |
static java.lang.Object |
convertListToArray(java.lang.Class the_class,
java.util.List the_list)
Converts a List of any size to a Java Object array that can be cast into an array of any class. |
static java.lang.String[] |
convertListToStringArray(java.util.List the_list)
Converts a List of any size of Strings to a Java Object array. |
protected org.w3c.dom.Element |
createDocRoot(org.w3c.dom.Document doc)
Given a Document, this method create the root epp tag and populates its attributes with xmlns, xmlns:xsi, and xsi:schemaLocation values. |
protected java.lang.String |
createXMLFromDoc(org.w3c.dom.Document doc)
Given a Document with all of its children elements appended, converts this document to an XML String. |
protected java.lang.String |
createXMLSnippetFromDoc(org.w3c.dom.Document doc)
Given a Document with all of its children elements appended, converts this document to an XML Snippet. |
static java.lang.Boolean |
getAvailResultFor(epp_CheckResult[] check_results,
java.lang.String check_value)
Given an array of epp_CheckResult's, finds the matching value and returns it's avail value in a Boolean object. |
static java.lang.Boolean |
getCheckResultFor(epp_CheckResult[] check_results,
java.lang.String check_value)
Deprecated. Please use getAvailResultFor(epp_CheckResult[] check_results,String check_value) |
protected org.w3c.dom.Element |
getDocumentElement()
Using pre-set response XML, returns the document's Element. |
protected org.w3c.dom.Element |
getElement(org.w3c.dom.NodeList node_list,
java.lang.String node_name)
Given the node list, it finds the Element for the given name. |
protected org.w3c.dom.Node |
getExtensionNode(java.lang.String extension_string)
Gets the Node representing the extension xml tag. |
protected org.w3c.dom.Node |
getNode(org.w3c.dom.NodeList node_list,
java.lang.String node_name)
Given the node list, it finds the node for the given name Please see the Xerces documentation for more information regarding Nodes and Nodelists |
static java.lang.String |
getPanData(org.w3c.dom.NodeList pan_data_list,
java.lang.String namespace_uri,
epp_PanData pan_data)
|
static epp_TransID |
getTransID(org.w3c.dom.Node trans_id_node)
|
java.lang.String |
getXML()
Accessor method for the response XML String |
static void |
initAuthInfoStringToTypeHash()
|
static void |
initHashes()
|
static void |
initTransferStatusToTypeHash()
|
protected epp_CheckResult[] |
parseGenericCheckResults(org.w3c.dom.Node chkdata_node)
Given the chkData XML node, it extracts the check value, object availability and reason text. |
protected epp_Response |
parseGenericResult(org.w3c.dom.Node response_node)
Given the response XML node, it extracts the result code and result text. |
protected org.w3c.dom.Element |
prepareAuthInfo(org.w3c.dom.Document doc,
java.lang.String object_name,
epp_AuthInfo auth_info)
Creates an EPP |
protected void |
prepareExtensionElement(org.w3c.dom.Document doc,
org.w3c.dom.Element command,
epp_Extension[] extensions)
Method to change an epp_Extension instance to XML elements. |
protected void |
stringListToXML(org.w3c.dom.Document doc,
org.w3c.dom.Element wrapper,
java.lang.String tag_name,
java.util.List list)
Given a list of String values, create Elements all with the same tag name and all going under the same Element wrapper. |
static epp_TransferStatusType |
transferStatusFromString(java.lang.String s)
|
static java.lang.String |
transferStatusToString(epp_TransferStatusType status_type)
Convenience method to get a transfer status string from an epp_TransferStatusType object. |
Methods inherited from class com.tucows.oxrs.epp0705.rtk.RTKBase |
_ids, debug, debug, getDebugLevel, getDebugPrintStream, getRTKProperties, setDebugLevel, setDebugLevel, setDebugPrintStream |
Methods inherited from class org.omg.CORBA.portable.ObjectImpl |
_create_request, _create_request, _duplicate, _get_delegate, _get_domain_managers, _get_interface_def, _get_policy, _hash, _invoke, _is_a, _is_equivalent, _is_local, _non_existent, _orb, _release, _releaseReply, _request, _request, _servant_postinvoke, _servant_preinvoke, _set_delegate, _set_policy_override, equals, hashCode, toString |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
protected static java.util.Hashtable transfer_status_to_type_hash_
EPP IDL epp.idl for the definition of the epp_TransferStatusType enum
protected static java.util.Hashtable auth_type_string_to_type_hash_
EPP IDL epp.idl for the definition of the epp_AuthInfoType enum
protected java.lang.String xml_
Constructor Detail |
protected EPPXMLBase()
protected EPPXMLBase(java.lang.String xml)
Method Detail |
public java.lang.String getXML()
public static void initHashes()
public static void initTransferStatusToTypeHash()
public static void initAuthInfoStringToTypeHash()
protected epp_Response parseGenericResult(org.w3c.dom.Node response_node) throws epp_XMLException
epp_XMLException
- if the node list does not contain the result textprotected org.w3c.dom.Node getNode(org.w3c.dom.NodeList node_list, java.lang.String node_name)
protected org.w3c.dom.Element getElement(org.w3c.dom.NodeList node_list, java.lang.String node_name)
getNode(NodeList,String)
protected org.w3c.dom.Element getDocumentElement() throws java.io.IOException, org.xml.sax.SAXException
java.io.IOException
- if there is an error getting the bytes from the XML
org.xml.sax.SAXException
- if there are XML errors
java.lang.RuntimeException
- if the XML document does not support Traversal v2.0protected org.w3c.dom.Element createDocRoot(org.w3c.dom.Document doc)
protected java.lang.String createXMLFromDoc(org.w3c.dom.Document doc) throws java.io.IOException
java.io.IOException
protected java.lang.String createXMLSnippetFromDoc(org.w3c.dom.Document doc) throws java.io.IOException
java.io.IOException
protected org.w3c.dom.Element addXMLElement(org.w3c.dom.Document doc, org.w3c.dom.Element containing_element, java.lang.String tag_name, java.lang.String value)
public static java.lang.Object convertListToArray(java.lang.Class the_class, java.util.List the_list)
List integer_list = (List)ArrayList();
integer_list.add(new Integer(1));
integer_list.add(new Integer(2));
Integer[] string_array = (Integer[]) EPPXMLBase.convertListToArray((new Integer()).getClass(), string_list)
public static java.lang.String[] convertListToStringArray(java.util.List the_list)
List string_list = (List)ArrayList();
string_list.add("Hello");
string_list.add("Goodbye");
// Note that no casting is required here.
String[] string_array = EPPXMLBase.convertListToStringArray(string_list)
protected void stringListToXML(org.w3c.dom.Document doc, org.w3c.dom.Element wrapper, java.lang.String tag_name, java.util.List list)
protected org.w3c.dom.Element prepareAuthInfo(org.w3c.dom.Document doc, java.lang.String object_name, epp_AuthInfo auth_info)
protected epp_CheckResult[] parseGenericCheckResults(org.w3c.dom.Node chkdata_node) throws epp_XMLException
epp_XMLException
- if the node list does not contain the datapublic static java.lang.Boolean getCheckResultFor(epp_CheckResult[] check_results, java.lang.String check_value)
public static java.lang.Boolean getAvailResultFor(epp_CheckResult[] check_results, java.lang.String check_value)
protected org.w3c.dom.Node getExtensionNode(java.lang.String extension_string) throws java.io.IOException, org.xml.sax.SAXException
java.io.IOException
- if there is an error getting the bytes from the XML
org.xml.sax.SAXException
- if there are XML errors
java.lang.RuntimeException
- if the XML document does not support Traversal v2.0protected void prepareExtensionElement(org.w3c.dom.Document doc, org.w3c.dom.Element command, epp_Extension[] extensions) throws epp_XMLException
epp_XMLException
public static java.lang.String transferStatusToString(epp_TransferStatusType status_type)
public static epp_TransferStatusType transferStatusFromString(java.lang.String s)
public static java.lang.String getPanData(org.w3c.dom.NodeList pan_data_list, java.lang.String namespace_uri, epp_PanData pan_data) throws epp_XMLException
epp_XMLException
public static epp_TransID getTransID(org.w3c.dom.Node trans_id_node)
|
EPP RTK for Java v 0.7.2 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |