id
The id method retrieves the domainMgrId
from the domainMgr table in the NCIM topology database that resides
in the specified domain.
Method Synopsis
id()Parameters
None
Description
The id method
retrieves the domainMgrId from the domainMgr table in the NCIM topology
database that resides in this domain.
Notes
To
ensure that the id method can print appropriate error
and other messages to a log file, you must have previously specified
a log handle (that is, a reference to a file object) by calling the setLogHandle method.
Otherwise, the method sends these messages to STDOUT.
Example Usage
The example that illustrates
a call to the id method is divided into the following
sections:
- Create a new
NCP::Domainobject - Call
idto return the domainMgrId
Create a new NCP::Domain object
The following
code shows a call to the NCP::Domain constructor,
which returns a new NCP::Domain object to the $domain variable.
The name of the domain is specified in $domainName in
the call to the NCP::Domain constructor:
.
.
.
my $domain = new NCP::Domain($domainName, %$ncimArgs);
.
.
.Call id to return the name
of the domain
The following code shows an invocation
of the id method on the NCP::Domain object
($domain->). The id method returns
the domainMgrId to the $domainMgrId variable. Note
that $domainMgrId is used in the call to the dropPollPolicies method.
.
.
.
my $domainMgrId = $domain->id();
.
.
.
dropPollPolicies($ncmonitor, $domainMgrId);
.
.
.
Returns
Upon completion, the id method
returns the domainMgrId.