Rakesh API

org.rakeshv.xml.addressbook
Class Address

java.lang.Object
  extended by org.rakeshv.xml.addressbook.Address

public class Address
extends java.lang.Object

A bean that represents a postal address. Multiple postal addresses may be available for a person in the address book.

Copyright 2003 Rakesh Vidyadharan

Version:
$Id: Address.java,v 1.3 2004/05/26 11:42:39 rakesh Exp $
Author:
Rakesh Vidyadharan 2003 February 12

Field Summary
private  java.lang.String city
          The city to which the address belongs.
private  java.lang.String country
          The country to which the address belongs.
private  java.lang.String postalCode
          The postal code of the address.
private  java.lang.String state
          The state to which the address belongs.
private  java.lang.String street1
          The street address of the person.
private  java.lang.String street2
          The secondary street address of the person.
private  java.lang.String street3
          The tertiary street address of the person.
 
Constructor Summary
Address()
          Default constructor.
Address(java.lang.String street1, java.lang.String city, java.lang.String state, java.lang.String postalCode, java.lang.String country)
          Construct an new address with most of the common fields populated.
Address(java.lang.String street1, java.lang.String street2, java.lang.String street3, java.lang.String city, java.lang.String state, java.lang.String postalCode, java.lang.String country)
          Construct an new address with all the fields populated.
 
Method Summary
 java.lang.String getCity()
          Return the value/reference of the city.
 java.lang.String getCountry()
          Return the value/reference of the country.
 java.lang.String getPostalCode()
          Return the value/reference of the postalCode.
 java.lang.String getState()
          Return the value/reference of the state.
 java.lang.String getStreet1()
          Return the value/reference of the street1.
 java.lang.String getStreet2()
          Return the value/reference of the street2.
 java.lang.String getStreet3()
          Return the value/reference of the street3.
 void setCity(java.lang.String city)
          Set the value of city.
 void setCountry(java.lang.String country)
          Set the value of country.
 void setPostalCode(java.lang.String postalCode)
          Set the value of postalCode.
 void setState(java.lang.String state)
          Set the value of state.
 void setStreet1(java.lang.String street1)
          Set the value of street1.
 void setStreet2(java.lang.String street2)
          Set the value of street2.
 void setStreet3(java.lang.String street3)
          Set the value of street3.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

street1

private java.lang.String street1
The street address of the person. This field maps to the street1 element.


street2

private java.lang.String street2
The secondary street address of the person. This field maps to the street2 element.


street3

private java.lang.String street3
The tertiary street address of the person. This field maps to the street3 element.


city

private java.lang.String city
The city to which the address belongs. This field maps to the city element.


state

private java.lang.String state
The state to which the address belongs. This field maps to the state element.


postalCode

private java.lang.String postalCode
The postal code of the address. This field maps to the postalCode element.


country

private java.lang.String country
The country to which the address belongs. This field maps to the country element.

Constructor Detail

Address

public Address()
Default constructor. Just serves to create an instance, which may then be used to populate the fields using the mutator methods.


Address

public Address(java.lang.String street1,
               java.lang.String city,
               java.lang.String state,
               java.lang.String postalCode,
               java.lang.String country)
Construct an new address with most of the common fields populated. Simply invokes Address( String, String, String, String, String, String, String ) with null values for street2 and street3.

Parameters:
street1 - - The first line of the street address.
city - - The city of the address.
state - - The state of the address.
postalCode - - The postalCode of the address.
country - - The country of the address.

Address

public Address(java.lang.String street1,
               java.lang.String street2,
               java.lang.String street3,
               java.lang.String city,
               java.lang.String state,
               java.lang.String postalCode,
               java.lang.String country)
Construct an new address with all the fields populated.

Parameters:
street1 - - The first line of the street address.
street2 - - The second line of the street address.
street3 - - The third line of the street address.
city - - The city of the address.
state - - The state of the address.
postalCode - - The postalCode of the address.
country - - The country of the address.
Method Detail

getStreet1

public final java.lang.String getStreet1()
Return the value/reference of the street1.

Returns:
String - The value/reference of street1.

setStreet1

public final void setStreet1(java.lang.String street1)
Set the value of street1.

Parameters:
street1 - - The value to set.

getStreet2

public final java.lang.String getStreet2()
Return the value/reference of the street2.

Returns:
String - The value/reference of street2.

setStreet2

public final void setStreet2(java.lang.String street2)
Set the value of street2.

Parameters:
street2 - - The value to set.

getStreet3

public final java.lang.String getStreet3()
Return the value/reference of the street3.

Returns:
String - The value/reference of street3.

setStreet3

public final void setStreet3(java.lang.String street3)
Set the value of street3.

Parameters:
street3 - - The value to set.

getCity

public final java.lang.String getCity()
Return the value/reference of the city.

Returns:
String - The value/reference of city.

setCity

public final void setCity(java.lang.String city)
Set the value of city.

Parameters:
city - - The value to set.

getState

public final java.lang.String getState()
Return the value/reference of the state.

Returns:
String - The value/reference of state.

setState

public final void setState(java.lang.String state)
Set the value of state.

Parameters:
state - - The value to set.

getPostalCode

public final java.lang.String getPostalCode()
Return the value/reference of the postalCode.

Returns:
String - The value/reference of postalCode.

setPostalCode

public final void setPostalCode(java.lang.String postalCode)
Set the value of postalCode.

Parameters:
postalCode - - The value to set.

getCountry

public final java.lang.String getCountry()
Return the value/reference of the country.

Returns:
String - The value/reference of country.

setCountry

public final void setCountry(java.lang.String country)
Set the value of country.

Parameters:
country - - The value to set.

Rakesh API

Copyright © 2002-2005 - Rakesh Vidyadharan