JsonPathArgument constructor

JsonPathArgument(
  1. String path,
  2. VariableDefinitionContext definition,
  3. dynamic defaultValue,
  4. Map<String, dynamic> variableValues,
)

Implementation

JsonPathArgument(
    this.path, this.definition, this.defaultValue, this.variableValues)
    : _spl = path.split('.') {
  if (_spl.isEmpty || _spl.length < 2 || _spl.first != r'$') {
    throw 'Bad json path $path';
  }

  _spl.removeAt(0);
}