Versions in this module Expand all Collapse all v0 v0.1.0 Oct 21, 2026 Changes in this version + const ClassEngine + const ClassInvalidArgument + const ClassInvalidMethod + const ClassJSException + const ClassResource + const ClassUnknownMethod + const DefaultMaxArgBytes + const DefaultTimeout + const FakerVersion + var ErrArgTooLarge = errors.New("faker call argument exceeds the size limit") + var ErrClosed = errors.New("engine is closed") + var ErrDeadline = errors.New("faker call exceeded its deadline") + var ErrOutOfMemory = errors.New("faker call exceeded the Wasm memory limit") + var ErrPoisoned = errors.New("engine poisoned") + var ErrResultTooLarge = errors.New("faker call result exceeds the size limit") + var ErrUnknownMethod = errors.New("unknown faker method") + func DeriveSeed(base int64, index int) int64 + func IsClass(err error, class string) bool + func ValidMethod(method string) bool + type Engine struct + func NewEngine(seed int64, opts ...Option) *Engine + func (e *Engine) Close() + func (e *Engine) Generate(method string, arg any) (string, error) + func (e *Engine) GenerateN(method string, arg any, n int) ([]string, error) + func (e *Engine) Poisoned() bool + type Error struct + Class string + Err error + Method string + Msg string + func (e *Error) Error() string + func (e *Error) ErrorClass() string + func (e *Error) Unwrap() error + type Option func(*config) + func WithClock(now func() time.Time) Option + func WithMaxArgBytes(n int) Option + func WithRefDate(t time.Time) Option + func WithTimeout(d time.Duration) Option + type Pool struct + func NewPool(size int, base int64, opts ...Option) *Pool + func (p *Pool) Close() + func (p *Pool) Do(fn func(*Engine) error) error + func (p *Pool) Get() (*Engine, func()) + func (p *Pool) Size() int