# Path: autonetkit/network_model/types.py
# class DeviceType(Enum):
# class PortType(Enum):
#     ROUTER = "Router"
#     SWITCH = "Switch"
#     HOST = "Host"
#     VIRTUAL = "Virtual"
#     BROADCAST_DOMAIN = "Broadcast Domain"
# LAYER3_DEVICES = {DeviceType.ROUTER, DeviceType.HOST}
#     PHYSICAL = "Physical"
#     LOGICAL = "Logical"


import logging
import typing
import networkx as nx
        import numpy
from typing import Optional, List, NamedTuple
from autonetkit.network_model.types import DeviceType, PortType, NodeId
    from autonetkit.network_model.node import Node
    from autonetkit.network_model.port import Port
    from autonetkit.network_model.link import Link
    from autonetkit.network_model.topology import Topology
    result = []
    peer_ports = node.peer_ports()
    topology.remove_node(node)

    pairs = [(x, y) for x in peer_ports for y in peer_ports
             if x != y]

    for p1, p2 in pairs:
        link = topology.create_link(p1, p2)
        result.append(link)

    return result


def links_contained_by_nodes(topology: 'Topology', nodes: List['Node']) -> List['Link']:
    """

    @param topology:
    @param nodes:
    @return:
    """
    nodes = set(nodes)
    result = []
    for link in topology.links():
        if link.n1 in nodes and link.n2 in nodes:
            result.append(link)

    return result



# Path: autonetkit/network_model/types.py
# class DeviceType(Enum):
# class PortType(Enum):
#     ROUTER = "Router"
#     SWITCH = "Switch"
#     HOST = "Host"
#     VIRTUAL = "Virtual"
#     BROADCAST_DOMAIN = "Broadcast Domain"
# LAYER3_DEVICES = {DeviceType.ROUTER, DeviceType.HOST}
#     PHYSICAL = "Physical"
#     LOGICAL = "Logical"


# Path: autonetkit/design/utils/graph_utils.py
import logging
import typing
import networkx as nx
        import numpy
from typing import Optional, List, NamedTuple
from autonetkit.network_model.types import DeviceType, PortType, NodeId
    from autonetkit.network_model.node import Node
    from autonetkit.network_model.port import Port
    from autonetkit.network_model.link import Link
    from autonetkit.network_model.topology import Topology

    result = []
    peer_ports = node.peer_ports()
    topology.remove_node(node)

    pairs = [(x, y) for x in peer_ports for y in peer_ports
             if x != y]

    for p1, p2 in pairs:
        link = topology.create_link(p1, p2)
        result.append(link)

    return result


def links_contained_by_nodes(topology: 'Topology', nodes: List['Node']) -> List['Link']:
    """

    @param topology:
    @param nodes:
    @return:
    """
    nodes = set(nodes)
    result = []
    for link in topology.links():
        if link.n1 in nodes and link.n2 in nodes:
            result.append(link)

    return result



def wrap_node_ids(topology: 'Topology', nodes: List[NodeId]) -> List['Node']: