Index: DCWoRMS/trunk/src/test/DEBBTranslator/src/DEBB2DCWoRMSTranslator.java
===================================================================
--- DCWoRMS/trunk/src/test/DEBBTranslator/src/DEBB2DCWoRMSTranslator.java	(revision 567)
+++ DCWoRMS/trunk/src/test/DEBBTranslator/src/DEBB2DCWoRMSTranslator.java	(revision 568)
@@ -25,4 +25,5 @@
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
 import org.xml.sax.SAXException;
 
@@ -51,4 +52,5 @@
 
 	private static HashMap<String, String> computingResourceClasses = null;
+	private static HashMap<String, String> resourceUnitClasses;
 
 	/**
@@ -164,4 +166,12 @@
 		computingResourceClasses.put("NodeGroup", "NodeGroup");
 		computingResourceClasses.put("Node", "Node");
+		computingResourceClasses.put("Processor", "Processor");
+		
+		resourceUnitClasses = new HashMap<String, String>();
+		resourceUnitClasses.put("Sensor", "Sensor");
+		resourceUnitClasses.put("Memory", "Memory");
+		resourceUnitClasses.put("Baseboard", "Baseboard");
+		resourceUnitClasses.put("CoolingDevice", "CoolingDevice");
+		resourceUnitClasses.put("Storage", "Storage");
 
 	}
@@ -419,4 +429,127 @@
 			// Read data from DEBBComponent file(s)
 			Document debbComponentDocument = readDEBBComponentInputFile(debbComponentFileName);
+			System.out.println(debbComponentIdNode.getNodeValue());
+			expr = xpath.compile("//*[ComponentId='"
+					+ debbComponentIdNode.getNodeValue() + "']");
+			result = expr.evaluate(debbComponentDocument, XPathConstants.NODE);
+			Node debbComponentNode = (Node) result;
+			if (debbComponentNode != null) {
+				System.out.println("id=" + debbComponentNode.getNodeName());
+
+				//	Get all baseboards
+				expr = xpath.compile("Baseboard");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList baseboardNodeList = (NodeList) result;
+				if (baseboardNodeList != null) {
+					for (int i = 0; i < baseboardNodeList.getLength(); i++) {
+						Node baseboardNode = baseboardNodeList.item(i);
+
+						Element resourceUnitElement = dcwormsDocument
+								.createElement("resourceUnit");
+						Attr baseboardClassAttribute = dcwormsDocument.createAttribute("class");
+						baseboardClassAttribute.setValue(resourceUnitClasses.get(baseboardNode.getNodeName()));
+						resourceUnitElement.setAttributeNode(baseboardClassAttribute);
+						computingResourceElement
+								.appendChild(resourceUnitElement);
+					}
+				}
+				
+				//	Get all memory units
+				expr = xpath.compile("Memory");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList memoryNodeList = (NodeList) result;
+				if (memoryNodeList != null) {
+					for (int i = 0; i < memoryNodeList.getLength(); i++) {
+						Node memoryNode = memoryNodeList.item(i);
+
+						Element resourceUnitElement = dcwormsDocument
+								.createElement("resourceUnit");
+						Attr memoryClassAttribute = dcwormsDocument.createAttribute("class");
+						memoryClassAttribute.setValue(resourceUnitClasses.get(memoryNode.getNodeName()));
+						resourceUnitElement.setAttributeNode(memoryClassAttribute);
+						computingResourceElement
+								.appendChild(resourceUnitElement);
+					}
+				}
+
+				//	Get all storages
+				expr = xpath.compile("Storage");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList storageNodeList = (NodeList) result;
+				if (storageNodeList != null) {
+					for (int i = 0; i < storageNodeList.getLength(); i++) {
+						Node storageNode = storageNodeList.item(i);
+
+						Element resourceUnitElement = dcwormsDocument
+								.createElement("resourceUnit");
+						Attr storageClassAttribute = dcwormsDocument.createAttribute("class");
+						storageClassAttribute.setValue(resourceUnitClasses.get(storageNode.getNodeName()));
+						resourceUnitElement.setAttributeNode(storageClassAttribute);
+						computingResourceElement
+								.appendChild(resourceUnitElement);
+					}
+				}
+				
+				// Get all sensors				
+				expr = xpath.compile("Sensor");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList sensorsNodeList = (NodeList) result;
+				if (sensorsNodeList != null) {
+					for (int i = 0; i < sensorsNodeList.getLength(); i++) {
+						Node sensorNode = sensorsNodeList.item(i);
+
+						Element resourceUnitElement = dcwormsDocument
+								.createElement("resourceUnit");
+						Attr sensorClassAttribute = dcwormsDocument.createAttribute("class");
+						sensorClassAttribute.setValue(resourceUnitClasses.get(sensorNode.getNodeName()));
+						resourceUnitElement.setAttributeNode(sensorClassAttribute);
+						computingResourceElement
+								.appendChild(resourceUnitElement);
+					}
+				}
+				
+				//	Get all cooling devices
+				expr = xpath.compile("CoolingDevice");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList coolingDeviceNodeList = (NodeList) result;
+				if (coolingDeviceNodeList != null) {
+					for (int i = 0; i < coolingDeviceNodeList.getLength(); i++) {
+						Node coolingDeviceNode = coolingDeviceNodeList.item(i);
+
+						Element resourceUnitElement = dcwormsDocument
+								.createElement("resourceUnit");
+						Attr coolingDeviceClassAttribute = dcwormsDocument.createAttribute("class");
+						coolingDeviceClassAttribute.setValue(resourceUnitClasses.get(coolingDeviceNode.getNodeName()));
+						resourceUnitElement.setAttributeNode(coolingDeviceClassAttribute);
+						computingResourceElement
+								.appendChild(resourceUnitElement);
+					}
+				}
+			
+				//	Get all processors
+				expr = xpath.compile("Processor");
+				result = expr.evaluate(debbComponentNode,
+						XPathConstants.NODESET);
+				NodeList processorNodeList = (NodeList) result;
+				if (processorNodeList != null) {
+					for (int i = 0; i < processorNodeList.getLength(); i++) {
+						Node processorNode = processorNodeList.item(i);
+
+						Element processorElement = dcwormsDocument
+								.createElement("computingResource");
+						Attr processorClassAttribute = dcwormsDocument.createAttribute("class");
+						processorClassAttribute.setValue(computingResourceClasses.get(processorNode.getNodeName()));
+						processorElement.setAttributeNode(processorClassAttribute);
+						computingResourceElement
+								.appendChild(processorElement);
+					}
+				}
+				
+			}
 
 			// Find component
