AdventNet Web NMS 4 API Specification

com.adventnet.management.config.xml
Class DeviceResult

java.lang.Object
  |
  +--com.adventnet.management.config.xml.BaseElement
        |
        +--com.adventnet.management.config.xml.DeviceResult
All Implemented Interfaces:
java.io.Serializable

public class DeviceResult
extends BaseElement

This class represents the configuration status of the device associated with the task.

Sample Configuration Result:

<?xml version="1.0" encoding="ISO-8859-1"?>
<ConfigResult taskName="SystemConfig" rollbackEnabled="false">
<DeviceResult deviceName="192.168.4.19" configuration="Attempted">
<AttributeResult identifier="1.6.0" label="sysLocation" errorStatus="0" message="Success"/>
</DeviceResult>
<DeviceResult deviceName="192.168.4.24" configuration="Attempted">
<AttributeResult identifier="1.6.0" label="sysLocation" errorStatus="0" message="Success"/>
</DeviceResult>

</ConfigResult>

See Also:
ConfigResult, AttributeResult, Serialized Form

Fields inherited from class com.adventnet.management.config.xml.BaseElement
element, isServer
 
Constructor Summary
DeviceResult(org.w3c.dom.Element element)
          Creates a DeviceList from the XML Element.
DeviceResult(java.lang.String taskName, java.lang.String subTaskName, java.lang.String deviceName, AttributeResult[] attributeResults)
          Creates a new DeviceResult instance.
 
Method Summary
 AttributeResult[] getAttributeResults()
          Returns the result of configuration for each attribute.
 java.lang.String getDeviceName()
          Returns the name of the Device that has been configured.
 java.lang.String getRollbackStatus()
          Returns the status of the rollback for this device.
 java.lang.String getSubTaskName()
          Returns the name of the SubTask( in a CombinedTask ) whose attributes has been configured for the device.
 java.lang.String getTaskName()
          Returns the name of the task that has been executed for the device.
 boolean isConfigurationAttempted()
          Returns true if configuration is attempted for this device, otherwise false.
 boolean isRollbackAttempted()
          Returns true if rollback is attempted for this device, otherwise false.
 
Methods inherited from class com.adventnet.management.config.xml.BaseElement
addSubTag, getAttribute, getElement, getProperties, getSubTagsByName, hasAttribute, removeSubTagsByName, setAttribute, setProperties, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DeviceResult

public DeviceResult(org.w3c.dom.Element element)
             throws InvalidTemplateException
Creates a DeviceList from the XML Element.
Parameters:
element - represents the DeviceList.
Throws:
InvalidTemplateException - if the element passed is invalid

DeviceResult

public DeviceResult(java.lang.String taskName,
                    java.lang.String subTaskName,
                    java.lang.String deviceName,
                    AttributeResult[] attributeResults)
Creates a new DeviceResult instance.
Parameters:
taskName - the name of the task which is configured over this device.
subTaskName - name of the subtask present in a combined task.
deviceName - name of the configured device.
attributeResults - result of the Configured Attributes defined in a Task.
Method Detail

getTaskName

public java.lang.String getTaskName()
Returns the name of the task that has been executed for the device.
Returns:
task's name.

getSubTaskName

public java.lang.String getSubTaskName()
Returns the name of the SubTask( in a CombinedTask ) whose attributes has been configured for the device.
Returns:
SubTask's name

getDeviceName

public java.lang.String getDeviceName()
Returns the name of the Device that has been configured.
Returns:
device's name

getRollbackStatus

public java.lang.String getRollbackStatus()
Returns the status of the rollback for this device. If rollback is not specified or applied ,it returns a value of NULL.
Returns:
the rollbackStatus of the device.

isConfigurationAttempted

public boolean isConfigurationAttempted()
Returns true if configuration is attempted for this device, otherwise false.
Returns:
true if Configuration has been attempted, else false.

isRollbackAttempted

public boolean isRollbackAttempted()
Returns true if rollback is attempted for this device, otherwise false.
Returns:
true if Rollback has been attempted, else false.

getAttributeResults

public AttributeResult[] getAttributeResults()
Returns the result of configuration for each attribute.
Returns:
an AttributeResult[] value

AdventNet Web NMS 4 API Specification