public class VTNMatch extends Object
VTNMatch describes the condition to match against packtes.
Note that this class is not synchronized.
| Modifier and Type | Field and Description |
|---|---|
static String |
COND_KEY_SEPARATOR
A separator used to construct flow condition key.
|
| Constructor and Description |
|---|
VTNMatch()
Create a new flow match that matches every packet.
|
VTNMatch(org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.Match match)
Construct a new flow match from the given
Match instance. |
VTNMatch(VTNEtherMatch ematch,
VTNInetMatch imatch,
VTNLayer4Match l4match)
Construct a new flow match.
|
| Modifier and Type | Method and Description |
|---|---|
void |
complete()
Complete the flow conditions.
|
boolean |
equals(Object o)
Determine whether the given object is identical to this object.
|
String |
getConditionKey()
Create a condition key that identifies this flow match.
|
VTNEtherMatch |
getEtherMatch()
Return the condition against Ethernet header.
|
String |
getFlowKey(SalNode snode,
int pri,
SalPort ingress)
Create a flow condition key that identifies the flow entry.
|
VTNInetMatch |
getInetMatch()
Return the condition against IP header.
|
Short |
getInetProtocol()
Return the IP protocol specified by this match.
|
VTNLayer4Match |
getLayer4Match()
Return the condition against layer 4 protocol header.
|
int |
hashCode()
Return the hash code of this object.
|
boolean |
match(FlowMatchContext ctx)
Determine whether the given packet header matches the condition
specified by this instance.
|
void |
set(VtnMatchFields vmatch)
Set flow conditions configured in the given
VtnMatchFields
instance. |
DataFlowMatchBuilder |
toDataFlowMatchBuilder()
Return a
DataFlowMatchBuilder instance which contains the
flow conditions configured in this instance. |
org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.MatchBuilder |
toMatchBuilder()
Return a
MatchBuilder instance which contains the flow
conditions configured in this instance. |
void |
verify()
Verify the contents of this instance.
|
public static final String COND_KEY_SEPARATOR
public VTNMatch()
public VTNMatch(VTNEtherMatch ematch, VTNInetMatch imatch, VTNLayer4Match l4match) throws RpcException
ematch - A VTNEtherMatch instance which specifies the
condition for Ethernet header.imatch - A VTNInetMatch instance which specifies the
condition for IP header.l4match - A VTNLayer4Match instance which specifies the
condition for layer 4 protocol header.RpcException - The specified condition is invalid.public VTNMatch(org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.Match match)
throws RpcException
Match instance.
Note that this constructor does not complete the condition specified
by the given Match instance.
match - A Match instance.RpcException - match contains invalid value.public final void set(VtnMatchFields vmatch) throws RpcException
VtnMatchFields
instance.
This method completes the condition specified by the given
VtnMatchFields instance. For instance, ethernet type is added
if IP condition is configured in the given VtnMatchFields
instance.
vmatch - A VtnMatchFields instance.NullPointerException - vmatch is null.RpcException - fmatch contains invalid value.public final VTNEtherMatch getEtherMatch()
VTNEtherMatch instance.
null if no condition is specified.public final VTNInetMatch getInetMatch()
VTNInetMatch instance.
null if no condition is specified.public final VTNLayer4Match getLayer4Match()
VTNLayer4Match instance.
null if no condition is specified.public DataFlowMatchBuilder toDataFlowMatchBuilder()
DataFlowMatchBuilder instance which contains the
flow conditions configured in this instance.DataFlowMatchBuilder instance.public final org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.flow.MatchBuilder toMatchBuilder()
MatchBuilder instance which contains the flow
conditions configured in this instance.MatchBuilder instance.public final String getFlowKey(SalNode snode, int pri, SalPort ingress)
public final String getConditionKey()
public void verify()
throws RpcException
RpcException - Verification failed.public final void complete()
throws RpcException
RpcException - This flow match contains inconsistent conditions.public final boolean match(FlowMatchContext ctx)
ctx - A FlowMatchContext instance.true only if the given packet header matches all
the conditions configured in this instance.public final Short getInetProtocol()
Short instance which represents the IP protocol
number if this match specifies the IP protocol.
null if this match does not specify the IP protocol.public boolean equals(Object o)
Copyright © 2018 OpenDaylight. All rights reserved.