Project JXTA

net.jxta.impl.config
Class HostAddress

java.lang.Object
  |
  +--net.jxta.impl.config.HostAddress

public class HostAddress
extends java.lang.Object

Simple class to represent hostname and port atomically


Constructor Summary
HostAddress(java.lang.String aHostname, int aPort)
          Creates a HostAddress given a hostname and a port
 
Method Summary
 java.lang.String getHostname()
          Returns the hostname port of the HostAddress
 int getPort()
          Returns the port portion of the HostAddress
static HostAddress newFromXML(net.jxta.document.Element parent)
          creates an instance from passing in a parent XML element
 void writeToXML(net.jxta.document.StructuredTextDocument doc, net.jxta.document.Element parent)
          writes the HostAddress to an XML doc
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HostAddress

public HostAddress(java.lang.String aHostname,
                   int aPort)
Creates a HostAddress given a hostname and a port
Method Detail

getHostname

public java.lang.String getHostname()
Returns the hostname port of the HostAddress

getPort

public int getPort()
Returns the port portion of the HostAddress

writeToXML

public void writeToXML(net.jxta.document.StructuredTextDocument doc,
                       net.jxta.document.Element parent)
writes the HostAddress to an XML doc

newFromXML

public static HostAddress newFromXML(net.jxta.document.Element parent)
creates an instance from passing in a parent XML element

Project JXTA