daemon: renamed LinkData.link_type to LinkData.type and removed LinkOptions.type to remove redundant information, link_type param added to session.add_link, delete_link, and update_link functions
This commit is contained in:
parent
a29a7a5582
commit
351b99aae0
10 changed files with 37 additions and 28 deletions
|
@ -1109,9 +1109,9 @@ class CoreNetworkBase(NodeBase):
|
|||
options_data = iface.get_link_options(unidirectional)
|
||||
link_data = LinkData(
|
||||
message_type=flags,
|
||||
type=self.linktype,
|
||||
node1_id=self.id,
|
||||
node2_id=linked_node.id,
|
||||
link_type=self.linktype,
|
||||
iface2=iface2,
|
||||
options=options_data,
|
||||
)
|
||||
|
@ -1123,9 +1123,9 @@ class CoreNetworkBase(NodeBase):
|
|||
options_data = iface.get_link_options(unidirectional)
|
||||
link_data = LinkData(
|
||||
message_type=MessageFlags.NONE,
|
||||
type=self.linktype,
|
||||
node1_id=linked_node.id,
|
||||
node2_id=self.id,
|
||||
link_type=self.linktype,
|
||||
options=options_data,
|
||||
)
|
||||
iface.swapparams("_params_up")
|
||||
|
|
|
@ -923,9 +923,9 @@ class PtpNet(CoreNetwork):
|
|||
options_data = iface1.get_link_options(unidirectional)
|
||||
link_data = LinkData(
|
||||
message_type=flags,
|
||||
type=self.linktype,
|
||||
node1_id=iface1.node.id,
|
||||
node2_id=iface2.node.id,
|
||||
link_type=self.linktype,
|
||||
iface1=iface1_data,
|
||||
iface2=iface2_data,
|
||||
options=options_data,
|
||||
|
@ -940,7 +940,7 @@ class PtpNet(CoreNetwork):
|
|||
options_data = iface2.get_link_options(unidirectional)
|
||||
link_data = LinkData(
|
||||
message_type=MessageFlags.NONE,
|
||||
link_type=self.linktype,
|
||||
type=self.linktype,
|
||||
node1_id=iface2.node.id,
|
||||
node2_id=iface1.node.id,
|
||||
iface1=iface1_data,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue