-from sfa.rspec.elements.interface import Interface
+from sfa.rspecs.elements.element import Element
-class Link:
- def __init__(self):
- self.component_id = None
- self.component_name = None
- self.component_manager_id = None
- self.type = None
- self.endpoint1 = Interface()
- self.endpoint2 = Interface()
- self.capacity = None
- self.latency = None
- self.packet_loss = None
- self.description = None
+
+class Link(Element):
+ fields = [
+ 'client_id',
+ 'component_id',
+ 'component_name',
+ 'component_manager',
+ 'type',
+ 'interface1',
+ 'interface2',
+ 'capacity',
+ 'latency',
+ 'packet_loss',
+ 'description',
+ ]