NAME

FS::nas - Object methods for nas records


SYNOPSIS

  use FS::nas;
  $record = new FS::nas \%hash;
  $record = new FS::nas {
    'nasnum'  => 1,
    'nasip'   => '10.4.20.23',
    'nasfqdn' => 'box1.brc.nv.us.example.net',
  };
  $error = $record->insert;
  $error = $new_record->replace($old_record);
  $error = $record->delete;
  $error = $record->check;
  $error = $record->heartbeat($timestamp);


DESCRIPTION

An FS::nas object represents an Network Access Server on your network, such as a terminal server or equivalent. FS::nas inherits from FS::Record. The following fields are currently supported:

nasnum - primary key
nas - NAS name
nasip - NAS ip address
nasfqdn - NAS fully-qualified domain name
last - timestamp indicating the last instant the NAS was in a known state (used by the session monitoring).


METHODS

new HASHREF
Creates a new NAS. To add the NAS 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.

insert
Adds this record to the database. If there is an error, returns the error, otherwise returns false.

delete
Delete this record from the database.

replace OLD_RECORD
Replaces the OLD_RECORD with this one in the database. If there is an error, returns the error, otherwise returns false.

check
Checks all fields to make sure this is a valid example. If there is an error, returns the error, otherwise returns false. Called by the insert and replace methods.

heartbeat TIMESTAMP
Updates the timestamp for this nas


VERSION

$Id: nas.html,v 1.3 2002-01-29 17:42:46 ivan Exp $


BUGS


SEE ALSO

the FS::Record manpage, schema.html from the base documentation.