Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.flexstor.common.data.ejb.server
Class ServerData  view ServerData download ServerData.java

java.lang.Object
  extended bycom.flexstor.common.data.ejb.Data
      extended bycom.flexstor.common.data.ejb.server.ServerData
All Implemented Interfaces:
java.io.Serializable

public class ServerData
extends com.flexstor.common.data.ejb.Data

This class supports state data for Server. A Data class holds
all of the state information for a corresponding class and reference
pointers to other classes

Since:
FLEXSTOR.db 3.0
Version:
1.0, 1/25/99

Field Summary
protected  int appleTalkVendor
           
protected  java.sql.Timestamp currentTimestamp
           
protected  java.lang.String dnsName
           
static java.lang.String IDENTIFIER
           
protected  java.lang.String ipAddress
           
protected  java.lang.String name
           
protected  java.util.Hashtable ports
           
(package private) static long serialVersionUID
           
protected  com.flexstor.common.keys.ejb.ServerKey serverKey
           
 
Fields inherited from class com.flexstor.common.data.ejb.Data
DELETE, DELETED, derived, htModifiedStates, htOptions, MODIFY, modTime, NEW_ENTRY, presentState, prevState, UNCHANGED, UPDATED, WARN_BEFORE_DELETE
 
Constructor Summary
ServerData()
          Default constructor for the ServerData class
ServerData(java.lang.String aName)
          Constructor for the ServerDataBuild class
 
Method Summary
private  boolean arePortsEqual(java.util.Hashtable aPorts)
          Checks if all port data is equal
private  boolean checkSize(java.util.Hashtable aPorts)
          Checks to see if both port hashtables are the same size
 boolean equals(ServerData aDataObject)
          Determine if these two objects are equal, i.e.
 int getAppleTalkVendor()
          Appletalk Vendor getter method
 java.lang.String getDNSName()
          Return the DNS (domain name service) name for this server
 java.lang.String getIPAddress()
          Return the ip address for this server
 com.flexstor.common.keys.ejb.ServerKey getKey()
          Return the reference to this object
 java.lang.String getName()
          Return the user-defined name for this server
 java.lang.String getPort()
          Returns the port number for the default HTTP port
 java.lang.Integer getPort(java.lang.Integer nPortType)
          Returns the port number for a specific port type
 java.lang.String getPort(java.lang.String sPortName)
          Returns the port number as a String for a specific port type as a string
 java.util.Hashtable getPorts()
           
 com.flexstor.common.keys.ejb.ServerKey getReference()
          Deprecated. see getKey()
 java.sql.Timestamp getTimestamp()
          Return the timestamp of this object in database when the object was retrieved
private  boolean isDNSNameEqual(java.lang.String aDNSName)
          Checks whether two DNS name strings have equal values.
private  boolean isIPAddressEqual(java.lang.String anIPAddress)
          Checks whether two TCP/IP address strings have equal values.
private  boolean isNameEqual(java.lang.String aName)
          Checks whether two name strings have equal values.
private  boolean isPortEqual(java.lang.Integer nType, java.lang.Integer nPort)
          Checks whether two server port types have equal ports
 void setAppleTalkVendor(int vendor)
          Appletalk Vendor setting method
 void setDNSName(java.lang.String aDNSName)
          Return the user-defined name for this server
 void setIPAddress(java.lang.String anIPAddress)
          Set the ip address for this server
 void setKey(com.flexstor.common.keys.ejb.ServerKey aKey)
          Assign the reference to this record
 void setName(java.lang.String sName)
          Set the user-defined name for this server
 void setPort(java.lang.Integer aPort)
          Sets the default port information HTTP
 void setPorts(java.util.Hashtable aPorts)
          Sets the hashtable for the ports for this server
 void setReference(com.flexstor.common.keys.ejb.ServerKey aKey)
          Deprecated. see setKey()
 void setTimestamp(java.sql.Timestamp aTimeStamp)
          Assign the current timestamp of the object
 java.lang.String toString()
          Return the contents of the instance as a String.
 void updatePort(java.lang.Integer nPortType, java.lang.Integer nPort)
           
 
Methods inherited from class com.flexstor.common.data.ejb.Data
assertEquals, changed, fillCloneInfo, getDateModTime, getModTime, getPresentState, getPreviousState, initializeState, isDeleted, isDerived, isModified, isModified, isObjectPersist, isOptionAllowed, resetModifiedStates, rollBackState, setDeleted, setDerived, setModifiedState, setModTime, setModTime, setNewEntry, setOption, setPerisistState, setPreviousState, setState, setUpdated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

