Package org.netxms.client.snmp
Class SnmpTrap
java.lang.Object
org.netxms.client.snmp.SnmpTrap
Object of this class represents single SNMP trap matching configuration record
-
Constructor Summary
ConstructorsConstructorDescriptionSnmpTrap()Default constructorSnmpTrap(NXCPMessage msg) Create SNMP trap configuration object from NXCP messageSnmpTrap(NXCPMessage msg, long baseId) Create SNMP trap configuration object from summary NXCP message -
Method Summary
Modifier and TypeMethodDescriptionvoidfillMessage(NXCPMessage msg) Fill NXCP message with trap configuration data.intGet event tag to be added when generating NetXMS event.longgetId()Get trap transformation script.voidsetDescription(String description) voidsetEventCode(int eventCode) voidsetEventTag(String eventTag) Set event tag to be added when generating NetXMS event.voidsetId(long id) voidsetObjectId(SnmpObjectId objectId) voidsetTransformationScript(String transformationScript) Set trap transformation script.
-
Constructor Details
-
SnmpTrap
public SnmpTrap()Default constructor -
SnmpTrap
Create SNMP trap configuration object from NXCP message- Parameters:
msg- NXCP message
-
SnmpTrap
Create SNMP trap configuration object from summary NXCP message- Parameters:
msg- NXCP messagebaseId- base field ID
-
-
Method Details
-
fillMessage
Fill NXCP message with trap configuration data.- Parameters:
msg- NXCP message
-
getId
public long getId()- Returns:
- the id
-
setId
public void setId(long id) - Parameters:
id- the id to set
-
getDescription
- Returns:
- the description
-
setDescription
- Parameters:
description- the description to set
-
getObjectId
- Returns:
- the objectId
-
setObjectId
- Parameters:
objectId- the objectId to set
-
getEventCode
public int getEventCode()- Returns:
- the eventCode
-
setEventCode
public void setEventCode(int eventCode) - Parameters:
eventCode- the eventCode to set
-
getEventTag
Get event tag to be added when generating NetXMS event.- Returns:
- event tag to be added when generating NetXMS event.
-
setEventTag
Set event tag to be added when generating NetXMS event.- Parameters:
eventTag- event tag to be added when generating NetXMS event
-
getTransformationScript
Get trap transformation script.- Returns:
- trap transformation script
-
setTransformationScript
Set trap transformation script.- Parameters:
transformationScript- trap transformation script
-
getParameterMapping
- Returns:
- the parameterMapping
-