policer

package
v0.0.0-...-f91f7f2 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package policer is a generated VPP binary API for 'policer' module.

It consists of:

4 enums
1 type
4 messages
2 services

Index

Constants

View Source
const (
	// ModuleName is the name of this module.
	ModuleName = "policer"
	// APIVersion is the API version of this module.
	APIVersion = "2.0.0"
	// VersionCrc is the CRC of this module.
	VersionCrc = 0xd9188811
)

Variables

View Source
var Sse2QosActionType_name = map[uint8]string{
	0: "SSE2_QOS_ACTION_API_DROP",
	1: "SSE2_QOS_ACTION_API_TRANSMIT",
	2: "SSE2_QOS_ACTION_API_MARK_AND_TRANSMIT",
}
View Source
var Sse2QosActionType_value = map[string]uint8{
	"SSE2_QOS_ACTION_API_DROP":              0,
	"SSE2_QOS_ACTION_API_TRANSMIT":          1,
	"SSE2_QOS_ACTION_API_MARK_AND_TRANSMIT": 2,
}
View Source
var Sse2QosPolicerType_name = map[uint8]string{
	0: "SSE2_QOS_POLICER_TYPE_API_1R2C",
	1: "SSE2_QOS_POLICER_TYPE_API_1R3C_RFC_2697",
	2: "SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_2698",
	3: "SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_4115",
	4: "SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_MEF5CF1",
	5: "SSE2_QOS_POLICER_TYPE_API_MAX",
}
View Source
var Sse2QosPolicerType_value = map[string]uint8{
	"SSE2_QOS_POLICER_TYPE_API_1R2C":             0,
	"SSE2_QOS_POLICER_TYPE_API_1R3C_RFC_2697":    1,
	"SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_2698":    2,
	"SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_4115":    3,
	"SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_MEF5CF1": 4,
	"SSE2_QOS_POLICER_TYPE_API_MAX":              5,
}
View Source
var Sse2QosRateType_name = map[uint8]string{
	0: "SSE2_QOS_RATE_API_KBPS",
	1: "SSE2_QOS_RATE_API_PPS",
	2: "SSE2_QOS_RATE_API_INVALID",
}
View Source
var Sse2QosRateType_value = map[string]uint8{
	"SSE2_QOS_RATE_API_KBPS":    0,
	"SSE2_QOS_RATE_API_PPS":     1,
	"SSE2_QOS_RATE_API_INVALID": 2,
}
View Source
var Sse2QosRoundType_name = map[uint8]string{
	0: "SSE2_QOS_ROUND_API_TO_CLOSEST",
	1: "SSE2_QOS_ROUND_API_TO_UP",
	2: "SSE2_QOS_ROUND_API_TO_DOWN",
	3: "SSE2_QOS_ROUND_API_INVALID",
}
View Source
var Sse2QosRoundType_value = map[string]uint8{
	"SSE2_QOS_ROUND_API_TO_CLOSEST": 0,
	"SSE2_QOS_ROUND_API_TO_UP":      1,
	"SSE2_QOS_ROUND_API_TO_DOWN":    2,
	"SSE2_QOS_ROUND_API_INVALID":    3,
}

Functions

func AllMessages

func AllMessages() []api.Message

Messages returns list of all messages in this module.

Types

type PolicerAddDel

type PolicerAddDel struct {
	IsAdd         bool
	Name          string `struc:"[64]byte"`
	Cir           uint32
	Eir           uint32
	Cb            uint64
	Eb            uint64
	RateType      Sse2QosRateType
	RoundType     Sse2QosRoundType
	Type          Sse2QosPolicerType
	ColorAware    bool
	ConformAction Sse2QosAction
	ExceedAction  Sse2QosAction
	ViolateAction Sse2QosAction
}

PolicerAddDel represents VPP binary API message 'policer_add_del'.

func (*PolicerAddDel) GetCrcString

func (*PolicerAddDel) GetCrcString() string

func (*PolicerAddDel) GetMessageName

func (*PolicerAddDel) GetMessageName() string

func (*PolicerAddDel) GetMessageType

func (*PolicerAddDel) GetMessageType() api.MessageType

func (*PolicerAddDel) Reset

func (m *PolicerAddDel) Reset()

type PolicerAddDelReply

type PolicerAddDelReply struct {
	Retval       int32
	PolicerIndex uint32
}

PolicerAddDelReply represents VPP binary API message 'policer_add_del_reply'.

func (*PolicerAddDelReply) GetCrcString

func (*PolicerAddDelReply) GetCrcString() string

func (*PolicerAddDelReply) GetMessageName

func (*PolicerAddDelReply) GetMessageName() string

func (*PolicerAddDelReply) GetMessageType

func (*PolicerAddDelReply) GetMessageType() api.MessageType

func (*PolicerAddDelReply) Reset

func (m *PolicerAddDelReply) Reset()

type PolicerDetails

