pipeline

package
v0.0.107 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: GPL-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PerformSubstitutions

func PerformSubstitutions(pipelineStr string, subs map[string]string) (string, error)

PerformSubstitutions replaces placeholders like ${VAR} with values from the map.

func TokenizePipeline

func TokenizePipeline(pipelineStr string) ([]string, error)

TokenizePipeline parses a pipeline string into individual commands.

Types

type Evaluator

type Evaluator struct {
	Client *http.Client
}

Evaluator is responsible for executing pipelines.

func NewEvaluator

func NewEvaluator(client *http.Client) *Evaluator

NewEvaluator creates a new pipeline evaluator.

func (*Evaluator) Evaluate

func (e *Evaluator) Evaluate(pipelineStr string) (*PipelineValue, error)

Evaluate runs the given pipeline string and returns the resulting value.

type PipelineValue

type PipelineValue struct {
	IsEmpty bool
	Value   any
	List    []any
	RawNode *xmlquery.Node
}

PipelineValue models the structured internal value in the pipeline. It explicitly distinguishes zero cardinality, scalars, and lists.

func (*PipelineValue) GetString

func (v *PipelineValue) GetString() string

GetString converts the single scalar value to a string if it exists.

func (*PipelineValue) IsList

func (v *PipelineValue) IsList() bool

IsList returns true if the value is a list.

Jump to

Keyboard shortcuts

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