# Path: wiremaps/collector/exception.py
# class CollectorException(RuntimeError):
# class NoCommunity(CollectorException):
# class UnknownEquipment(CollectorException):
# class NoLLDP(CollectorException):
# class CollectorAlreadyRunning(CollectorException):
# 
# Path: wiremaps/collector/datastore.py
# class Edp:
#     implements(IEdp)
# 
#     def __init__(self, sysname, slot, port):
#         self.sysname = ascii(sysname)
#         self.slot = slot
#         self.port = port
# 
# class RemoteVlan(Vlan):
#     implements(IRemoteVlan)


from wiremaps.collector import exception
from wiremaps.collector.datastore import Edp, RemoteVlan
            if self.normport is not None:
                port = self.normport(port)
            desc = results[oid]
            if desc and port is not None:
                dic[port] = desc

    def gotEdpVlan(self, results):
        """Callback handling reception of EDP vlan

        @param results: result of walking C{EXTREME-EDP-MIB::extremeEdpNeighborVlanId}
        """
        for oid in results:
            port = int(oid[len(self.edpNeighborVlanId):].split(".")[1])
            if self.normport is not None:
                port = self.normport(port)
            vlan = [chr(int(x))
                    for x in oid[len(self.edpNeighborVlanId):].split(".")[11:]]
            self.vlan[results[oid], port] = "".join(vlan)

    def completeEquipment(self):
        """Complete C{self.equipment} with data from EDP."""
        # Core EDP
        for port in self.edpSysName:
            self.equipment.ports[port].edp = \
                Edp(self.edpSysName[port],
                    int(self.edpRemoteSlot[port]),
                    int(self.edpRemotePort[port]))
        # Vlans
        for vid, port in self.vlan:
            self.equipment.ports[port].vlan.append(

# Path: wiremaps/collector/exception.py
# class CollectorException(RuntimeError):
# class NoCommunity(CollectorException):
# class UnknownEquipment(CollectorException):
# class NoLLDP(CollectorException):
# class CollectorAlreadyRunning(CollectorException):
# 
# Path: wiremaps/collector/datastore.py
# class Edp:
#     implements(IEdp)
# 
#     def __init__(self, sysname, slot, port):
#         self.sysname = ascii(sysname)
#         self.slot = slot
#         self.port = port
# 
# class RemoteVlan(Vlan):
#     implements(IRemoteVlan)


# Path: wiremaps/collector/helpers/edp.py
from wiremaps.collector import exception
from wiremaps.collector.datastore import Edp, RemoteVlan

            if self.normport is not None:
                port = self.normport(port)
            desc = results[oid]
            if desc and port is not None:
                dic[port] = desc

    def gotEdpVlan(self, results):
        """Callback handling reception of EDP vlan

        @param results: result of walking C{EXTREME-EDP-MIB::extremeEdpNeighborVlanId}
        """
        for oid in results:
            port = int(oid[len(self.edpNeighborVlanId):].split(".")[1])
            if self.normport is not None:
                port = self.normport(port)
            vlan = [chr(int(x))
                    for x in oid[len(self.edpNeighborVlanId):].split(".")[11:]]
            self.vlan[results[oid], port] = "".join(vlan)

    def completeEquipment(self):
        """Complete C{self.equipment} with data from EDP."""
        # Core EDP
        for port in self.edpSysName:
            self.equipment.ports[port].edp = \
                Edp(self.edpSysName[port],
                    int(self.edpRemoteSlot[port]),
                    int(self.edpRemotePort[port]))
        # Vlans
        for vid, port in self.vlan:
            self.equipment.ports[port].vlan.append(

                RemoteVlan(vid, self.vlan[vid, port]))