/** * PROXY METHOD: do not delete until {@link OnmsGeolocation} is truly a separate table, or projection mapping will fail. */ @Transient @Deprecated @XmlElement public String getState() { return m_geolocation == null ? null : m_geolocation.getState(); }
@Override public ItemProvider<String> getItemProvider() { return node -> node.getAssetRecord().getGeolocation().getState(); } }),
.add("address2", m_geolocation == null ? null : m_geolocation.getAddress2()) .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())
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; } }
setZip(mergeWith.getZip()); setCountry(mergeWith.getCountry()); setState(mergeWith.getState());