UnparsedVariableValue represents a variable value provided by the caller whose parsing must be deferred until configuration is available. This exists to allow processing of variable-setting arguments (e.g. in the command package) to be separated from parsing (in the backend package).
| 21 | // This exists to allow processing of variable-setting arguments (e.g. in the |
| 22 | // command package) to be separated from parsing (in the backend package). |
| 23 | type UnparsedVariableValue interface { |
| 24 | // ParseVariableValue information in the provided variable configuration |
| 25 | // to parse (if necessary) and return the variable value encapsulated in |
| 26 | // the receiver. |
| 27 | // |
| 28 | // If error diagnostics are returned, the resulting value may be invalid |
| 29 | // or incomplete. |
| 30 | ParseVariableValue(mode configs.VariableParsingMode) (*tofu.InputValue, tfdiags.Diagnostics) |
| 31 | } |
| 32 | |
| 33 | // ParseUndeclaredVariableValues processes a map of unparsed variable values |
| 34 | // and returns an input values map of the ones not declared in the specified |
no outgoing calls
no test coverage detected