allParameters property

List<Parameter> allParameters

Implementation

List<Parameter> get allParameters {
  if (_allParameters == null) {
    var recursedParameters = <Parameter>{};
    var newParameters = <Parameter>{};
    if (this is GetterSetterCombo &&
        (this as GetterSetterCombo).setter != null) {
      newParameters.addAll((this as GetterSetterCombo).setter.parameters);
    } else {
      if (isCallable) newParameters.addAll(parameters);
    }
    while (newParameters.isNotEmpty) {
      recursedParameters.addAll(newParameters);
      newParameters.clear();
      for (var p in recursedParameters) {
        var l = p.modelType.parameters
            .where((pm) => !recursedParameters.contains(pm));
        newParameters.addAll(l);
      }
    }
    _allParameters = recursedParameters.toList();
  }
  return _allParameters;
}