public static AddressView convert(Address address) { if (address == null) return null; AddressView view = new AddressView(); view.setId(address.getId()); view.setCompanyId(address.getCompanyId()); view.setProvince(address.getProvince()); view.setCity(address.getCity()); view.setRegion(address.getRegion()); view.setStreet(address.getStreet()); view.setAddress(address.getAddress()); return view; }