codecreator

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: May 4, 2026 License: MPL-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicCodeCreator

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

func (*BasicCodeCreator) AddBlock added in v1.4.8

func (bcc *BasicCodeCreator) AddBlock(block func())

func (*BasicCodeCreator) AddEmptyLine added in v1.4.8

func (bcc *BasicCodeCreator) AddEmptyLine()

func (*BasicCodeCreator) AddFullEmptyLine added in v1.4.9

func (bcc *BasicCodeCreator) AddFullEmptyLine()

func (*BasicCodeCreator) AddLinef added in v1.4.8

func (bcc *BasicCodeCreator) AddLinef(format string, args ...any)

func (*BasicCodeCreator) AddLines added in v1.4.8

func (bcc *BasicCodeCreator) AddLines(lines ...string)

func (*BasicCodeCreator) AddShift added in v1.4.8

func (bcc *BasicCodeCreator) AddShift(shift int)

func (*BasicCodeCreator) Block

func (bcc *BasicCodeCreator) Block(prefix string, block func(), suffix string)

func (*BasicCodeCreator) Comment

func (bcc *BasicCodeCreator) Comment(lines string)

func (*BasicCodeCreator) Comments

func (bcc *BasicCodeCreator) Comments(lines ...string)

func (*BasicCodeCreator) FinishBlock added in v1.4.8

func (bcc *BasicCodeCreator) FinishBlock(block func(), suffix string)

func (*BasicCodeCreator) For

func (bcc *BasicCodeCreator) For(initState, condition, iterationStep string, block func())

func (*BasicCodeCreator) If

func (bcc *BasicCodeCreator) If(condition string, block func())

func (*BasicCodeCreator) IfElse

func (bcc *BasicCodeCreator) IfElse(condition string, block func(), elseBlock func())

func (*BasicCodeCreator) Lines added in v1.4.8

func (bcc *BasicCodeCreator) Lines() []string

func (*BasicCodeCreator) NewVariable

func (bcc *BasicCodeCreator) NewVariable(name string) string

func (*BasicCodeCreator) Print added in v1.4.8

func (bcc *BasicCodeCreator) Print() []string

TODO - remove, use Lines()

func (*BasicCodeCreator) Text added in v1.4.8

func (bcc *BasicCodeCreator) Text() string

type CppCodeCreator

type CppCodeCreator struct {
	BasicCodeCreator
}

func NewCppCodeCreator

func NewCppCodeCreator() *CppCodeCreator

func (*CppCodeCreator) ForIndexed added in v1.4.8

func (bcc *CppCodeCreator) ForIndexed(indexVar, startValue, upperBound, step string, block func())

type FunctionArgument added in v1.4.9

type FunctionArgument struct {
	Name     string
	TypeName string
}

type PhpCodeCreator

type PhpCodeCreator struct {
	BasicCodeCreator
}

func NewPhpCodeCreator

func NewPhpCodeCreator() *PhpCodeCreator

func (*PhpCodeCreator) AddAssign added in v1.4.8

func (ph *PhpCodeCreator) AddAssign(name, value string) string

func (*PhpCodeCreator) Assign added in v1.4.8

func (ph *PhpCodeCreator) Assign(name, value string) string

func (*PhpCodeCreator) CheckBit added in v1.4.8

func (ph *PhpCodeCreator) CheckBit(target string, bit int) string

func (*PhpCodeCreator) Class added in v1.4.9

func (ph *PhpCodeCreator) Class(modifiers []string, name string, interfaces []string, block func())

class body without any comment

func (*PhpCodeCreator) Equal added in v1.4.8

func (ph *PhpCodeCreator) Equal(left, right string) string

func (*PhpCodeCreator) ForIndexed added in v1.4.8

func (ph *PhpCodeCreator) ForIndexed(indexVar, startValue, upperBound, step string, block func())

func (*PhpCodeCreator) Function added in v1.4.9

func (ph *PhpCodeCreator) Function(modifiers []string, name string, args []FunctionArgument, returnType string, block func())

func (*PhpCodeCreator) FunctionComment added in v1.4.9

func (ph *PhpCodeCreator) FunctionComment(args []FunctionArgument, returnType string)

func (*PhpCodeCreator) NotEqual added in v1.4.8

func (ph *PhpCodeCreator) NotEqual(left, right string) string

func (*PhpCodeCreator) NotStrongEqual added in v1.4.9

func (ph *PhpCodeCreator) NotStrongEqual(left, right string) string

func (*PhpCodeCreator) OrAssign added in v1.4.8

func (ph *PhpCodeCreator) OrAssign(name, value string) string

func (*PhpCodeCreator) StrongEqual added in v1.4.9

func (ph *PhpCodeCreator) StrongEqual(left, right string) string

func (*PhpCodeCreator) SubAssign added in v1.4.8

func (ph *PhpCodeCreator) SubAssign(name, value string) string

func (*PhpCodeCreator) TL2CountBytes added in v1.4.8

func (ph *PhpCodeCreator) TL2CountBytes(value string) string

func (*PhpCodeCreator) TL2FetchSize added in v1.4.8

func (ph *PhpCodeCreator) TL2FetchSize() string

func (*PhpCodeCreator) TL2FetchSizeTo added in v1.4.8

func (ph *PhpCodeCreator) TL2FetchSizeTo(name string) string

func (*PhpCodeCreator) TL2SkipBytes added in v1.4.8

func (ph *PhpCodeCreator) TL2SkipBytes(value string) string

func (*PhpCodeCreator) TL2StoreSize added in v1.4.8

func (ph *PhpCodeCreator) TL2StoreSize(value string) string

func (*PhpCodeCreator) TLFetchUint32 added in v1.4.9

func (ph *PhpCodeCreator) TLFetchUint32() string

func (*PhpCodeCreator) TLFetchUint32To added in v1.4.9

func (ph *PhpCodeCreator) TLFetchUint32To(target string) string

func (*PhpCodeCreator) TLStoreUint32 added in v1.4.9

func (ph *PhpCodeCreator) TLStoreUint32(target string) string

type RustCodeCreator added in v1.4.8

type RustCodeCreator struct {
	BasicCodeCreator
}

func NewRustCodeCreator added in v1.4.8

func NewRustCodeCreator() *RustCodeCreator

Jump to

Keyboard shortcuts

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