public final class BitmaskOperandParser extends AbstractOperandParser<BitmaskOperand>
Modifier and Type | Field and Description |
---|---|
static BitmaskOperandParser |
INSTANCE |
static String |
MATCH_VALUE |
static String |
NOT_VALUE |
AND_BIT, AND_BIT_VALUE, END_OF_LIST, END_OF_LIST_VALUE, LENGTH_SHIFT, OPERAND_LENGTH
Modifier and Type | Method and Description |
---|---|
BitmaskOperand |
create(Set<String> opValues)
Creates operand from a set of operand values.
|
BitmaskOperand |
parse(byte op)
Parses operand from byte value.
|
void |
serialize(BitmaskOperand op,
int length,
boolean endOfList,
io.netty.buffer.ByteBuf buffer)
Serializes operand to bytes.
|
String |
toString(BitmaskOperand op,
boolean isFirst)
Creates a string representation of the operand.
|
parseLength
public static final BitmaskOperandParser INSTANCE
public static final String MATCH_VALUE
public static final String NOT_VALUE
public BitmaskOperand create(Set<String> opValues)
AbstractOperandParser
create
in class AbstractOperandParser<BitmaskOperand>
opValues
- set of operand valuespublic void serialize(BitmaskOperand op, int length, boolean endOfList, io.netty.buffer.ByteBuf buffer)
AbstractOperandParser
serialize
in class AbstractOperandParser<BitmaskOperand>
op
- operand to be serializedlength
- value of the 'length' fieldendOfList
- if this operand is at the end of the listbuffer
- where the operand will be serialized topublic BitmaskOperand parse(byte op)
AbstractOperandParser
parse
in class AbstractOperandParser<BitmaskOperand>
op
- byte representation of an operandpublic String toString(BitmaskOperand op, boolean isFirst)
AbstractOperandParser
toString
in class AbstractOperandParser<BitmaskOperand>
op
- operandisFirst
- true if this operand is the first in list of operandsCopyright © 2019 OpenDaylight. All rights reserved.