/** * PROXY METHOD: do not delete until {@link OnmsGeolocation} is truly a separate table, or projection mapping will fail. */ @Transient @Deprecated @XmlElement public String getZip() { return m_geolocation == null ? null : m_geolocation.getZip(); }
@Override public ItemProvider<String> getItemProvider() { return node -> node.getAssetRecord().getGeolocation().getZip(); } }),
.add("city", m_geolocation == null ? null : m_geolocation.getCity()) .add("state", m_geolocation == null ? null : m_geolocation.getState()) .add("zip", m_geolocation == null ? null : m_geolocation.getZip()) .add("country", m_geolocation == null ? null : m_geolocation.getCountry()) .add("longitude", m_geolocation == null ? null : m_geolocation.getLongitude())
private static AddressInfo toAddressInfo(OnmsGeolocation input) { if (input != null) { AddressInfo addressInfo = new AddressInfo(); addressInfo.setAddress1(input.getAddress1()); addressInfo.setAddress2(input.getAddress2()); addressInfo.setCity(input.getCity()); addressInfo.setCountry(input.getCountry()); addressInfo.setState(input.getState()); addressInfo.setZip(input.getZip()); return addressInfo; } return null; } }
private static AddressInfo toAddressInfo(OnmsGeolocation input) { if (input != null) { AddressInfo addressInfo = new AddressInfo(); addressInfo.setAddress1(input.getAddress1()); addressInfo.setAddress2(input.getAddress2()); addressInfo.setCity(input.getCity()); addressInfo.setCountry(input.getCountry()); addressInfo.setState(input.getState()); addressInfo.setZip(input.getZip()); return addressInfo; } return null; } }
setAddress1(mergeWith.getAddress1()); setAddress2(mergeWith.getAddress2()); setZip(mergeWith.getZip()); setCountry(mergeWith.getCountry()); setState(mergeWith.getState());