Package Products :: Package DataCollector :: Module ApplyDataMap :: Class ApplyDataMap |
[hide private]
[frames] | no frames]

# Class ApplyDataMap

source code

    object --+
             |
            ApplyDataMap

Known Subclasses:
  - ApplyDataMapThread

Instance Methods | [hide private]
__init__(self, datacollector=None) | source code
logChange(self, device, compname, eventClass, msg) | source code
logEvent(self, device, component, eventClass, msg, severity) Used to report a change to a device model. | source code
processClient(self, device, collectorClient) A modeler plugin specifies the protocol (eg SNMP, WMI) and the specific data to retrieve from the device (eg an OID). | source code
applyDataMap(self, device, datamap, relname="", compname="", modname="") Apply a datamap passed as a list of dicts through XML-RPC. | source code
setDeviceClass(self, device, deviceClass=None) If a device class has been passed and the current class is not /Classifier then move the device to the newly clssified device class. | source code
_applyDataMap(self, device, datamap) Apply a datamap to a device. | source code
_updateRelationship(self, device, relmap) Add/Update/Remote objects to the target relationship. | source code
_updateObject(self, obj, objmap) Update an object using a objmap. | source code
_createRelObject(self, device, objmap, relname) Create an object on a relationship using its objmap. | source code
stop(self) | source code

Method Details | [hide private]

### __init__(self, datacollector=None) (Constructor) | source code
Overrides: object.__init__ (inherited documentation)

### logEvent(self, device, component, eventClass, msg, severity) | source code
Used to report a change to a device model. Logs the given msg to log.info and creates an event.

### processClient(self, device, collectorClient) | source code
A modeler plugin specifies the protocol (eg SNMP, WMI) and the specific data to retrieve from the device (eg an OID). This data is then processed by the modeler plugin and then passed to this method to apply the results to the ZODB. Parameters: `device` (DMD device object) - DMD device object `collectorClient` (DMD object) - results of modeling

### _applyDataMap(self, device, datamap) | source code
Apply a datamap to a device. Decorators: `@transact`