@Test public void testEquals() { TransitGatewayOptions opt1 = new TransitGatewayOptions( 64512L, true, "tgw-rtb-0fa40c8df355dce6e", true, "tgw-rtb-0fa40c8df355dce6e", true); TransitGatewayOptions opt2 = new TransitGatewayOptions( 64513L, true, "tgw-rtb-0fa40c8df355dce6e", true, "tgw-rtb-0fa40c8df355dce6e", true); TransitGateway tgw = new TransitGateway("gid", opt1, "owner", ImmutableMap.of()); new EqualsTester() .addEqualityGroup(tgw, tgw, new TransitGateway("gid", opt1, "owner", ImmutableMap.of())) .addEqualityGroup(new TransitGateway("gid2", opt1, "owner", ImmutableMap.of())) .addEqualityGroup(new TransitGateway("gid", opt2, "owner", ImmutableMap.of())) .addEqualityGroup(new TransitGateway("gid", opt1, "other_owner", ImmutableMap.of())) .addEqualityGroup( new TransitGateway("gid", opt1, "owner", ImmutableMap.of("Name", "Value"))) .testEquals(); }
@Override public boolean equals(@Nullable Object o) { if (this == o) { return true; } if (!(o instanceof TransitGateway)) { return false; } TransitGateway that = (TransitGateway) o; return _gatewayId.equals(that._gatewayId) && _options.equals(that._options) && _ownerId.equals(that._ownerId) && _tags.equals(that._tags); }
TransitGateway implements AwsVpcEntity, Serializable { @Override public boolean equals(@Nullable Object o) { if (this == o) { return true; } if (!(o instanceof TransitGateway)) { return false; } TransitGateway that = (TransitGateway) o; return _gatewayId.equals(that._gatewayId) && _options.equals(that._options) && _ownerId.equals(that._ownerId) && _tags.equals(that._tags); } }
TransitGateway implements AwsVpcEntity, Serializable { @Override public boolean equals(@Nullable Object o) { if (this == o) { return true; } if (!(o instanceof TransitGateway)) { return false; } TransitGateway that = (TransitGateway) o; return _gatewayId.equals(that._gatewayId) && _options.equals(that._options) && _ownerId.equals(that._ownerId) && _tags.equals(that._tags); } TransitGateway(
      String gatewayId, TransitGatewayOptions options, String ownerId, Map<String, String> tags); }
TransitGateway implements AwsVpcEntity, Serializable { @Override public boolean equals(@Nullable Object o) { if (this == o) { return true; } if (!(o instanceof TransitGateway)) { return false; } TransitGateway that = (TransitGateway) o; return _gatewayId.equals(that._gatewayId) && _options.equals(that._options) && _ownerId.equals(that._ownerId) && _tags.equals(that._tags); } TransitGateway(
      String gatewayId, TransitGatewayOptions options, String ownerId, Map<String, String> tags); @Nonnull TransitGatewayOptions getOptions(); @Override String getId(); @Nonnull String getOwnerId(); @Override boolean equals(@Nullable Object o); @Override int hashCode(); }
TransitGateway implements AwsVpcEntity, Serializable { @Override public boolean equals(@Nullable Object o) { if (this == o) { return true; } if (!(o instanceof TransitGateway)) { return false; } TransitGateway that = (TransitGateway) o; return _gatewayId.equals(that._gatewayId) && _options.equals(that._options) && _ownerId.equals(that._ownerId) && _tags.equals(that._tags); } TransitGateway(
      String gatewayId, TransitGatewayOptions options, String ownerId, Map<String, String> tags); @Nonnull TransitGatewayOptions getOptions(); @Override String getId(); @Nonnull String getOwnerId(); @Override boolean equals(@Nullable Object o); @Override int hashCode();  }