fwdconfig

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 12, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package fwdconfig contains builders for varius proto types.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionBuilder

type ActionBuilder struct {
	// contains filtered or unexported fields
}

ActionBuilder is a builder for forward action types.

func Action

func Action(adb actionDescBuilder) *ActionBuilder

Action returns a new action builder.

func (*ActionBuilder) Build

func (ab *ActionBuilder) Build() *fwdpb.ActionDesc

Build returns a new action.

func (*ActionBuilder) WithActionDesc

func (ab *ActionBuilder) WithActionDesc(adb actionDescBuilder) *ActionBuilder

WithActionDesc sets the action description

type ActionEntryBuilder

type ActionEntryBuilder struct {
	// contains filtered or unexported fields
}

ActionEntryBuilder builds action table entries.

func ActionEntry

func ActionEntry(id string, insertMethod fwdpb.ActionEntryDesc_InsertMethod) *ActionEntryBuilder

ActionEntry creates a new action entry builder.

type ContinueActionBuilder added in v0.5.0

type ContinueActionBuilder struct{}

ContinueActionBuilder is a builder for a continue action.

func ContinueAction added in v0.5.0

func ContinueAction() *ContinueActionBuilder

ContinueAction returns a new continue action builder.

type DecapActionBuilder

type DecapActionBuilder struct {
	// contains filtered or unexported fields
}

DecapActionBuilder is a builder for a lookup action.

func DecapAction

func DecapAction(header fwdpb.PacketHeaderId) *DecapActionBuilder

LookupAction returns a new lookup action builder.

func (*DecapActionBuilder) WithHeaderID

func (u *DecapActionBuilder) WithHeaderID(header fwdpb.PacketHeaderId) *DecapActionBuilder

WithHeaderID sets the header id.

type DropActionBuilder

type DropActionBuilder struct{}

DropActionBuilder is a builder for a drop action.

func DropAction

func DropAction() *DropActionBuilder

LookupAction returns a new drop action builder.

type EncapActionBuilder

type EncapActionBuilder struct {
	// contains filtered or unexported fields
}

EncapActionBuilder is a builder for a lookup action.

func EncapAction

func EncapAction(header fwdpb.PacketHeaderId) *EncapActionBuilder

LookupAction returns a new lookup action builder.

func (*EncapActionBuilder) WithHeaderID

func (u *EncapActionBuilder) WithHeaderID(header fwdpb.PacketHeaderId) *EncapActionBuilder

WithHeaderID sets the header id.

type EntryDescBuilder

type EntryDescBuilder struct {
	// contains filtered or unexported fields
}

EntryDesc returns a new EntryDescBuilder.

func EntryDesc

func EntryDesc(e entryDescBuilder) *EntryDescBuilder

EntryDesc returns a new EntryDescBuilder.

func (EntryDescBuilder) Build

func (edb EntryDescBuilder) Build() *fwdpb.EntryDesc

Build returns a new EntryDesc.

type ExactEntryBuilder

type ExactEntryBuilder struct {
	// contains filtered or unexported fields
}

ExactEntryBuilder builds exact table entries.

func ExactEntry

func ExactEntry(fields ...*PacketFieldBytesBuilder) *ExactEntryBuilder

ExactEntry creates a new exact entry builder.

type FlowCounterActionBuilder

type FlowCounterActionBuilder struct {
	// contains filtered or unexported fields
}

FlowActionBuilder is a builder for a flow action.

func FlowCounterAction

func FlowCounterAction(id string) *FlowCounterActionBuilder

FlowAction returns a new flow action builder.

type FlowEntryBuilder

type FlowEntryBuilder struct {
	// contains filtered or unexported fields
}

FlowEntryBuilder builds flow table entries.

func FlowEntry

func FlowEntry(fields ...*PacketFieldMaskedBytesBuilder) *FlowEntryBuilder

FlowEntry creates a new flow entry builder.

type LookupActionBuilder

type LookupActionBuilder struct {
	// contains filtered or unexported fields
}

LookupActionBuilder is a builder for a lookup action.

func LookupAction

func LookupAction(tableID string) *LookupActionBuilder

LookupAction returns a new lookup action builder.

func (*LookupActionBuilder) WithTableID

func (u *LookupActionBuilder) WithTableID(id string) *LookupActionBuilder

WithTableID sets the table id.

type PacketFieldBytesBuilder

type PacketFieldBytesBuilder struct {
	// contains filtered or unexported fields
}

PacketFieldBytesBuilder is a builder for PacketFieldBytes.

func PacketFieldBytes

func PacketFieldBytes(field fwdpb.PacketFieldNum) *PacketFieldBytesBuilder

PacketFieldBytes creates a new PacketFieldBytesBuilder

func (*PacketFieldBytesBuilder) Build

Build returns a new PacketFieldBytes.

func (*PacketFieldBytesBuilder) WithBytes

WithBytes sets the bytes value.

func (*PacketFieldBytesBuilder) WithUint16

WithUint16 sets the bytes value with big endian encoded uint.

