NAME

Liz::OCASet::Address - generic module for Address objects


SYNOPSIS

 use xxLINK;
 $xxlink = new xxLINK;
 $ocaset = $xxlink->OCASet( 'customers' );
 
 $address = $ocaset->Address;
 $address = $ocaset->Address( $addressID );

 $street = $address->Street;
 $zipcode = $address->ZipCode;
 $city = $address->City;
 $state = $address->State;
 $country = $address->Country;

 $addressID = $address->update;


DESCRIPTION

Provide object oriented access to the Address opbject of the Liz::OCASet module family. Usually not accessed directly, but rather through a client module.


BASIC METHODS


new

Create a new Address object from a client module object.

Input Parameters

 1 Liz::SQL object
 2 ID to created Address object with
Output Parameters

 1 instantiated object
Note

It is not intended to call this method directly, but rather indirectly through a client module.

Example

 $xxlink = new xxLINK;
 $ocaset = $xxlink->OCASet( 'customers' );
 $address = $ocaset->Address;
 $address = $ocaset->Address( $addressID );


update

Update a Address object in the database.

Output Parameters

 1 ID with which the object was updated (undef = error)
Example

 $address->update;


CONTENT METHODS

The following methods allow you to change the fields associated with the Liz::OCASet::Address object.


City

Return or set the City information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the City
   (default: no change)
Output Parameters

 1 current/old name of the City
Example

 $address->City( 'Amsterdam' );
 $city = $address->City;


Country

Return or set the Country information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the Country
   (default: no change)
Output Parameters

 1 current/old name of the Country
Example

 $address->Country( 'The Netherlands' );
 $country = $address->Country;


Created

Return the Created information of the Liz::OCASet::Address object.

Output Parameters

 1 current timestamp of the Created
Example

 $created = $address->Created;


Data

Return or set the Data information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the Data
   (default: no change)
Output Parameters

 1 current/old name of the Data
Example

 $address->Data( Scalars2Hash( qw($aap $noot $mies) ) );
 Hash2Scalars( $address->Data );


IP

Return the IP number from where the object was last edited.

Output Parameters

 1 IP-number where record was last edited
Example

 $ip = $contact->IP;


Options

Return or set the Options information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the Options
   (default: no change)
Output Parameters

 1 current/old name of the Options
Example

 $address->Options( 'ACF' );
 $options = $address->Options;


State

Return or set the State information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the State
   (default: no change)
Output Parameters

 1 current/old name of the State
Example

 $address->State( 'Illinois' );
 $state = $address->State;


Status

Return or set the Status information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the Status
   (default: no change)
Output Parameters

 1 current/old name of the Status
Example

 $address->Status( 1 );
 $status = $address->Status;


Street

Return or set the Street information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the Street
   (default: no change)
Output Parameters

 1 current/old name of the Street
Example

 $address->Street( 'Admiralengracht 281-3' );
 $street = $address->Street;


Updated

Return the Updated information of the Liz::OCASet::Address object.

Output Parameters

 1 current timestamp of the Updated
Example

 $updated = $address->Updated;


ZipCode

Return or set the ZipCode information of the Liz::OCASet::Address object.

Input Parameters

 1 new name of the ZipCode
   (default: no change)
Output Parameters

 1 current/old name of the ZipCode
Example

 $address->ZipCode( '1056 EA' );
 $zipcode = $address->ZipCode;


AUTHOR

Elizabeth Mattijsen ( lizperl@INC.nl )


COPYRIGHT

(C) 1998-1999 International Network Consultants


HISTORY

Version 0.18, 30 September 1999

Now no longer adds Exporter to ISA: it wasn't necessary.

Version 0.17, 24 July 1999

Removed inheritance of EXTRAFIELDS_ALPHA and EXTRAFIELDS_NUMERIC from method new as they are not necessary and actually cause problems.

Version 0.16, 12 May 1999

Adapted method new so that the global variable $ERROR will be set with an error message if obtaining of an existing record failed.

Updated methods new and update so that this module can be sub-classed with extra fields.

Changed the typography of this module to the new indented format.

Version 0.15, 27 April 1999

Fixed problem in method update which would not return the ID of the object if the object was not changed.

Version 0.14, 3 April 1999

Added support for the IP method, which returns the IP-number from which the record was created or last changed.

Added support for the IP field in the database structure.

Version 0.13, 2 April 1999

Some cosmetic changes to the source to make it more in line with the Contact and Organization modules.

Version 0.12, 30 November 1998

Now uses the field ``TOKEN'' and the internal subroutine RawTableName to create the database table name.

Internal subroutine RawTableName added.

Version 0.11, 6 October 1998

Reduced memory footprint by using fully qualified global variables only.

Version 0.1, 17 September 1998

First version of this true Perl module. Based on version .3 of the HN::Address module.