net.sourceforge.jpalm.mobiledb.field.type
Class Phone

java.lang.Object
  extended by net.sourceforge.jpalm.mobiledb.field.type.Phone
All Implemented Interfaces:
Type<java.lang.String>

public class Phone
extends java.lang.Object
implements Type<java.lang.String>

A phone number in a MobileDB record.


Field Summary
protected  T value
           
 
Constructor Summary
Phone()
          Creates a new phone number.
Phone(java.lang.String phone)
          Creates a new phone number.
 
Method Summary
 boolean equals(java.lang.Object object)
           
static Phone fromMobileDB(java.lang.String string)
          Creates a phone number from the MobileDB value.
 java.lang.String getValue()
          Gets the native object for this type.
 java.lang.String toMobileDB()
          Gets the MobileDB value for this type.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.sourceforge.jpalm.mobiledb.field.type.Type
getValue, toMobileDB
 

Field Detail

value

protected T value
Constructor Detail

Phone

public Phone()
Creates a new phone number.


Phone

public Phone(java.lang.String phone)
Creates a new phone number.

Parameters:
phone - the phone number
Method Detail

fromMobileDB

public static Phone fromMobileDB(java.lang.String string)
Creates a phone number from the MobileDB value.

Parameters:
string - the MobileDB value to convert
Returns:
a phone number

toMobileDB

public java.lang.String toMobileDB()
Description copied from interface: Type
Gets the MobileDB value for this type.

Specified by:
toMobileDB in interface Type<java.lang.String>
Returns:
the MobileDB value

getValue

public java.lang.String getValue()
Description copied from interface: Type
Gets the native object for this type.

Specified by:
getValue in interface Type<java.lang.String>
Returns:
the native object

equals

public boolean equals(java.lang.Object object)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object