@Test public void testEquals() { BgpNeighborSourceInterface bgpNeighborSourceInterface = new BgpNeighborSourceInterface("lo"); new EqualsTester() .addEqualityGroup(bgpNeighborSourceInterface, new BgpNeighborSourceInterface("lo")) .addEqualityGroup(new BgpNeighborSourceInterface("iface")) .testEquals(); }
@Override public boolean equals(Object o) { if (o == this) { return true; } else if (!(o instanceof BgpNeighborSourceInterface)) { return false; } BgpNeighborSourceInterface other = (BgpNeighborSourceInterface) o; return _ifaceName.equals(other._ifaceName); }
BgpNeighborSourceInterface implements BgpNeighborSource { @Override public boolean equals(Object o) { if (o == this) { return true; } else if (!(o instanceof BgpNeighborSourceInterface)) { return false; } BgpNeighborSourceInterface other = (BgpNeighborSourceInterface) o; return _ifaceName.equals(other._ifaceName); } }
BgpNeighborSourceInterface implements BgpNeighborSource { @Override public boolean equals(Object o) { if (o == this) { return true; } else if (!(o instanceof BgpNeighborSourceInterface)) { return false; } BgpNeighborSourceInterface other = (BgpNeighborSourceInterface) o; return _ifaceName.equals(other._ifaceName); } BgpNeighborSourceInterface(@Nonnull String ifaceName); }
BgpNeighborSourceInterface implements BgpNeighborSource { @Override public boolean equals(Object o) { if (o == this) { return true; } else if (!(o instanceof BgpNeighborSourceInterface)) { return false; } BgpNeighborSourceInterface other = (BgpNeighborSourceInterface) o; return _ifaceName.equals(other._ifaceName); } BgpNeighborSourceInterface(@Nonnull String ifaceName); @Nonnull String getInterface(); @Override T accept(BgpNeighborSourceVisitor<T> visitor); @Override boolean equals(Object o); @Override int hashCode(); }
BgpNeighborSourceInterface implements BgpNeighborSource { @Override public boolean equals(Object o) { if (o == this) { return true; } else if (!(o instanceof BgpNeighborSourceInterface)) { return false; } BgpNeighborSourceInterface other = (BgpNeighborSourceInterface) o; return _ifaceName.equals(other._ifaceName); } BgpNeighborSourceInterface(@Nonnull String ifaceName); @Nonnull String getInterface(); @Override T accept(BgpNeighborSourceVisitor<T> visitor); @Override boolean equals(Object o); @Override int hashCode();  }