IDENTIFIER

public static final java.lang.String IDENTIFIER
See Also:
Constant Field Values

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

name

protected java.lang.String name

ports

protected java.util.Hashtable ports

dnsName

protected java.lang.String dnsName

ipAddress

protected java.lang.String ipAddress

appleTalkVendor

protected int appleTalkVendor

currentTimestamp

protected java.sql.Timestamp currentTimestamp

serverKey

protected com.flexstor.common.keys.ejb.ServerKey serverKey
Constructor Detail

ServerData

public ServerData()
Default constructor for the ServerData class

Warning Any objects created with this constructor are not updatable or insertable to the database


ServerData

public ServerData(java.lang.String aName)
Constructor for the ServerDataBuild class

Warning Any objects created with this constructor are not updatable (insertable, but not updatable) to the database

Method Detail

equals

public boolean equals(ServerData aDataObject)
Determine if these two objects are equal, i.e. their attributes are equal. This method will not test the equality of references to other objects


getDNSName

public java.lang.String getDNSName()
Return the DNS (domain name service) name for this server


getIPAddress

public java.lang.String getIPAddress()
Return the ip address for this server


getName

public java.lang.String getName()
Return the user-defined name for this server


getAppleTalkVendor

public int getAppleTalkVendor()
Appletalk Vendor getter method


setAppleTalkVendor

public void setAppleTalkVendor(int vendor)
Appletalk Vendor setting method


setName

public void setName(java.lang.String sName)
Set the user-defined name for this server


getPort

public java.lang.Integer getPort(java.lang.Integer nPortType)
                          throws com.flexstor.common.exceptions.ejb.EjbException
Returns the port number for a specific port type


getPort

public java.lang.String getPort(java.lang.String sPortName)
                         throws com.flexstor.common.exceptions.ejb.EjbException
Returns the port number as a String for a specific port type as a string


getPort

public java.lang.String getPort()
                         throws com.flexstor.common.exceptions.ejb.EjbException
Returns the port number for the default HTTP port


getPorts

public java.util.Hashtable getPorts()

getReference

public com.flexstor.common.keys.ejb.ServerKey getReference()
Deprecated. see getKey()

Return the reference to this object


getKey

public com.flexstor.common.keys.ejb.ServerKey getKey()
Return the reference to this object


getTimestamp

public java.sql.Timestamp getTimestamp()
Return the timestamp of this object in database when the object was retrieved


isDNSNameEqual

private boolean isDNSNameEqual(java.lang.String aDNSName)
Checks whether two DNS name strings have equal values.


isIPAddressEqual

private boolean isIPAddressEqual(java.lang.String anIPAddress)
Checks whether two TCP/IP address strings have equal values.


isNameEqual

private boolean isNameEqual(java.lang.String aName)
Checks whether two name strings have equal values.


arePortsEqual

private boolean arePortsEqual(java.util.Hashtable aPorts)
Checks if all port data is equal


checkSize

private boolean checkSize(java.util.Hashtable aPorts)
Checks to see if both port hashtables are the same size


isPortEqual

private boolean isPortEqual(java.lang.Integer nType,
                            java.lang.Integer nPort)
Checks whether two server port types have equal ports


setDNSName

public void setDNSName(java.lang.String aDNSName)
Return the user-defined name for this server


setIPAddress

public void setIPAddress(java.lang.String anIPAddress)
Set the ip address for this server


setPorts

public void setPorts(java.util.Hashtable aPorts)
Sets the hashtable for the ports for this server


setPort

public void setPort(java.lang.Integer aPort)
Sets the default port information HTTP


updatePort

public void updatePort(java.lang.Integer nPortType,
                       java.lang.Integer nPort)

setReference

public void setReference(com.flexstor.common.keys.ejb.ServerKey aKey)
Deprecated. see setKey()

Assign the reference to this record


setKey

public void setKey(com.flexstor.common.keys.ejb.ServerKey aKey)
Assign the reference to this record


setTimestamp

public void setTimestamp(java.sql.Timestamp aTimeStamp)
Assign the current timestamp of the object


toString

public java.lang.String toString()
Return the contents of the instance as a String. This method is strictly for use by testing classes
and should not be called by business objects