Package org.snmp4j.agent.mo
Class MOTableRowEvent<R extends MOTableRow>
java.lang.Object
java.util.EventObject
org.snmp4j.agent.mo.DeniableEventObject
org.snmp4j.agent.mo.MOTableRowEvent<R>
- Type Parameters:
R
- TheMOTable
row type of this event.
- All Implemented Interfaces:
Serializable
The
MOTableRowEvent
class describes the changes- Version:
- 2.2
- Author:
- Frank Fock
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
A row is added.static final int
A single column of a row is changed.static final int
A row is created.static final int
A row is deleted.static final int
This event type indicates that a complete row has been updated.Fields inherited from class java.util.EventObject
source
-
Constructor Summary
ConstructorDescriptionMOTableRowEvent
(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, int type) Creates a table row event based on table, row and type that cannot be canceled by the event listener.MOTableRowEvent
(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, int type, boolean deniable) Creates a table row event based on table, row and type that may be canceled by the event listener depending on the specified flag.MOTableRowEvent
(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, MOTableRow preparedChanges, int type) Creates a table row event based on table, row, prepared changes, and type that cannot be canceled by the event listener.MOTableRowEvent
(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, MOTableRow preparedChanges, int type, boolean deniable) Creates a table row event based on table, row, prepared changes, and type. -
Method Summary
Modifier and TypeMethodDescriptiongetRow()
MOTable<R,
? extends MOColumn, ? extends MOTableModel<R>> getTable()
int
getType()
int
int
Returns the veto status that revokes the row operation or zero if the row operation is accepted by all listeners.void
setVetoColumn
(int vetoColumn) Sets the column index on whose behalf the veto is issued.void
setVetoStatus
(int denyReason) Sets the veto status that revokes the row operation.toString()
Methods inherited from class org.snmp4j.agent.mo.DeniableEventObject
getDenyReason, isDeniable, setDenyReason
Methods inherited from class java.util.EventObject
getSource
-
Field Details
-
CHANGE
public static final int CHANGEA single column of a row is changed.- See Also:
-
CREATE
public static final int CREATEA row is created.- See Also:
-
ADD
public static final int ADDA row is added.- See Also:
-
DELETE
public static final int DELETEA row is deleted.- See Also:
-
UPDATED
public static final int UPDATEDThis event type indicates that a complete row has been updated.- See Also:
-
-
Constructor Details
-
MOTableRowEvent
public MOTableRowEvent(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, int type) Creates a table row event based on table, row and type that cannot be canceled by the event listener.- Parameters:
source
- the event source.table
- the table.row
- the row associated with this event.type
- the event type.
-
MOTableRowEvent
public MOTableRowEvent(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, int type, boolean deniable) Creates a table row event based on table, row and type that may be canceled by the event listener depending on the specified flag.- Parameters:
source
- the event source.table
- the table.row
- the row associated with this event.type
- the event type.deniable
- indicates whether the event can be canceled through setting its denyReason member to a SNMP error status.- Since:
- 1.1
-
MOTableRowEvent
public MOTableRowEvent(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, MOTableRow preparedChanges, int type) Creates a table row event based on table, row, prepared changes, and type that cannot be canceled by the event listener.- Parameters:
source
- the event source.table
- the table.row
- the row associated with this event.preparedChanges
- a row instance containing the prepared changes forrow
.type
- the event type.
-
MOTableRowEvent
public MOTableRowEvent(Object source, MOTable<R, ? extends MOColumn, ? extends MOTableModel<R>> table, R row, MOTableRow preparedChanges, int type, boolean deniable) Creates a table row event based on table, row, prepared changes, and type.- Parameters:
source
- the event source.table
- the table.row
- the row associated with this event.preparedChanges
- a row instance containing the prepared changes forrow
.type
- the event type.deniable
- indicates whether the event can be canceled through setting its denyReason member to a SNMP error status.- Since:
- 1.1
-
-
Method Details
-
getRow
-
getTable
-
getType
public int getType() -
getVetoStatus
public int getVetoStatus()Returns the veto status that revokes the row operation or zero if the row operation is accepted by all listeners.- Returns:
- a SNMP or sub-agent protocol error status or zero if the row operation is accepted.
-
getPreparedChanges
-
getVetoColumn
public int getVetoColumn() -
setVetoStatus
public void setVetoStatus(int denyReason) Sets the veto status that revokes the row operation.- Parameters:
denyReason
- a SNMP error status or a sub-agent protocol specific error status. In any case zero represents no error.
-
setVetoColumn
public void setVetoColumn(int vetoColumn) Sets the column index on whose behalf the veto is issued.- Parameters:
vetoColumn
- a column index.
-
toString
- Overrides:
toString
in classEventObject
-