% include( '/elements/header.html', 'Developer Documentation' ) %> <& /elements/menubar.html, 'Freeside Perl Modules' => $fsurl.'docs/library/FS.html', 'Complete Index' => $fsurl.'docs/library/index.html', &>
FS::tower - Object methods for tower records
use FS::tower;
$record = new FS::tower \%hash;
$record = new FS::tower { 'column' => 'value' };
$error = $record->insert;
$error = $new_record->replace($old_record);
$error = $record->delete;
$error = $record->check;
An FS::tower object represents a tower. FS::tower inherits from FS::Record. The following fields are currently supported:
primary key
Tower name
Disabled flag, empty or 'Y'
Up Rate limit for towner
Down Rate limit for tower
Creates a new tower. To add the tower to the database, see "insert".
Note that this stores the hash reference, not a distinct copy of the hash it points to. You can ask the object for a copy with the hash method.
Adds this record to the database. If there is an error, returns the error, otherwise returns false.
Delete this record from the database.
Replaces the OLD_RECORD with this one in the database. If there is an error, returns the error, otherwise returns false.
Checks all fields to make sure this is a valid tower. If there is an error, returns the error, otherwise returns false. Called by the insert and replace methods.
Returns the default sector.
Returns the sectors of this tower, as FS::tower_sector objects (see FS::tower_sector), except for the default sector.
Wrapper for the default method (see FS::o2m_Common) to manage the default sector.