memif

package
v3.4.0-alpha Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package memif contains generated bindings for API file memif.api.

Contents:

 2 enums
10 messages

Index

Constants

View Source
const (
	APIFile    = "memif"
	APIVersion = "3.0.0"
	VersionCrc = 0xd09fa76
)

Variables

View Source
var (
	MemifMode_name = map[uint32]string{
		0: "MEMIF_MODE_API_ETHERNET",
		1: "MEMIF_MODE_API_IP",
		2: "MEMIF_MODE_API_PUNT_INJECT",
	}
	MemifMode_value = map[string]uint32{
		"MEMIF_MODE_API_ETHERNET":    0,
		"MEMIF_MODE_API_IP":          1,
		"MEMIF_MODE_API_PUNT_INJECT": 2,
	}
)
View Source
var (
	MemifRole_name = map[uint32]string{
		0: "MEMIF_ROLE_API_MASTER",
		1: "MEMIF_ROLE_API_SLAVE",
	}
	MemifRole_value = map[string]uint32{
		"MEMIF_ROLE_API_MASTER": 0,
		"MEMIF_ROLE_API_SLAVE":  1,
	}
)

Functions

func AllMessages

func AllMessages() []api.Message

Messages returns list of all messages in this module.

Types

type MemifCreate

type MemifCreate struct {
	Role       MemifRole                 `binapi:"memif_role,name=role" json:"role,omitempty"`
	Mode       MemifMode                 `binapi:"memif_mode,name=mode" json:"mode,omitempty"`
	RxQueues   uint8                     `binapi:"u8,name=rx_queues" json:"rx_queues,omitempty"`
	TxQueues   uint8                     `binapi:"u8,name=tx_queues" json:"tx_queues,omitempty"`
	ID         uint32                    `binapi:"u32,name=id" json:"id,omitempty"`
	SocketID   uint32                    `binapi:"u32,name=socket_id" json:"socket_id,omitempty"`
	RingSize   uint32                    `binapi:"u32,name=ring_size" json:"ring_size,omitempty"`
	BufferSize uint16                    `binapi:"u16,name=buffer_size" json:"buffer_size,omitempty"`
	NoZeroCopy bool                      `binapi:"bool,name=no_zero_copy" json:"no_zero_copy,omitempty"`
	HwAddr     ethernet_types.MacAddress `binapi:"mac_address,name=hw_addr" json:"hw_addr,omitempty"`
	Secret     string                    `binapi:"string[24],name=secret" json:"secret,omitempty"`
}

MemifCreate defines message 'memif_create'.

func (*MemifCreate) GetCrcString

func (*MemifCreate) GetCrcString() string

func (*MemifCreate) GetMessageName

func (*MemifCreate) GetMessageName() string

func (*MemifCreate) GetMessageType

func (*MemifCreate) GetMessageType() api.MessageType

func (*MemifCreate) Marshal

func (m *MemifCreate) Marshal(b []byte) ([]byte, error)

func (*MemifCreate) Reset

func (m *MemifCreate) Reset()

func (*MemifCreate) Size

func (m *MemifCreate) Size() (size int)

func (*MemifCreate) Unmarshal

func (m *MemifCreate) Unmarshal(b []byte) error

type MemifCreateReply

type MemifCreateReply struct {
	Retval    int32                          `binapi:"i32,name=retval" json:"retval,omitempty"`
	SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
}

MemifCreateReply defines message 'memif_create_reply'.

func (*MemifCreateReply) GetCrcString

func (*MemifCreateReply) GetCrcString() string

func (*MemifCreateReply) GetMessageName

func (*MemifCreateReply) GetMessageName() string

func (*MemifCreateReply) GetMessageType

func (*MemifCreateReply) GetMessageType() api.MessageType

func (*MemifCreateReply) Marshal

func (m *MemifCreateReply) Marshal(b []byte) ([]byte, error)

func (*MemifCreateReply) Reset

func (m *MemifCreateReply) Reset()

func (*MemifCreateReply) Size

func (m *MemifCreateReply) Size() (size int)

func (*MemifCreateReply) Unmarshal

func (m *MemifCreateReply) Unmarshal(b []byte) error

type MemifDelete

type MemifDelete struct {
	SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
}

MemifDelete defines message 'memif_delete'.

func (*MemifDelete) GetCrcString

func (*MemifDelete) GetCrcString() string

func (*MemifDelete) GetMessageName

func (*MemifDelete) GetMessageName() string

func (*MemifDelete) GetMessageType

func (*MemifDelete) GetMessageType() api.MessageType

func (*MemifDelete) Marshal

func (m *MemifDelete) Marshal(b []byte) ([]byte, error)

func (*MemifDelete) Reset

func (m *MemifDelete) Reset()

func (*MemifDelete) Size

func (m *MemifDelete) Size() (size int)

func (*MemifDelete) Unmarshal

func (m *MemifDelete) Unmarshal(b []byte) error

type MemifDeleteReply

type MemifDeleteReply struct {
	Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
}

MemifDeleteReply defines message 'memif_delete_reply'.

