org.apache.juddi.datatype
Class Phone

java.lang.Object
  extended by org.apache.juddi.datatype.Phone
All Implemented Interfaces:
java.io.Serializable, RegistryObject

public class Phone
extends java.lang.Object
implements RegistryObject

Holds telephone nbrs, can be adorned with an optinal useType attribute. If more than one Phone element is saved (in a Contacts.Phone[] ) then the useType must be supplied.

Author:
Steve Viens (sviens@apache.org)
See Also:
Serialized Form

Constructor Summary
Phone()
          Construct a new initialized Phone instance.
Phone(java.lang.String number)
          Construct a new phone with a given phone-number.
Phone(java.lang.String number, java.lang.String useType)
          Construct a new phone with a given phone-number and usetype.
 
Method Summary
 java.lang.String getUseType()
          Returns the UseType of this Phone.
 java.lang.String getValue()
          Returns the number of this Phone.
 void setUseType(java.lang.String type)
          Sets the UseType of this Phone to the given UseType.
 void setValue(java.lang.String number)
          Sets the number of this Phone to the given number.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Phone

public Phone()
Construct a new initialized Phone instance.


Phone

public Phone(java.lang.String number)
Construct a new phone with a given phone-number.

Parameters:
number - The number of the new phone.

Phone

public Phone(java.lang.String number,
             java.lang.String useType)
Construct a new phone with a given phone-number and usetype.

Parameters:
number - The number of the new phone.
useType - The usetype of the new phone.
Method Detail

setValue

public void setValue(java.lang.String number)
Sets the number of this Phone to the given number.

Parameters:
number - The new number of this phone.

getValue

public java.lang.String getValue()
Returns the number of this Phone.

Returns:
The number of this Phone.

setUseType

public void setUseType(java.lang.String type)
Sets the UseType of this Phone to the given UseType. If this Phone doesn't have a UseType anymore, then the new usetype must be null.

Parameters:
type - The new UseType of this Phone.

getUseType

public java.lang.String getUseType()
Returns the UseType of this Phone.

Returns:
The UseType of this Phone, or null if this Phone doesn't have an UseType.


Copyright © 2004-2007. All Rights Reserved.