org.opennms.netmgt.xml.eventconf
Class Snmp

java.lang.Object
  extended by org.opennms.netmgt.xml.eventconf.Snmp
All Implemented Interfaces:
Serializable

public class Snmp
extends Object
implements Serializable

The snmp information from the trap

Version:
$Revision$ $Date$
See Also:
Serialized Form

Constructor Summary
Snmp()
           
 
Method Summary
 void deleteGeneric()
           
 void deleteSpecific()
           
 String getCommunity()
          Returns the value of field 'community'.
 int getGeneric()
          Returns the value of field 'generic'.
 String getId()
          Returns the value of field 'id'.
 String getIdtext()
          Returns the value of field 'idtext'.
 int getSpecific()
          Returns the value of field 'specific'.
 String getVersion()
          Returns the value of field 'version'.
 boolean hasGeneric()
          Method hasGeneric.
 boolean hasSpecific()
          Method hasSpecific.
 boolean isValid()
          Method isValid.
 void marshal(ContentHandler handler)
           
 void marshal(Writer out)
           
 void setCommunity(String community)
          Sets the value of field 'community'.
 void setGeneric(int generic)
          Sets the value of field 'generic'.
 void setId(String id)
          Sets the value of field 'id'.
 void setIdtext(String idtext)
          Sets the value of field 'idtext'.
 void setSpecific(int specific)
          Sets the value of field 'specific'.
 void setVersion(String version)
          Sets the value of field 'version'.
static Snmp unmarshal(Reader reader)
          Method unmarshal.
 void validate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Snmp

public Snmp()
Method Detail

deleteGeneric

public void deleteGeneric()

deleteSpecific

public void deleteSpecific()

getCommunity

public String getCommunity()
Returns the value of field 'community'. The field 'community' has the following description: The community name

Returns:
the value of field 'Community'.

getGeneric

public int getGeneric()
Returns the value of field 'generic'. The field 'generic' has the following description: The generic trap number

Returns:
the value of field 'Generic'.

getId

public String getId()
Returns the value of field 'id'. The field 'id' has the following description: The snmp enterprise id

Returns:
the value of field 'Id'.

getIdtext

public String getIdtext()
Returns the value of field 'idtext'. The field 'idtext' has the following description: The snmp enterprise id text

Returns:
the value of field 'Idtext'.

getSpecific

public int getSpecific()
Returns the value of field 'specific'. The field 'specific' has the following description: The specific trap number

Returns:
the value of field 'Specific'.

getVersion

public String getVersion()
Returns the value of field 'version'. The field 'version' has the following description: The snmp version

Returns:
the value of field 'Version'.

hasGeneric

public boolean hasGeneric()
Method hasGeneric.

Returns:
true if at least one Generic has been added

hasSpecific

public boolean hasSpecific()
Method hasSpecific.

Returns:
true if at least one Specific has been added

isValid

public boolean isValid()
Method isValid.

Returns:
true if this object is valid according to the schema

marshal

public void marshal(Writer out)
             throws org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
out -
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

marshal

public void marshal(ContentHandler handler)
             throws IOException,
                    org.exolab.castor.xml.MarshalException,
                    org.exolab.castor.xml.ValidationException
Parameters:
handler -
Throws:
IOException - if an IOException occurs during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling

setCommunity

public void setCommunity(String community)
Sets the value of field 'community'. The field 'community' has the following description: The community name

Parameters:
community - the value of field 'community'.

setGeneric

public void setGeneric(int generic)
Sets the value of field 'generic'. The field 'generic' has the following description: The generic trap number

Parameters:
generic - the value of field 'generic'.

setId

public void setId(String id)
Sets the value of field 'id'. The field 'id' has the following description: The snmp enterprise id

Parameters:
id - the value of field 'id'.

setIdtext

public void setIdtext(String idtext)
Sets the value of field 'idtext'. The field 'idtext' has the following description: The snmp enterprise id text

Parameters:
idtext - the value of field 'idtext'.

setSpecific

public void setSpecific(int specific)
Sets the value of field 'specific'. The field 'specific' has the following description: The specific trap number

Parameters:
specific - the value of field 'specific'.

setVersion

public void setVersion(String version)
Sets the value of field 'version'. The field 'version' has the following description: The snmp version

Parameters:
version - the value of field 'version'.

unmarshal

public static Snmp unmarshal(Reader reader)
                      throws org.exolab.castor.xml.MarshalException,
                             org.exolab.castor.xml.ValidationException
Method unmarshal.

Parameters:
reader -
Returns:
the unmarshaled org.opennms.netmgt.xml.eventconf.Snmp
Throws:
org.exolab.castor.xml.MarshalException - if object is null or if any SAXException is thrown during marshaling
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema

validate

public void validate()
              throws org.exolab.castor.xml.ValidationException
Throws:
org.exolab.castor.xml.ValidationException - if this object is an invalid instance according to the schema


Copyright ? 2008. All Rights Reserved.