uInfo.getMigrationStatus() +
"</migrationStatus>");
// copy over the TypeMap object
sInfoBuffer.append("<properties>");
TypeMap tMap = uInfo.getProperties();
String[] mapKeys = tMap.getAllKeys();
for (int j = 0; j < mapKeys.length; j++) {
sInfoBuffer.append("<propertiesEntry>");
sInfoBuffer.append("<key>" +
mapKeys[j] +
"</key>");
sInfoBuffer.append("<type>" +
TypeUtil.toString(tMap.typeOf(mapKeys[j])) +
"</type>");
sInfoBuffer.append("<value>" +
tMap.getAsString(mapKeys[j]) +
"</value>");
sInfoBuffer.append("</propertiesEntry>");
}
sInfoBuffer.append("</properties>");
// copy over information from the ConnectionID
XCATConnectionID connID = uInfo.getConnectionID();
if (connID != null) {
sInfoBuffer.append("<connectionID>");
sInfoBuffer.append("<providerIntfName>" +
connID.getProviderIntfName() +
"</providerIntfName>");
sInfoBuffer.append("<userIntfName>" +
connID.getUserIntfName() +
"</userIntfName>");
// fill in the state of the connection
sInfoBuffer.append("<connectionIDInfo>");
XCATConnectionInfo xconnInfo = connID.getConnectionInfo();
sInfoBuffer.append("<providerIDHandle>" +
xconnInfo.getProviderIDHandle() +
"</providerIDHandle>");
sInfoBuffer.append("<userIDHandle>" +
xconnInfo.getUserIDHandle() +
"</userIDHandle>");
sInfoBuffer.append("<providerName>" +
xconnInfo.getProviderName() +
"</providerName>");
sInfoBuffer.append("<userName>" +
xconnInfo.getUserName() +
"</userName>");
sInfoBuffer.append("<providerPortName>" +
xconnInfo.getProviderPortName() +
"</providerPortName>");
sInfoBuffer.append("<userPortName>" +
xconnInfo.getUserPortName() +
"</userPortName>");
sInfoBuffer.append("<providesPortHandle>" +
xconnInfo.getProvidesPortHandle() +
"</providesPortHandle>");
sInfoBuffer.append("</connectionIDInfo>");
sInfoBuffer.append("</connectionID>");
}
sInfoBuffer.append("</usesPortRecord>");
sInfoBuffer.append("</usesPortEntry>");
}
sInfoBuffer.append("</usesPortMap>");
// create a list of WS ports
sInfoBuffer.append("<wsPortMap>");
Object[] wsKeys = wsPortMap.keySet().toArray();
// add an entry for every ws port
for (int i = 0; i < wsKeys.length; i++) {
// create an entry for each Ws Port
sInfoBuffer.append("<wsPortEntry>");
sInfoBuffer.append("<portName>" +
(String) wsKeys[i] +
"</portName>");
// copy over information from WSPortInfo to WsPortRecord
WSPortInfo wInfo = (WSPortInfo) wsPortMap.get(wsKeys[i]);
sInfoBuffer.append("<wsPortRecord>");
sInfoBuffer.append("<portName>" +
wInfo.getPortName() +
"</portName>");
sInfoBuffer.append("<portType>" +
wInfo.getPortType() +
"</portType>");
sInfoBuffer.append("<inUse>" +
false +
"</inUse>"); // inUse is always false before & after migration
sInfoBuffer.append("<unregistered>" +
wInfo.isUnregistered() +
"</unregistered>");
if (wInfo.isConnected())
sInfoBuffer.append("<endPointLocation>" +
wInfo.getEndPointLocation() +
"</endPointLocation>");
// copy over the TypeMap object
sInfoBuffer.append("<properties>");
TypeMap tMap = wInfo.getProperties();
String[] mapKeys = tMap.getAllKeys();
for (int j = 0; j < mapKeys.length; j++) {
sInfoBuffer.append("<propertiesEntry>");
sInfoBuffer.append("<key>" +
mapKeys[j] +
"</key>");
sInfoBuffer.append("<type>" +
TypeUtil.toString(tMap.typeOf(mapKeys[j])) +
"</type>");
sInfoBuffer.append("<value>" +
tMap.getAsString(mapKeys[j]) +
"</value>");
sInfoBuffer.append("</propertiesEntry>");
}
sInfoBuffer.append("</properties>");
// end of wsPortRecord
sInfoBuffer.append("</wsPortRecord>");
sInfoBuffer.append("</wsPortEntry>");
}
sInfoBuffer.append("</wsPortMap>");
// create a list of provides ports
sInfoBuffer.append("<providesPortMap>");
Object[] providerKeys = providesPortMap.keySet().toArray();
// add an entry for every provides port
for (int i = 0; i < providerKeys.length; i++) {
// create a entry for a Provides Port
sInfoBuffer.append("<providesPortEntry>");
sInfoBuffer.append("<portName>" +
(String) providerKeys[i] +
"</portName>");
// copy over information from ProvidesPortInfo
sInfoBuffer.append("<providesPortRecord>");
ProvidesPortInfo pInfo = (ProvidesPortInfo) providesPortMap.get(providerKeys[i]);
sInfoBuffer.append("<portName>" +
pInfo.getPortName() +
"</portName>");
sInfoBuffer.append("<portType>" +
pInfo.getPortType() +
"</portType>");
sInfoBuffer.append("<inUse>" +
pInfo.getInUse() +
"</inUse>");
sInfoBuffer.append("<numConnections>" +
pInfo.getNumConnections() +
"</numConnections>");
sInfoBuffer.append("<providesPortHandle>" +
pInfo.getProvidesPortHandle() +
"</providesPortHandle>");
sInfoBuffer.append("<removed>" +
pInfo.isRemoved() +
"</removed>");
// copy over the TypeMap object
sInfoBuffer.append("<properties>");
TypeMap tMap = pInfo.getProperties();
String[] mapKeys = tMap.getAllKeys();
for (int j = 0; j < mapKeys.length; j++) {
sInfoBuffer.append("<propertiesEntry>");
sInfoBuffer.append("<key>" +
mapKeys[j] +
"</key>");
sInfoBuffer.append("<type>" +
TypeUtil.toString(tMap.typeOf(mapKeys[j])) +
"</type>");
sInfoBuffer.append("<value>" +
tMap.getAsString(mapKeys[j]) +
"</value>");
sInfoBuffer.append("</propertiesEntry>");
}
sInfoBuffer.append("</properties>");