WithCall returns a new state with the given function call added to the chain
(fn *modFunction, argValues map[string]any)
| 338 | |
| 339 | // WithCall returns a new state with the given function call added to the chain |
| 340 | func (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 |
| 353 | func (st ShellState) QueryBuilder(dag *dagger.Client) *querybuilder.Selection { |
no test coverage detected