func (*MemifDeleteReply) GetCrcString

func (*MemifDeleteReply) GetCrcString() string

func (*MemifDeleteReply) GetMessageName

func (*MemifDeleteReply) GetMessageName() string

func (*MemifDeleteReply) GetMessageType

func (*MemifDeleteReply) GetMessageType() api.MessageType

func (*MemifDeleteReply) Marshal

func (m *MemifDeleteReply) Marshal(b []byte) ([]byte, error)

func (*MemifDeleteReply) Reset

func (m *MemifDeleteReply) Reset()

func (*MemifDeleteReply) Size

func (m *MemifDeleteReply) Size() (size int)

func (*MemifDeleteReply) Unmarshal

func (m *MemifDeleteReply) Unmarshal(b []byte) error

type MemifDetails

type MemifDetails struct {
	SwIfIndex  interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
	HwAddr     ethernet_types.MacAddress      `binapi:"mac_address,name=hw_addr" json:"hw_addr,omitempty"`
	ID         uint32                         `binapi:"u32,name=id" json:"id,omitempty"`
	Role       MemifRole                      `binapi:"memif_role,name=role" json:"role,omitempty"`
	Mode       MemifMode                      `binapi:"memif_mode,name=mode" json:"mode,omitempty"`
	ZeroCopy   bool                           `binapi:"bool,name=zero_copy" json:"zero_copy,omitempty"`
	SocketID   uint32                         `binapi:"u32,name=socket_id" json:"socket_id,omitempty"`
	RingSize   uint32                         `binapi:"u32,name=ring_size" json:"ring_size,omitempty"`
	BufferSize uint16                         `binapi:"u16,name=buffer_size" json:"buffer_size,omitempty"`
	Flags      interface_types.IfStatusFlags  `binapi:"if_status_flags,name=flags" json:"flags,omitempty"`
	IfName     string                         `binapi:"string[64],name=if_name" json:"if_name,omitempty"`
}

MemifDetails defines message 'memif_details'.

func (*MemifDetails) GetCrcString

func (*MemifDetails) GetCrcString() string

func (*MemifDetails) GetMessageName

func (*MemifDetails) GetMessageName() string

func (*MemifDetails) GetMessageType

func (*MemifDetails) GetMessageType() api.MessageType

func (*MemifDetails) Marshal

func (m *MemifDetails) Marshal(b []byte) ([]byte, error)

func (*MemifDetails) Reset

func (m *MemifDetails) Reset()

func (*MemifDetails) Size

func (m *MemifDetails) Size() (size int)

func (*MemifDetails) Unmarshal

func (m *MemifDetails) Unmarshal(b []byte) error

type MemifDump

type MemifDump struct{}

MemifDump defines message 'memif_dump'.

func (*MemifDump) GetCrcString

func (*MemifDump) GetCrcString() string

func (*MemifDump) GetMessageName

func (*MemifDump) GetMessageName() string

func (*MemifDump) GetMessageType

func (*MemifDump) GetMessageType() api.MessageType

func (*MemifDump) Marshal

func (m *MemifDump) Marshal(b []byte) ([]byte, error)

func (*MemifDump) Reset

func (m *MemifDump) Reset()

func (*MemifDump) Size

func (m *MemifDump) Size() (size int)

func (*MemifDump) Unmarshal

func (m *MemifDump) Unmarshal(b []byte) error

type MemifMode

type MemifMode uint32

MemifMode defines enum 'memif_mode'.

const (
	MEMIF_MODE_API_ETHERNET    MemifMode = 0
	MEMIF_MODE_API_IP          MemifMode = 1
	MEMIF_MODE_API_PUNT_INJECT MemifMode = 2
)

func (MemifMode) String

func (x MemifMode) String() string

type MemifRole

type MemifRole uint32

MemifRole defines enum 'memif_role'.

const (
	MEMIF_ROLE_API_MASTER MemifRole = 0
	MEMIF_ROLE_API_SLAVE  MemifRole = 1
)

func (MemifRole) String

func (x MemifRole) String() string

type MemifSocketFilenameAddDel

type MemifSocketFilenameAddDel struct {
	IsAdd          bool   `binapi:"bool,name=is_add" json:"is_add,omitempty"`
	SocketID       uint32 `binapi:"u32,name=socket_id" json:"socket_id,omitempty"`
	SocketFilename string `binapi:"string[108],name=socket_filename" json:"socket_filename,omitempty"`
}

MemifSocketFilenameAddDel defines message 'memif_socket_filename_add_del'.

func (*MemifSocketFilenameAddDel) GetCrcString

func (*MemifSocketFilenameAddDel) GetCrcString() string

func (*MemifSocketFilenameAddDel) GetMessageName

func (*MemifSocketFilenameAddDel) GetMessageName() string

func (*MemifSocketFilenameAddDel) GetMessageType

func (*MemifSocketFilenameAddDel) GetMessageType() api.MessageType

func (*MemifSocketFilenameAddDel) Marshal

