Skip to content
This repository has been archived by the owner on Apr 22, 2024. It is now read-only.

Create from_dict method for Interface, UNI, Switch and Link #1045

Merged
merged 3 commits into from Apr 30, 2021

Conversation

cmagnobarbosa
Copy link
Member

@cmagnobarbosa cmagnobarbosa commented Mar 30, 2020

Some classes, like Interface, UNI, Switch and Link do not have a from_dict method. This commit solves this problem.

Related #1043

@gleybersonandrade
Copy link
Contributor

Related: #1043

Copy link
Member

@hdiogenes hdiogenes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As we've discussed in the last meeting, this approach will have the downside of creating many instances of the same Interface object (with different values for the available_tags attribute, for example).

On the other hand, this is the approach which is already being done in some NApps, so at least we can centralize the logic here, and when we fix this it'll be fixed for all NApps that depend upon it.

@cmagnobarbosa cmagnobarbosa marked this pull request as draft October 28, 2020 15:23
@cmagnobarbosa cmagnobarbosa marked this pull request as ready for review April 30, 2021 13:40
cmagnobarbosa and others added 3 commits April 30, 2021 12:53
Some classes, like Interface and UNI, do not have a from_dict method. This commit solves this problem.
@hdiogenes hdiogenes merged commit 67f3b52 into kytos:master Apr 30, 2021
@cmagnobarbosa cmagnobarbosa deleted the switch_from_dict branch April 30, 2021 15:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants