public class MOColumn<V extends org.snmp4j.smi.Variable> extends Object implements Comparable
MOColumn
class represents columnar SMI objects. It
represents all instances of a table's column not only a single instance
(cell).
Objects represented by MOColumn
cannot be modified via SNMP,
thus MOColumn
supports read-only maximum access only.
MOMutableColumn
Constructor and Description |
---|
MOColumn(int columnID,
int syntax)
Creates a read-only column object with the given column and syntax.
|
MOColumn(int columnID,
int syntax,
MOAccess access)
Creates a column object with the given column, syntax, and maximum access.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Object column)
Compares this managed object column by its ID with another column.
|
void |
get(SubRequest subRequest,
MOTableRow row,
int column) |
MOAccess |
getAccess() |
int |
getColumnID() |
org.snmp4j.smi.Variable |
getRestoreValue(org.snmp4j.smi.Variable[] rowValues,
int column)
Return the restore value for this column and the given row.
|
org.snmp4j.smi.Variable |
getStoreValue(MOTableRow row,
int column)
Return the content of this column's value of the given row for persistent storage.
|
int |
getSyntax() |
MOTable |
getTable() |
V |
getValue(MOTableRow row,
int column) |
boolean |
isVolatile(MOTableRow<V> row,
int column)
Tests if the supplied row is volatile or persistent.
|
void |
setAccess(MOAccess access) |
void |
setColumnID(int columnID) |
void |
setSyntax(int syntax) |
<R extends MOTableRow> |
setTable(MOTable<R,? extends MOColumn,? extends MOTableModel<R>> table)
Sets the table instance this columnar object is contained in.
|
String |
toString() |
public MOColumn(int columnID, int syntax)
columnID
- the column ID which is ID the last sub-identifier of the corresponding
OBJECT-TYPE definition.syntax
- the syntax of the objects in this column. See SMIConstants
for
possible values.public MOColumn(int columnID, int syntax, MOAccess access)
MOColumn
only supports read-only columns the only
reasonable values for access
are 'not-accessible' and
'read-only'. Generally this constructor should not be called directly.columnID
- the column ID which is ID the last sub-indentifer of the corresponding
OBJECT-TYPE definition.syntax
- the syntax of the objects in this column. See SMIConstants
for
possible values.access
- the maximum access of the column.public void setColumnID(int columnID)
public void setSyntax(int syntax)
public void setAccess(MOAccess access)
public <R extends MOTableRow> void setTable(MOTable<R,? extends MOColumn,? extends MOTableModel<R>> table)
MOTable
instance to register the table with
the column.table
- the MOTable
instance where this column is contained in.public int getColumnID()
public int getSyntax()
public MOAccess getAccess()
public MOTable getTable()
public V getValue(MOTableRow row, int column)
public boolean isVolatile(MOTableRow<V> row, int column)
row
- a row of the table where this column is part of.column
- the column index of this column in row
.true
if row
should not bepublic org.snmp4j.smi.Variable getRestoreValue(org.snmp4j.smi.Variable[] rowValues, int column)
rowValues
- a row of the table where this column is part of.column
- the column index of this column in row
.rowValues[column]
.public org.snmp4j.smi.Variable getStoreValue(MOTableRow row, int column)
row
- a row of the table where this column is part of.column
- the column index of this column in row
.row
and column
.public int compareTo(Object column)
compareTo
in interface Comparable
column
- another MOColumn
.public void get(SubRequest subRequest, MOTableRow row, int column)
Copyright © 2016 SNMP4J.org. All rights reserved.