private void loadFrom(HL7ApplicationInfo hl7AppInfo, Attributes attrs, String deviceName) throws NamingException, ConfigurationException { hl7AppInfo.setDeviceName(deviceName); hl7AppInfo.setHl7ApplicationName( LdapUtils.stringValue(attrs.get("hl7ApplicationName"), null)); hl7AppInfo.setHl7OtherApplicationName( LdapUtils.stringArray(attrs.get("hl7OtherApplicationName"))); hl7AppInfo.setDescription( LdapUtils.stringValue(attrs.get("dicomDescription"), null)); hl7AppInfo.setApplicationClusters(LdapUtils.stringArray(attrs.get("dicomApplicationCluster"))); hl7AppInfo.setInstalled( LdapUtils.booleanValue(attrs.get("dicomInstalled"), null)); for (String connDN : LdapUtils.stringArray(attrs.get("dicomNetworkConnectionReference"))) hl7AppInfo.getConnections().add(config.findConnection(connDN)); }
public void writeTo(HL7ApplicationInfo hl7AppInfo, JsonGenerator gen) { JsonWriter writer = new JsonWriter(gen); gen.writeStartObject(); writer.writeNotNullOrDef("dicomDeviceName", hl7AppInfo.getDeviceName(), null); writer.writeNotNullOrDef("hl7ApplicationName", hl7AppInfo.getHl7ApplicationName(), null); writer.writeNotEmpty("hl7OtherApplicationName", hl7AppInfo.getHl7OtherApplicationName()); writer.writeNotNullOrDef("dicomDescription", hl7AppInfo.getDescription(), null); writer.writeNotEmpty("dicomApplicationCluster", hl7AppInfo.getApplicationClusters()); writer.writeNotNull("dicomInstalled", hl7AppInfo.getInstalled()); writeNotExtendedConns(hl7AppInfo.getConnections(), writer); gen.writeEnd(); }
public void writeTo(HL7ApplicationInfo hl7AppInfo, JsonGenerator gen) { JsonWriter writer = new JsonWriter(gen); gen.writeStartObject(); writer.writeNotNullOrDef("dicomDeviceName", hl7AppInfo.getDeviceName(), null); writer.writeNotNullOrDef("hl7ApplicationName", hl7AppInfo.getHl7ApplicationName(), null); writer.writeNotEmpty("hl7OtherApplicationName", hl7AppInfo.getHl7OtherApplicationName()); writer.writeNotNullOrDef("dicomDescription", hl7AppInfo.getDescription(), null); writer.writeNotEmpty("dicomApplicationCluster", hl7AppInfo.getApplicationClusters()); writer.writeNotNull("dicomInstalled", hl7AppInfo.getInstalled()); writeNotExtendedConns(hl7AppInfo.getConnections(), writer); gen.writeEnd(); }