diff options
Diffstat (limited to 'core/sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/slitopologyutils/topology/PInterface.java')
-rw-r--r-- | core/sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/slitopologyutils/topology/PInterface.java | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/core/sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/slitopologyutils/topology/PInterface.java b/core/sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/slitopologyutils/topology/PInterface.java new file mode 100644 index 000000000..6b111871d --- /dev/null +++ b/core/sliPluginUtils/provider/src/main/java/org/onap/ccsdk/sli/core/slipluginutils/slitopologyutils/topology/PInterface.java @@ -0,0 +1,36 @@ +package org.onap.ccsdk.sli.core.slipluginutils.slitopologyutils.topology; + +import java.util.Objects; + +public class PInterface { + + private final String pnfName; + private final PInterfaceName pInterfaceName; + + public PInterface(String pnfName, PInterfaceName pInterfaceName){ + this.pnfName = pnfName; + this.pInterfaceName = pInterfaceName; + } + + public PInterfaceName pInterfaceName() { + return pInterfaceName; + } + + @Override + public int hashCode(){ + return Objects.hash(pnfName, pInterfaceName); + } + + @Override + public boolean equals(Object o){ + if (this == o){ + return true; + } + if (o instanceof PInterface){ + final PInterface other = (PInterface) o; + return Objects.equals(this.pnfName, other.pnfName) && + Objects.equals(this.pInterfaceName, other.pInterfaceName); + } + return false; + } +} |