type PolicerDetails struct {
	Name               string `struc:"[64]byte"`
	Cir                uint32
	Eir                uint32
	Cb                 uint64
	Eb                 uint64
	RateType           Sse2QosRateType
	RoundType          Sse2QosRoundType
	Type               Sse2QosPolicerType
	ConformAction      Sse2QosAction
	ExceedAction       Sse2QosAction
	ViolateAction      Sse2QosAction
	SingleRate         bool
	ColorAware         bool
	Scale              uint32
	CirTokensPerPeriod uint32
	PirTokensPerPeriod uint32
	CurrentLimit       uint32
	CurrentBucket      uint32
	ExtendedLimit      uint32
	ExtendedBucket     uint32
	LastUpdateTime     uint64
}

PolicerDetails represents VPP binary API message 'policer_details'.

func (*PolicerDetails) GetCrcString

func (*PolicerDetails) GetCrcString() string

func (*PolicerDetails) GetMessageName

func (*PolicerDetails) GetMessageName() string

func (*PolicerDetails) GetMessageType

func (*PolicerDetails) GetMessageType() api.MessageType

func (*PolicerDetails) Reset

func (m *PolicerDetails) Reset()

type PolicerDump

type PolicerDump struct {
	MatchNameValid bool
	MatchName      string `struc:"[64]byte"`
}

PolicerDump represents VPP binary API message 'policer_dump'.

func (*PolicerDump) GetCrcString

func (*PolicerDump) GetCrcString() string

func (*PolicerDump) GetMessageName

func (*PolicerDump) GetMessageName() string

func (*PolicerDump) GetMessageType

func (*PolicerDump) GetMessageType() api.MessageType

func (*PolicerDump) Reset

func (m *PolicerDump) Reset()

type RPCService

type RPCService interface {
	DumpPolicer(ctx context.Context, in *PolicerDump) (RPCService_DumpPolicerClient, error)
	PolicerAddDel(ctx context.Context, in *PolicerAddDel) (*PolicerAddDelReply, error)
}

RPCService represents RPC service API for policer module.

func NewServiceClient

func NewServiceClient(ch api.Channel) RPCService

type RPCService_DumpPolicerClient

type RPCService_DumpPolicerClient interface {
	Recv() (*PolicerDetails, error)
}

type Sse2QosAction

type Sse2QosAction struct {
	Type Sse2QosActionType
	Dscp uint8
}

Sse2QosAction represents VPP binary API type 'sse2_qos_action'.

func (*Sse2QosAction) GetTypeName

func (*Sse2QosAction) GetTypeName() string

type Sse2QosActionType

type Sse2QosActionType uint8

Sse2QosActionType represents VPP binary API enum 'sse2_qos_action_type'.

const (
	SSE2_QOS_ACTION_API_DROP              Sse2QosActionType = 0
	SSE2_QOS_ACTION_API_TRANSMIT          Sse2QosActionType = 1
	SSE2_QOS_ACTION_API_MARK_AND_TRANSMIT Sse2QosActionType = 2
)

func (Sse2QosActionType) String

func (x Sse2QosActionType) String() string

type Sse2QosPolicerType

type Sse2QosPolicerType uint8

Sse2QosPolicerType represents VPP binary API enum 'sse2_qos_policer_type'.

const (
	SSE2_QOS_POLICER_TYPE_API_1R2C             Sse2QosPolicerType = 0
	SSE2_QOS_POLICER_TYPE_API_1R3C_RFC_2697    Sse2QosPolicerType = 1
	SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_2698    Sse2QosPolicerType = 2
	SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_4115    Sse2QosPolicerType = 3
	SSE2_QOS_POLICER_TYPE_API_2R3C_RFC_MEF5CF1 Sse2QosPolicerType = 4
	SSE2_QOS_POLICER_TYPE_API_MAX              Sse2QosPolicerType = 5
)

func (Sse2QosPolicerType) String

func (x Sse2QosPolicerType) String() string

type Sse2QosRateType

type Sse2QosRateType uint8

Sse2QosRateType represents VPP binary API enum 'sse2_qos_rate_type'.

const (
	SSE2_QOS_RATE_API_KBPS    Sse2QosRateType = 0
	SSE2_QOS_RATE_API_PPS     Sse2QosRateType = 1
	SSE2_QOS_RATE_API_INVALID Sse2QosRateType = 2
)

func (Sse2QosRateType) String

func (x Sse2QosRateType) String() string

type Sse2QosRoundType

type Sse2QosRoundType uint8

Sse2QosRoundType represents VPP binary API enum 'sse2_qos_round_type'.

const (
	SSE2_QOS_ROUND_API_TO_CLOSEST Sse2QosRoundType = 0
	SSE2_QOS_ROUND_API_TO_UP      Sse2QosRoundType = 1
	SSE2_QOS_ROUND_API_TO_DOWN    Sse2QosRoundType = 2
	SSE2_QOS_ROUND_API_INVALID    Sse2QosRoundType = 3
)

func (Sse2QosRoundType) String

func (x Sse2QosRoundType) String() string

Jump to

Keyboard shortcuts

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