org.openflow.protocol.statistics
Class OFFlowStatisticsReply

java.lang.Object
  extended by org.openflow.protocol.statistics.OFFlowStatisticsReply
All Implemented Interfaces:
OFInstructionFactoryAware, OFStatistics

public class OFFlowStatisticsReply
extends java.lang.Object
implements OFStatistics, OFInstructionFactoryAware

Represents an ofp_flow_stats structure

Author:
David Erickson (daviderickson@cs.stanford.edu), Srini Seetharaman (srini.seetharaman@gmail.com)

Field Summary
protected  long byteCount
           
protected  long cookie
           
protected  int durationNanoseconds
           
protected  int durationSeconds
           
protected  short flags
           
protected  short hardTimeout
           
protected  short idleTimeout
           
protected  OFInstructionFactory instructionFactory
           
protected  java.util.List<OFInstruction> instructions
           
protected  short length
           
protected  OFMatch match
           
static int MINIMUM_LENGTH
           
protected  long packetCount
           
protected  short priority
           
protected  byte tableId
           
 
Constructor Summary
OFFlowStatisticsReply()
           
 
Method Summary
 int computeLength()
          Computes, sets and returns the length of this OFStatistics message.
 boolean equals(java.lang.Object obj)
           
 long getByteCount()
           
 long getCookie()
           
 int getDurationNanoseconds()
           
 int getDurationSeconds()
           
 short getFlags()
           
 short getHardTimeout()
           
 short getIdleTimeout()
           
 java.util.List<OFInstruction> getInstructions()
           
 int getLength()
          Returns the wire length of this message in bytes
 OFMatch getMatch()
           
 long getPacketCount()
           
 short getPriority()
           
 byte getTableId()
           
 int hashCode()
           
 void readFrom(java.nio.ByteBuffer data)
          Read this message off the wire from the specified ByteBuffer
 OFFlowStatisticsReply setByteCount(long byteCount)
           
 OFFlowStatisticsReply setCookie(long cookie)
           
 OFFlowStatisticsReply setDurationNanoseconds(int durationNanoseconds)
           
 OFFlowStatisticsReply setDurationSeconds(int durationSeconds)
           
 OFFlowStatisticsReply setFlags(short flags)
           
 OFFlowStatisticsReply setHardTimeout(short hardTimeout)
           
 OFFlowStatisticsReply setIdleTimeout(short idleTimeout)
           
 void setInstructionFactory(OFInstructionFactory instructionFactory)
          Sets the OFInstructionFactory
 OFFlowStatisticsReply setInstructions(java.util.List<OFInstruction> instructions)
           
 void setLength(short length)
           
 OFFlowStatisticsReply setMatch(OFMatch match)
           
 OFFlowStatisticsReply setPacketCount(long packetCount)
           
 OFFlowStatisticsReply setPriority(short priority)
           
 OFFlowStatisticsReply setTableId(byte tableId)
           
 java.lang.String toString()
           
 void updateLength()
           
 void writeTo(java.nio.ByteBuffer data)
          Write this message's binary format to the specified ByteBuffer
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

MINIMUM_LENGTH

public static int MINIMUM_LENGTH

instructionFactory

protected OFInstructionFactory instructionFactory

length

protected short length

tableId

protected byte tableId

durationSeconds

protected int durationSeconds

durationNanoseconds

protected int durationNanoseconds

priority

protected short priority

idleTimeout

protected short idleTimeout

hardTimeout

protected short hardTimeout

flags

protected short flags

cookie

protected long cookie

packetCount

protected long packetCount

byteCount

protected long byteCount

match

protected OFMatch match

instructions

protected java.util.List<OFInstruction> instructions
Constructor Detail

OFFlowStatisticsReply

public OFFlowStatisticsReply()
Method Detail

getTableId

public byte getTableId()
Returns:
the tableId

setTableId

public OFFlowStatisticsReply setTableId(byte tableId)
Parameters:
tableId - the tableId to set

getMatch

public OFMatch getMatch()
Returns:
the match

setMatch

public OFFlowStatisticsReply setMatch(OFMatch match)
Parameters:
match - the match to set

getDurationSeconds

public int getDurationSeconds()
Returns:
the durationSeconds

setDurationSeconds

public OFFlowStatisticsReply setDurationSeconds(int durationSeconds)
Parameters:
durationSeconds - the durationSeconds to set

getDurationNanoseconds

public int getDurationNanoseconds()
Returns:
the durationNanoseconds

setDurationNanoseconds

public OFFlowStatisticsReply setDurationNanoseconds(int durationNanoseconds)
Parameters:
durationNanoseconds - the durationNanoseconds to set

getPriority

public short getPriority()
Returns:
the priority

setPriority

public OFFlowStatisticsReply setPriority(short priority)
Parameters:
priority - the priority to set

getIdleTimeout

public short getIdleTimeout()
Returns:
the idleTimeout

setIdleTimeout

public OFFlowStatisticsReply setIdleTimeout(short idleTimeout)
Parameters:
idleTimeout - the idleTimeout to set

getHardTimeout

public short getHardTimeout()
Returns:
the hardTimeout

setHardTimeout

public OFFlowStatisticsReply setHardTimeout(short hardTimeout)
Parameters:
hardTimeout - the hardTimeout to set

getFlags

public short getFlags()
Returns:
the flags

setFlags

public OFFlowStatisticsReply setFlags(short flags)
Parameters:
flags - the flags to set

getCookie

public long getCookie()
Returns:
the cookie

setCookie

public OFFlowStatisticsReply setCookie(long cookie)
Parameters:
cookie - the cookie to set

getPacketCount

public long getPacketCount()
Returns:
the packetCount

setPacketCount

public OFFlowStatisticsReply setPacketCount(long packetCount)
Parameters:
packetCount - the packetCount to set

getByteCount

public long getByteCount()
Returns:
the byteCount

setByteCount

public OFFlowStatisticsReply setByteCount(long byteCount)
Parameters:
byteCount - the byteCount to set

setLength

public void setLength(short length)
Parameters:
length - the length to set

getLength

public int getLength()
Description copied from interface: OFStatistics
Returns the wire length of this message in bytes

Specified by:
getLength in interface OFStatistics
Returns:
the length

setInstructionFactory

public void setInstructionFactory(OFInstructionFactory instructionFactory)
Description copied from interface: OFInstructionFactoryAware
Sets the OFInstructionFactory

Specified by:
setInstructionFactory in interface OFInstructionFactoryAware
Parameters:
instructionFactory - the instructionFactory to set

getInstructions

public java.util.List<OFInstruction> getInstructions()
Returns:
the instructions

setInstructions

public OFFlowStatisticsReply setInstructions(java.util.List<OFInstruction> instructions)
Parameters:
instructions - the instructions to set

readFrom

public void readFrom(java.nio.ByteBuffer data)
Description copied from interface: OFStatistics
Read this message off the wire from the specified ByteBuffer

Specified by:
readFrom in interface OFStatistics

writeTo

public void writeTo(java.nio.ByteBuffer data)
Description copied from interface: OFStatistics
Write this message's binary format to the specified ByteBuffer

Specified by:
writeTo in interface OFStatistics

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

updateLength

public void updateLength()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

computeLength

public int computeLength()
Description copied from interface: OFStatistics
Computes, sets and returns the length of this OFStatistics message. The value will be able to be retrieved from OFStatistics.getLength() without recomputing after this method is called.

Specified by:
computeLength in interface OFStatistics
Returns: