AFRouteSegmentChildren.fromList constructor

AFRouteSegmentChildren.fromList(
  1. List<AFRouteParam> children
)

Implementation

factory AFRouteSegmentChildren.fromList(List<AFRouteParam> children) {
  final result = <AFID, AFRouteSegment>{};
  for(final child in children) {
    AFID wid = child.wid;
    if(wid.isKindOf(AFUIWidgetID.useScreenParam)) {
      wid = child.screenId;
    }

    result[wid] = AFRouteSegment(param: child, children: null, createDefaultChildParam: null);
  }
  return AFRouteSegmentChildren(children: result);
}