MCPcopy Index your code
hub / github.com/dagger/dagger / WithCall

Method WithCall

cmd/dagger/shell_state.go:340–350  ·  view source on GitHub ↗

WithCall returns a new state with the given function call added to the chain

(fn *modFunction, argValues map[string]any)

Source from the content-addressed store, hash-verified

338
339// WithCall returns a new state with the given function call added to the chain
340func (st ShellState) WithCall(fn *modFunction, argValues map[string]any) ShellState {
341 prev := st.Function()
342 next := st
343 next.Calls = append(next.Calls, FunctionCall{
344 Object: prev.ReturnObject,
345 Name: fn.Name,
346 ReturnObject: fn.ReturnType.Name(),
347 Arguments: argValues,
348 })
349 return next
350}
351
352// QueryBuilder returns a querybuilder.Selection from the shell state
353func (st ShellState) QueryBuilder(dag *dagger.Client) *querybuilder.Selection {

Callers 3

constructorCallMethod · 0.80
functionCallMethod · 0.80
StateResultMethod · 0.80

Calls 2

FunctionMethod · 0.95
NameMethod · 0.65

Tested by

no test coverage detected