public class OfmMutablePortMod extends OfmPortMod implements MutableMessage
OfmPortMod
.length
Modifier and Type | Method and Description |
---|---|
OfmMutablePortMod |
advertise(Set<PortFeature> features)
Sets the features of this port to advertise; Since 1.0.
|
void |
clearXid()
Clears the transaction ID field of this message (sets it to 0).
|
OfmMutablePortMod |
config(Set<PortConfig> flags)
Sets the configuration flags to apply; Since 1.0.
|
OfmMutablePortMod |
configMask(Set<PortConfig> mask)
Sets the configuration flags mask to apply; Since 1.0.
|
OfmMutablePortMod |
hwAddress(MacAddress hwAddress)
Sets the hardware address to sanity check against; Since 1.0.
|
OfmMutablePortMod |
port(BigPortNumber port)
Sets the id of the port to be modified; Since 1.0.
|
OpenflowMessage |
toImmutable()
Returns an immutable instance of this message.
|
String |
toString() |
boolean |
writable()
Returns true if this mutable object is still writable.
|
getAdvertise, getConfig, getConfigMask, getHwAddress, getPort, toDebugString
decodeHeader, getType, getVersion, getXid, hex, hex, length, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getVersion, toDebugString
public void clearXid()
MutableMessage
clearXid
in interface MutableMessage
public OpenflowMessage toImmutable()
MutableMessage
It is expected that the reference to this mutable message will be
dropped. Note that all method calls invoked on a
MutableMessage
after toImmutable()
has been invoked
will result in an InvalidMutableException
being thrown.
toImmutable
in interface MutableMessage
public boolean writable()
MutableObject
#toImmutable()
method (defined on a sub-interface)
has not yet been invoked.writable
in interface MutableObject
public String toString()
toString
in class OfmPortMod
public OfmMutablePortMod port(BigPortNumber port)
Note that in 1.0, port numbers are u16.
port
- the port numberInvalidMutableException
- if this instance is no longer writableNullPointerException
- if port is nullIllegalArgumentException
- if the port number is invalidpublic OfmMutablePortMod hwAddress(MacAddress hwAddress)
The hardware address is not configurable. This is used to sanity-check
the request, so it must be the same as returned in a
Port
structure.
hwAddress
- the hardware addressInvalidMutableException
- if this instance is no longer writableNullPointerException
- if port is nullpublic OfmMutablePortMod config(Set<PortConfig> flags)
flags
- the configuration flagsInvalidMutableException
- if this instance is no longer writableNullPointerException
- if flags is nullpublic OfmMutablePortMod configMask(Set<PortConfig> mask)
mask
- the configuration flags maskInvalidMutableException
- if this instance is no longer writablepublic OfmMutablePortMod advertise(Set<PortFeature> features)
features
- the port features to advertiseInvalidMutableException
- if this instance is no longer writableCopyright © 2015. All Rights Reserved.