func (*PacketFieldBytesBuilder) WithUint32

WithUint32 sets the bytes value with big endian encoded uint.

func (*PacketFieldBytesBuilder) WithUint64

WithUint64 sets the bytes value with big endian encoded uint.

type PacketFieldMaskedBytesBuilder

type PacketFieldMaskedBytesBuilder struct {
	// contains filtered or unexported fields
}

PacketFieldMaskedBytesBuilder is a builder for PacketFieldBytes.

func PacketFieldMaskedBytes

func PacketFieldMaskedBytes(field fwdpb.PacketFieldNum) *PacketFieldMaskedBytesBuilder

PacketFieldMaskedBytes creates a new PacketFieldBytesBuilder

func (*PacketFieldMaskedBytesBuilder) Build

Build returns a new PacketFieldMaskedBytes.

func (*PacketFieldMaskedBytesBuilder) WithBytes

WithBytes sets the bytes and mask value.

func (*PacketFieldMaskedBytesBuilder) WithUint16

WithUint16 sets the bytes value with big endian encoded uint and the mask to an exact match.

func (*PacketFieldMaskedBytesBuilder) WithUint32

WithUint32 sets the bytes value with big endian encoded uint and the mask to an exact match.

func (*PacketFieldMaskedBytesBuilder) WithUint64

WithUint64 sets the bytes value with big endian encoded uint and the mask to an exact match.

type PrefixEntryBuilder

type PrefixEntryBuilder struct {
	// contains filtered or unexported fields
}

PrefixEntryBuilder builds prefix table entries.

func PrefixEntry

func PrefixEntry(fields ...*PacketFieldMaskedBytesBuilder) *PrefixEntryBuilder

PrefixEntry creates a new prefix entry builder.

type TableEntryAddRequestBuilder

type TableEntryAddRequestBuilder struct {
	// contains filtered or unexported fields
}

TableEntryAddRequest builds TableEntryAddRequests.

func TableEntryAddRequest

func TableEntryAddRequest(ctxID, tableID string) *TableEntryAddRequestBuilder

TableEntryAddRequest creates a new TableEntryAddRequestBuilder.

func (*TableEntryAddRequestBuilder) AppendActions

AppendEntry adds the actions to the requests.

func (*TableEntryAddRequestBuilder) AppendEntry

AppendEntry adds an entry and the actions to the requests.

func (TableEntryAddRequestBuilder) Build

Build returns a new TableEntryAddRequest.

type TableEntryRemoveRequestBuilder

type TableEntryRemoveRequestBuilder struct {
	// contains filtered or unexported fields
}

TableEntryAddRequest builds TableEntryAddRequests.

func TableEntryRemoveRequest

func TableEntryRemoveRequest(ctxID, tableID string) *TableEntryRemoveRequestBuilder

TableEntryRemoveRequest creates a new TableEntryRemoveRequestBuilder.

func (*TableEntryRemoveRequestBuilder) AppendEntry

AppendEntry adds an entry to the requests.

func (TableEntryRemoveRequestBuilder) Build

Build returns a new TableEntryAddRequest.

type TransmitActionBuilder

type TransmitActionBuilder struct {
	// contains filtered or unexported fields
}

TransmitActionBuilder is a builder for a transmit action.

func TransmitAction

func TransmitAction(portID string) *TransmitActionBuilder

TransmitAction returns a new update action builder.

func (*TransmitActionBuilder) WithImmediate

func (u *TransmitActionBuilder) WithImmediate(immediate bool) *TransmitActionBuilder

WithImmediate sets immediate option value.

func (*TransmitActionBuilder) WithPortID

WithFieldIDNum sets the port id value.

type UpdateActionBuilder

type UpdateActionBuilder struct {
	// contains filtered or unexported fields
}

UpdateActionBuilder is a builder for an update action.

func UpdateAction

UpdateAction returns a new update action builder.

func (*UpdateActionBuilder) WithFieldIDInstance

func (u *UpdateActionBuilder) WithFieldIDInstance(i uint32) *UpdateActionBuilder

WithFieldIDInstance sets the instance of the id num.

func (*UpdateActionBuilder) WithFieldIDNum

WithFieldIDNum sets the packet field id enum.

func (*UpdateActionBuilder) WithFieldSrc

WithUpdateType sets the update source field id.

func (*UpdateActionBuilder) WithFieldSrcInstance

func (u *UpdateActionBuilder) WithFieldSrcInstance(i uint32) *UpdateActionBuilder

WithFieldSrcInstance sets the instance of the src id num.

func (*UpdateActionBuilder) WithUint64Value

func (u *UpdateActionBuilder) WithUint64Value(v uint64) *UpdateActionBuilder

WithUint64Value sets the value to a uint64 value.

func (*UpdateActionBuilder) WithUpdateType

WithUpdateType sets the update type.

func (*UpdateActionBuilder) WithValue

func (u *UpdateActionBuilder) WithValue(v []byte) *UpdateActionBuilder

WithUint64Value sets the value to a byte slice.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL