### Question:
Address extends Base implements WithKey { public boolean equalsIgnoreId(final Address address) { return address != null && address.withId(null).equals(withId(null)); } @JsonCreator private  Address(final CountryCode country, @Nullable final String id,@Nullable final String key, @Nullable final String title, @Nullable final String salutation, @Nullable final String firstName, @Nullable final String lastName, @Nullable final String streetName, @Nullable final String streetNumber, @Nullable final String additionalStreetInfo, @Nullable final String postalCode, @Nullable final String city, @Nullable final String region, @Nullable final String state, @Nullable final String company, @Nullable final String department, @Nullable final String building, @Nullable final String apartment, @Nullable final String poBox, @Nullable final String phone, @Nullable final String mobile, @Nullable final String email, @Nullable final String additionalAddressInfo, @Nullable final String fax, @Nullable final String externalId); @JsonIgnore  Address(final AddressBuilder builder); CountryCode getCountry(); @Nullable String getId(); @Nullable String getTitle(); @Nullable String getSalutation(); @Nullable String getFirstName(); @Nullable String getLastName(); @Nullable String getStreetName(); @Nullable String getStreetNumber(); @Nullable String getAdditionalStreetInfo(); @Nullable String getPostalCode(); @Nullable String getCity(); @Nullable String getRegion(); @Nullable String getState(); @Nullable String getCompany(); @Nullable String getDepartment(); @Nullable String getBuilding(); @Nullable String getApartment(); @Nullable String getPoBox(); @Nullable String getPhone(); @Nullable String getMobile(); @Nullable String getEmail(); @Nullable String getAdditionalAddressInfo(); @Nullable String getFax(); @Nullable String getExternalId(); @Override @Nullable String getKey(); Address withCountry(final CountryCode country); Address withId(@Nullable final String id); Address withKey(@Nullable final String key); Address withTitle(@Nullable final String title); Address withSalutation(@Nullable final String salutation); Address withFirstName(@Nullable final String firstName); Address withLastName(@Nullable final String lastName); Address withStreetName(@Nullable final String streetName); Address withStreetNumber(@Nullable final String streetNumber); Address withAdditionalStreetInfo(@Nullable final String additionalStreetInfo); Address withPostalCode(@Nullable final String postalCode); Address withCity(@Nullable final String city); Address withRegion(@Nullable final String region); Address withState(@Nullable final String state); Address withCompany(@Nullable final String company); Address withDepartment(@Nullable final String department); Address withBuilding(@Nullable final String building); Address withApartment(@Nullable final String apartment); Address withPoBox(@Nullable final String poBox); Address withPhone(@Nullable final String phone); Address withMobile(@Nullable final String mobile); Address withEmail(@Nullable final String email); Address withAdditionalAddressInfo(@Nullable final String additionalAddressInfo); Address withFax(@Nullable final String fax); Address withExternalId(@Nullable final String externalId); static Address of(final CountryCode country); @Override String toString(); boolean equalsIgnoreId(final Address address);  }### Answer:
@Test public void equalsIgnoreId() { final Address addressWithoutId = Address.of(CountryCode.DE); final Address addressWithId = addressWithoutId.withId("foo"); assertThat(addressWithoutId) .isNotEqualTo(addressWithId) .matches(address -> address.equalsIgnoreId(addressWithId)); }