Documentation
¶
Overview ¶
Package fwdflowcounter implements the functionality of Flow Counters. Flow Counters are objects that are managed by the client. They track the number of packets and octets that match each row in the flow table.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FlowCounter ¶
FlowCounter implements the per flow counter.
func Acquire ¶
func Acquire(ctx *fwdcontext.Context, id *fwdpb.FlowCounterId) (*FlowCounter, error)
Acquire acquires a reference to a FlowCounter.
func New ¶
func New(ctx *fwdcontext.Context, req *fwdpb.FlowCounterCreateRequest) (*FlowCounter, error)
New is used to create a per flow counter, which will store byte and packet counts.
func (*FlowCounter) Process ¶
func (fc *FlowCounter) Process(octetCount, packetCount uint32) error
Process is used to process a packet and increment the octet and packet counts.
func (*FlowCounter) Query ¶
func (fc *FlowCounter) Query() (*fwdpb.FlowCounter, error)
Query is used to read out the packet and octet counts stored in flow counters.
func (*FlowCounter) String ¶
func (fc *FlowCounter) String() string
String method formats the FlowCounter.
Click to show internal directories.
Click to hide internal directories.