extgen

package
v1.13.4 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2026 License: MIT Imports: 21 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

header.go

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NamespacedName added in v1.9.0

func NamespacedName(namespace, name string) string

NamespacedName converts a namespace and name to a C-compatible format. E.g., namespace "Go\Extension" and name "MyClass" become "Go_Extension_MyClass". This symbol remains exported, so it's usable in templates.

func SanitizePackageName

func SanitizePackageName(name string) string

EXPERIMENTAL

Types

type ConstantParser

type ConstantParser struct{}

type DocTemplateData

type DocTemplateData struct {
	BaseName  string
	Functions []phpFunction
	Classes   []phpClass
}

type DocumentationGenerator

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

type FuncParser

type FuncParser struct{}

type Generator

type Generator struct {
	BaseName   string
	SourceFile string
	BuildDir   string
	Functions  []phpFunction
	Classes    []phpClass
	Constants  []phpConstant
	Namespace  string
}

func (*Generator) Generate

func (g *Generator) Generate() error

EXPERIMENTAL

type GeneratorError

type GeneratorError struct {
	Stage   string
	Message string
	Err     error
}

func (*GeneratorError) Error

func (e *GeneratorError) Error() string

type GoFileGenerator

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

type HeaderGenerator

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

type NamespaceParser added in v1.9.0

type NamespaceParser struct{}

type PHPFuncGenerator

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

type ParameterInfo

type ParameterInfo struct {
	RequiredCount int
	TotalCount    int
}

type ParameterParser

type ParameterParser struct{}

type SourceAnalyzer

type SourceAnalyzer struct{}

type SourceParser

type SourceParser struct{}

func (*SourceParser) ParseClasses

func (p *SourceParser) ParseClasses(filename string) ([]phpClass, error)

EXPERIMENTAL

func (*SourceParser) ParseConstants

func (p *SourceParser) ParseConstants(filename string) ([]phpConstant, error)

EXPERIMENTAL

func (*SourceParser) ParseFunctions

func (p *SourceParser) ParseFunctions(filename string) ([]phpFunction, error)

EXPERIMENTAL

func (*SourceParser) ParseNamespace added in v1.9.0

func (p *SourceParser) ParseNamespace(filename string) (string, error)

EXPERIMENTAL

type StubGenerator

type StubGenerator struct {
	Generator *Generator
}

type TemplateData

type TemplateData struct {
	BaseName    string
	HeaderGuard string
	Constants   []phpConstant
	Classes     []phpClass
}

type Validator

type Validator struct{}

Jump to

Keyboard shortcuts

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