inproc

package
v2.10.1 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package inproc is the client.Client over an engine in the same process: no wire, no serialisation beyond the codec. It is what a terminal interface uses when it runs in the cartograph binary itself, and what the conformance suite uses to prove the scenarios against the engine directly.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	E *engine.Engine
	// Operator is recorded as the actor when the context carries no
	// principal: the vault's settings say what it is.
	Operator string
}

Client wraps an engine.

func New

func New(e *engine.Engine) *Client

New returns a client over e.

func (*Client) Actor

func (c *Client) Actor(ctx context.Context) (string, error)

func (*Client) Checks

func (c *Client) Checks(ctx context.Context, kind, id string) ([]client.Check, error)

func (*Client) Close

func (c *Client) Close() error

func (*Client) Flow

func (c *Client) Flow(_ context.Context, kind string) (client.Flow, bool, error)

func (*Client) Get

func (c *Client) Get(ctx context.Context, kind, id string) (client.Manifest, error)

func (*Client) Kinds

func (c *Client) Kinds(context.Context) ([]string, error)

func (*Client) List

func (c *Client) List(ctx context.Context, kind, query string) ([]client.Summary, error)

func (*Client) SaveVersion

func (c *Client) SaveVersion(ctx context.Context, kind, id string, doc map[string]any, reason string) (client.Version, error)

func (*Client) SaveWorking

func (c *Client) SaveWorking(ctx context.Context, kind, id string, doc map[string]any) error

func (*Client) Schema

func (c *Client) Schema(_ context.Context, kind string) ([]byte, error)

func (*Client) Settings

func (c *Client) Settings(ctx context.Context) (client.Settings, error)

func (*Client) SharedDocument

func (c *Client) SharedDocument(ctx context.Context, kind, id string) (string, error)

func (*Client) Subscribe

func (c *Client) Subscribe(ctx context.Context, kind, id string) (<-chan client.Event, error)

func (*Client) Validate

func (c *Client) Validate(ctx context.Context, kind string, doc map[string]any) ([]client.Problem, error)

func (*Client) Working

func (c *Client) Working(ctx context.Context, kind, id string) (client.Manifest, error)

Jump to

Keyboard shortcuts

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