@Test public void testEquals() { MacAddress macAddress = of(0L); new EqualsTester() .addEqualityGroup(new Object()) .addEqualityGroup(macAddress, macAddress, of(0L)) .addEqualityGroup(of(0x012345ABCDEFL)) .addEqualityGroup(of(0xFFFFFFFFFFFFL)) .testEquals(); }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof MacAddress)) { return false; } return _longVal == ((MacAddress) obj)._longVal; }
MacAddress implements Comparable<MacAddress>, Serializable { @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof MacAddress)) { return false; } return _longVal == ((MacAddress) obj)._longVal; } }
MacAddress implements Comparable<MacAddress>, Serializable { @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof MacAddress)) { return false; } return _longVal == ((MacAddress) obj)._longVal; } private  MacAddress(long longVal); }
MacAddress implements Comparable<MacAddress>, Serializable { @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof MacAddress)) { return false; } return _longVal == ((MacAddress) obj)._longVal; } private  MacAddress(long longVal); static @Nonnull MacAddress of(long longVal); static @Nonnull MacAddress parse(String macAddressStr); long asLong(); @Override int compareTo(MacAddress o); @Override boolean equals(Object obj); @Override int hashCode(); @JsonValue @Override @Nonnull String toString(); }
MacAddress implements Comparable<MacAddress>, Serializable { @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof MacAddress)) { return false; } return _longVal == ((MacAddress) obj)._longVal; } private  MacAddress(long longVal); static @Nonnull MacAddress of(long longVal); static @Nonnull MacAddress parse(String macAddressStr); long asLong(); @Override int compareTo(MacAddress o); @Override boolean equals(Object obj); @Override int hashCode(); @JsonValue @Override @Nonnull String toString();  }