def _add_aggregate_node(parent_elem, aggregate, slice_urn, available):
    
    agg_elem = et.SubElement(
        parent_elem, NETWORK_TAG, {
            LOCATION: aggregate.location,
            NAME: aggregate.name,
        },
    )

    _add_switches_node(agg_elem, aggregate, slice_urn, available)
    _add_links_node(agg_elem, aggregate, slice_urn, available)
    
    return agg_elem
Add an aggregate and the switches and links
dataset/ETHPy150Open fp7-ofelia/ocf/expedient/src/python/plugins/openflow/plugin/gapi/rspec.py/_add_aggregate_node