Cisco::SNMP::Entity - Entity Interface for Cisco Management
use Cisco::SNMP::Entity;
The following methods implement the Entity MIB defined in ENTITY-MIB.
ENTITY-MIB
my $cm = Cisco::SNMP::Entity->new([OPTIONS]);
Create a new Cisco::SNMP::Entity object with OPTIONS as optional parameters. See Cisco::SNMP for options.
my @entityOIDs = $cm->entityOIDs();
Return list of Entity MIB object ID names.
my $entity = $cm->entity_info();
Populate a data structure with entity information. If successful, returns a pointer to an array containing entity information.
$entity->[0]->{'Descr', 'VendorType', ...} $entity->[1]->{'Descr', 'VendorType', ...} ... $entity->[n]->{'Descr', 'VendorType', ...}
Allows the following accessors to be called.
$entity->entityDescr([#]);
Return the description of the entity at index '#'. Defaults to 0.
$entity->entityVendorType([#]);
Return the vendor type of the entity at index '#'. Defaults to 0.
$entity->entityContainedIn([#]);
Return the ContainedIn of the entity at index '#'. Defaults to 0.
$entity->entityClass([#]);
Return the class of the entity at index '#'. Defaults to 0.
$entity->entityParentRelPos([#]);
Return the ParentRelPos of the entity at index '#'. Defaults to 0.
$entity->entityName([#]);
Return the name of the entity at index '#'. Defaults to 0.
$entity->entityHardwareRev([#]);
Return the hardware revision of the entity at index '#'. Defaults to 0.
$entity->entityFirmwareRev([#]);
Return the firmware revision of the entity at index '#'. Defaults to 0.
$entity->entitySoftwareRev([#]);
Return the software revision of the entity at index '#'. Defaults to 0.
$entity->entitySerialNum([#]);
Return the serial number of the entity at index '#'. Defaults to 0.
$entity->entityMfgName([#]);
Return the manufacturer name of the entity at index '#'. Defaults to 0.
$entity->entityModelName([#]);
Return the model name of the entity at index '#'. Defaults to 0.
$entity->entityAlias([#]);
Return the alias of the entity at index '#'. Defaults to 0.
$entity->entityAssetID([#]);
Return the asset ID of the entity at index '#'. Defaults to 0.
$entity->entityIsFRU([#]);
Return the IsFRU of the entity at index '#'. Defaults to 0.
The following methods can be called on the Cisco::SNMP::Entity object directly to access the values directly.
Get Entity OIDs where (#) is the OID instance, not the index from entity_info. If (#) not provided, uses 0.
entity_info
The following are inherited methods. See Cisco::SNMP for more information.
None by default.
This distribution comes with several scripts (installed to the default bin install directory) that not only demonstrate example uses but also provide functional execution.
bin
This software is released under the same terms as Perl itself. If you don't know what that means visit http://perl.com/.
Copyright (C) Michael Vincent 2015
http://www.VinsWorld.com
All rights reserved
To install Cisco::SNMP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Cisco::SNMP
CPAN shell
perl -MCPAN -e shell install Cisco::SNMP
For more information on module installation, please visit the detailed CPAN module installation guide.