setChildren method

void setChildren(
  1. List<Widget> children
)

Implementation

void setChildren(List<Widget> children) {
  final existingPropertyIndex = properties
      .indexWhere((element) => element.property == NodeProperties.children);
  if (existingPropertyIndex >= 0) {
    properties[existingPropertyIndex] = ChildrenProperty(children: children);
  } else {
    properties.add(ChildrenProperty(children: children));
  }
}