CLRA 0.1.2

com.clra.member
Class Telephone

java.lang.Object
  |
  +--com.clra.member.Telephone
All Implemented Interfaces:
Serializable

public class Telephone
extends Object
implements Serializable

Encapsulates telephone information of a CLRA member.

Version:
$Id: Telephone.java,v 1.2 2002/02/18 18:03:26 rphall Exp $
Author:
Rick Hall
See Also:
Serialized Form

Field Summary
static String DAY
           
static String EVENING
           
static String OTHER
           
 
Constructor Summary
Telephone()
          Produces an invalid instance.
Telephone(String number)
           
 
Method Summary
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

EVENING

public static final String EVENING

DAY

public static final String DAY

OTHER

public static final String OTHER
Constructor Detail

Telephone

public Telephone()
Produces an invalid instance. Used only during deserialization.

Telephone

public Telephone(String number)
          throws ValidationException
Parameters:
number - a string of the form "(123) 456-7890 Ext. 12345" where 123 is the area code, 456 is the exchange, 7890 is the local number, and 12345 is an optional extension. The area code, exchange and local number are required, so the minimal length of a valid number is 14 including parentheses, a space and a dash.
Throws:
ValidationException - if the number cannot be parsed into an area code, exchange, local number and an option extension.
Method Detail

toString

public String toString()
Overrides:
toString in class Object

CLRA 0.1.2