model

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Delete

func Delete(ctx context.Context, s logical.Storage, fullPath string) (err error)

Delete removes the storage entry at the specified fullPath.

func Get

func Get[T any](ctx context.Context, s logical.Storage, fullPath string) (data *T, err error)

Get retrieves and decodes an entry at fullPath into a new T. Returns (nil, nil) if the entry is not found.

func List

func List(ctx context.Context, s logical.Storage, fullPath string) (entries []string, err error)

List returns the list of keys at fullPath in storage.

func Save

func Save(ctx context.Context, s logical.Storage, rootPath string, data Named) (err error)

Save marshals and stores 'data' at the given rootPath in storage 's'.

Types

type Event

type Event interface{}

type IsNil

type IsNil interface {
	// IsNil returns a boolean indicating whether the instance is considered nil or invalid
	IsNil() bool
}

type LogicalResponseData

type LogicalResponseData interface {
	// LogicalResponseData returns a map containing relevant data that can be used in template operations or logical evaluations
	LogicalResponseData() map[string]any
}

type LogicalResponseDataWithOptions

type LogicalResponseDataWithOptions[T any] interface {
	// LogicalResponseData returns a map containing relevant data that can be used in template operations or logical evaluations
	LogicalResponseData(opts T) map[string]any
}

type Named

type Named interface {
	// GetName returns the model's name as a string
	GetName() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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