func (m *MemifSocketFilenameAddDel) Marshal(b []byte) ([]byte, error)

func (*MemifSocketFilenameAddDel) Reset

func (m *MemifSocketFilenameAddDel) Reset()

func (*MemifSocketFilenameAddDel) Size

func (m *MemifSocketFilenameAddDel) Size() (size int)

func (*MemifSocketFilenameAddDel) Unmarshal

func (m *MemifSocketFilenameAddDel) Unmarshal(b []byte) error

type MemifSocketFilenameAddDelReply

type MemifSocketFilenameAddDelReply struct {
	Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
}

MemifSocketFilenameAddDelReply defines message 'memif_socket_filename_add_del_reply'.

func (*MemifSocketFilenameAddDelReply) GetCrcString

func (*MemifSocketFilenameAddDelReply) GetCrcString() string

func (*MemifSocketFilenameAddDelReply) GetMessageName

func (*MemifSocketFilenameAddDelReply) GetMessageName() string

func (*MemifSocketFilenameAddDelReply) GetMessageType

func (*MemifSocketFilenameAddDelReply) Marshal

func (m *MemifSocketFilenameAddDelReply) Marshal(b []byte) ([]byte, error)

func (*MemifSocketFilenameAddDelReply) Reset

func (m *MemifSocketFilenameAddDelReply) Reset()

func (*MemifSocketFilenameAddDelReply) Size

func (m *MemifSocketFilenameAddDelReply) Size() (size int)

func (*MemifSocketFilenameAddDelReply) Unmarshal

func (m *MemifSocketFilenameAddDelReply) Unmarshal(b []byte) error

type MemifSocketFilenameDetails

type MemifSocketFilenameDetails struct {
	SocketID       uint32 `binapi:"u32,name=socket_id" json:"socket_id,omitempty"`
	SocketFilename string `binapi:"string[108],name=socket_filename" json:"socket_filename,omitempty"`
}

MemifSocketFilenameDetails defines message 'memif_socket_filename_details'.

func (*MemifSocketFilenameDetails) GetCrcString

func (*MemifSocketFilenameDetails) GetCrcString() string

func (*MemifSocketFilenameDetails) GetMessageName

func (*MemifSocketFilenameDetails) GetMessageName() string

func (*MemifSocketFilenameDetails) GetMessageType

func (*MemifSocketFilenameDetails) GetMessageType() api.MessageType

func (*MemifSocketFilenameDetails) Marshal

func (m *MemifSocketFilenameDetails) Marshal(b []byte) ([]byte, error)

func (*MemifSocketFilenameDetails) Reset

func (m *MemifSocketFilenameDetails) Reset()

func (*MemifSocketFilenameDetails) Size

func (m *MemifSocketFilenameDetails) Size() (size int)

func (*MemifSocketFilenameDetails) Unmarshal

func (m *MemifSocketFilenameDetails) Unmarshal(b []byte) error

type MemifSocketFilenameDump

type MemifSocketFilenameDump struct{}

MemifSocketFilenameDump defines message 'memif_socket_filename_dump'.

func (*MemifSocketFilenameDump) GetCrcString

func (*MemifSocketFilenameDump) GetCrcString() string

func (*MemifSocketFilenameDump) GetMessageName

func (*MemifSocketFilenameDump) GetMessageName() string

func (*MemifSocketFilenameDump) GetMessageType

func (*MemifSocketFilenameDump) GetMessageType() api.MessageType

func (*MemifSocketFilenameDump) Marshal

func (m *MemifSocketFilenameDump) Marshal(b []byte) ([]byte, error)

func (*MemifSocketFilenameDump) Reset

func (m *MemifSocketFilenameDump) Reset()

func (*MemifSocketFilenameDump) Size

func (m *MemifSocketFilenameDump) Size() (size int)

func (*MemifSocketFilenameDump) Unmarshal

func (m *MemifSocketFilenameDump) Unmarshal(b []byte) error

type RPCService

type RPCService interface {
	MemifCreate(ctx context.Context, in *MemifCreate) (*MemifCreateReply, error)
	MemifDelete(ctx context.Context, in *MemifDelete) (*MemifDeleteReply, error)
	MemifDump(ctx context.Context, in *MemifDump) (RPCService_MemifDumpClient, error)
	MemifSocketFilenameAddDel(ctx context.Context, in *MemifSocketFilenameAddDel) (*MemifSocketFilenameAddDelReply, error)
	MemifSocketFilenameDump(ctx context.Context, in *MemifSocketFilenameDump) (RPCService_MemifSocketFilenameDumpClient, error)
}

RPCService defines RPC service memif.

func NewServiceClient

func NewServiceClient(conn api.Connection) RPCService

type RPCService_MemifDumpClient

type RPCService_MemifDumpClient interface {
	Recv() (*MemifDetails, error)
	api.Stream
}

type RPCService_MemifSocketFilenameDumpClient

type RPCService_MemifSocketFilenameDumpClient interface {
	Recv() (*MemifSocketFilenameDetails, error)
	api.Stream
}

Jump to

Keyboard shortcuts

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