org.openflow.vendor.openflow
Class OFQueueVendorData

java.lang.Object
  extended by org.openflow.vendor.openflow.OFOpenFlowVendorData
      extended by org.openflow.vendor.openflow.OFQueueVendorData
All Implemented Interfaces:
OFVendorData
Direct Known Subclasses:
OFQueueDeleteVendorData, OFQueueModifyVendorData

public class OFQueueVendorData
extends OFOpenFlowVendorData

Class that represents the vendor data in a queue modify or delete request

Author:
Andrew Ferguson (adf@cs.brown.edu)

Field Summary
static int MINIMUM_LENGTH
           
protected  int portNumber
           
protected  java.util.List<OFPacketQueue> queues
           
 
Fields inherited from class org.openflow.vendor.openflow.OFOpenFlowVendorData
dataType, OF_VENDOR_ID
 
Constructor Summary
OFQueueVendorData(int dataType)
           
 
Method Summary
 int getLength()
          Get the length of the vendor data.
 int getPortNumber()
           
 java.util.List<OFPacketQueue> getQueues()
           
 void readFrom(java.nio.ByteBuffer data, int length)
          Read the queue message data from the ByteBuffer
 void setPortNumber(int portNumber)
           
 void setQueues(java.util.List<OFPacketQueue> queues)
           
 void writeTo(java.nio.ByteBuffer data)
          Write the queue message data to the ByteBuffer
 
Methods inherited from class org.openflow.vendor.openflow.OFOpenFlowVendorData
getDataType, setDataType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MINIMUM_LENGTH

public static int MINIMUM_LENGTH

portNumber

protected int portNumber

queues

protected java.util.List<OFPacketQueue> queues
Constructor Detail

OFQueueVendorData

public OFQueueVendorData(int dataType)
Method Detail

getPortNumber

public int getPortNumber()
Returns:
the portNumber

setPortNumber

public void setPortNumber(int portNumber)
Parameters:
port - the port on which the queue is

getQueues

public java.util.List<OFPacketQueue> getQueues()
Returns:
the queues

setQueues

public void setQueues(java.util.List<OFPacketQueue> queues)
Parameters:
queues - the queues to modify or delete

getLength

public int getLength()
Description copied from class: OFOpenFlowVendorData
Get the length of the vendor data. This implementation will normally be the superclass for another class that will override this to return the overall vendor data length. This implementation just returns the length of the part that includes the 4-byte integer data type value at the beginning of the vendor data.

Specified by:
getLength in interface OFVendorData
Overrides:
getLength in class OFOpenFlowVendorData
Returns:
the total length of the queue modify or delete msg

readFrom

public void readFrom(java.nio.ByteBuffer data,
                     int length)
Read the queue message data from the ByteBuffer

Specified by:
readFrom in interface OFVendorData
Overrides:
readFrom in class OFOpenFlowVendorData
Parameters:
data - the channel buffer from which we're deserializing
length - the length to the end of the enclosing message

writeTo

public void writeTo(java.nio.ByteBuffer data)
Write the queue message data to the ByteBuffer

Specified by:
writeTo in interface OFVendorData
Overrides:
writeTo in class OFOpenFlowVendorData
Parameters:
data - the channel buffer to which we're serializing