@Override public List<Address> findAddressOfOwnerByNameStartsWith(String name, Integer ownerId) { if (checkOwner) { return addressDAO.findAddressesOfOwnerByCategoryAndLastNameOrCompanyStartsWith( ownerId, category, name); } else { return addressDAO.findAddressesByCategoryAndNameOrCompanyStartsWith(category, name); } }
@Override public List<Address> findAddressByNameStartsWith(String name) { return addressDAO.findAddressesByCategoryAndNameOrCompanyStartsWith(category, name); }