dylib

package
v0.0.0-...-7c1eb0e Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SyscallN

func SyscallN(fn uintptr, args ...uintptr) (r1, r2, err uintptr)

Types

type DyLib

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

func NewDyLib

func NewDyLib(filename string) *DyLib

func (*DyLib) Call

func (dy *DyLib) Call(name string, args ...interface{}) (uintptr, error)

func (*DyLib) Close

func (dy *DyLib) Close()

func (*DyLib) GetFunctionPtr

func (dy *DyLib) GetFunctionPtr(name string) (uintptr, error)

func (*DyLib) Load

func (dy *DyLib) Load(filename ...string) error

func (*DyLib) RegisterFunction

func (dy *DyLib) RegisterFunction(bindFunPtr interface{}, name string) error

RegisterFunction 注册函数

bindFunPtr: 函数原形定义 name 函数名字

type ReturnValue

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

func NewReturnValue

func NewReturnValue(value uintptr) *ReturnValue

func (*ReturnValue) ToBool

func (r *ReturnValue) ToBool() bool

func (*ReturnValue) ToBytes

func (r *ReturnValue) ToBytes(maxLen int) []byte

func (*ReturnValue) ToInt

func (r *ReturnValue) ToInt() int64

func (*ReturnValue) ToString

func (r *ReturnValue) ToString() string

type VarUtil

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

func NewValString

func NewValString(str string) *VarUtil

func NewVarBuffer

func NewVarBuffer(str string, maxLen int) *VarUtil

func NewVarInt32

func NewVarInt32(v int32) *VarUtil

func NewVarInt32Ptr

func NewVarInt32Ptr(v int32) *VarUtil

func NewVarInt64

func NewVarInt64(v int64) *VarUtil

func NewVarInt64Ptr

func NewVarInt64Ptr(v int64) *VarUtil

func (*VarUtil) BufferValue

func (vl *VarUtil) BufferValue() []byte

func (*VarUtil) IntValue

func (vl *VarUtil) IntValue() int64

func (*VarUtil) StringValue

func (vl *VarUtil) StringValue() string

Jump to

Keyboard shortcuts

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