Adder constructor

Adder(
  1. String name, {
  2. dynamic onSet(
    1. Map<String, dynamic>
    )?,
  3. dynamic onCancel()?,
  4. List<InputData> textfieldList = const [],
  5. List<JsonExtractable> children = const [],
})

Implementation

Adder(
  this.name, {
  this.onSet,
  this.onCancel,
  this.textfieldList = const [],
  this.children = const [],
})  : assert(textfieldList ==
          textfieldList
              .unique((x) => x.varName)), //all varnames need to be unique
      this._textfieldControllerList =
          textfieldList.map((tf) => TextEditingController()).toList(),
      // this._textfield_focusnode_list =
      //     textfield_list.map((tf) => FocusNode()).toList(),
      this.json = {name: {}};