[jboss-svn-commits] JBL Code SVN: r8063 - in labs/jbossesb/trunk/product: core/listeners/src/org/jboss/soa/esb core/rosetta/src/org/jboss/soa/esb/common core/rosetta/src/org/jboss/soa/esb/services core/rosetta/src/org/jboss/soa/esb/util core/rosetta/tests/src/org/jboss/soa/esb/common core/rosetta/tests/src/org/jboss/soa/esb/common/tests core/rosetta/tests/src/org/jboss/soa/esb/util docs

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Tue Dec 5 07:12:58 EST 2006


Author: mark.little at jboss.com
Date: 2006-12-05 07:12:49 -0500 (Tue, 05 Dec 2006)
New Revision: 8063

Removed:
   labs/jbossesb/trunk/product/core/listeners/src/org/jboss/soa/esb/nagios/
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/bizclasses/
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/BatchManager.java
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/PersistManager.java
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BaseBusinessObject.java
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BobjStdDTO.java
   labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/NagiosStandaloneHeartbeat.java
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/common/bizclasses/
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/common/tests/bizclasses/
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest.java
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest_testfile1.xml
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest.java
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest_testfile1.xml
   labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/TestBob.java
Modified:
   labs/jbossesb/trunk/product/docs/ProgrammersGuide.odt
Log:
Begun pruning dead code.

Deleted: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/BatchManager.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/BatchManager.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/BatchManager.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,35 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-
-
-
-package org.jboss.soa.esb.services;
-
-import org.jboss.soa.esb.common.bizclasses.BatchProcess;
-
-public interface BatchManager
-{
-  public long   newBatch    ()                  throws Exception;
-  public int    addToBatch  (String p_s)        throws Exception;
-  public void   finish      ()                  throws Exception;
-  public void   commitBatch(BatchProcess p_oBP) throws Exception;
-} //____________________________________________________________________________

Deleted: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/PersistManager.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/PersistManager.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/PersistManager.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,40 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-
-
-package org.jboss.soa.esb.services;
-
-import java.util.Properties;
-
-import org.jboss.soa.esb.util.BaseBusinessObject;
-import org.jboss.soa.esb.util.ObjLocator;
-
-public interface PersistManager
-{
-  public long getUidChunk(int p_iHowMany) throws Exception;
-  public ObjLocator[] getLocatorList(Class p_oCls,Properties p_oProp) throws Exception;
-
-  public long addObject(BaseBusinessObject p_oQ)      throws Exception;
-  public BaseBusinessObject getObject(Class p_oCls,long p_lUid) throws Exception;
-  public void rplObject(BaseBusinessObject p_o)       throws Exception;
-  public void rmvObject(Class p_oCls,long p_lUid) throws Exception;
-} //____________________________________________________________________________

Deleted: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BaseBusinessObject.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BaseBusinessObject.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BaseBusinessObject.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,298 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.soa.esb.util;
-
-import java.lang.reflect.Constructor;
-import java.util.ArrayList;
-import java.util.EnumMap;
-import java.util.List;
-
-public abstract class BaseBusinessObject {
-	
-	public BobjStdDTO toDTO() throws Exception {
-		String sClass = getClass().getSimpleName();
-		BobjStdDTO oRet = new BobjStdDTO(sClass, getElemNm(), null);
-		if (hasUid())
-			try {
-				oRet.addAttr(HIDDEN.uid.toString(), Long.toString(m_lUid));
-			} catch (Exception e) {
-			}
-		putStdAtts(oRet);
-		return oRet;
-	}
-
-	public String toString() {
-		try {
-			return this.toDTO().toXml();
-		} catch (Exception e) {
-			return null;
-		}
-	} // __________________________________
-
-	public String[] locator() {
-		return new String[] {};
-	}
-
-	/**
-	 * Get all locators for a given BaseBusinessObject
-	 * <p />
-	 * Override this method in your class if you have more than 1 locator array
-	 * 
-	 * @return An array of String arrays containing all locators
-	 */
-	public String[][] allLocators() {
-		return new String[][] { locator() };
-	}
-
-	private enum ATTRIB {
-		elem, rol
-	};
-
-	enum HIDDEN {
-		uid, stamp, type, snap, dtSnap, batch
-	};
-
-	private EnumMap<ATTRIB, String> m_oData;
-
-	private String setField(ATTRIB pKey, String pVal) {
-		if (null == pKey)
-			return null;
-		String sRet = (null == m_oData) ? null : m_oData.remove(pKey);
-		if (!Util.isNullString(pVal)) {
-			if (null == m_oData)
-				m_oData = new EnumMap<ATTRIB, String>(ATTRIB.class);
-			m_oData.put(pKey, pVal);
-		}
-		return sRet;
-	} // __________________________________
-
-	private String getField(ATTRIB pKey) {
-		if (null == pKey)
-			return null;
-		if (null == m_oData)
-			return null;
-		return m_oData.get(pKey);
-	} // __________________________________
-
-	private long m_lStamp = -1;
-
-	private long m_lUid = -1;
-
-	private long m_lLastSnap = 0;
-
-	private long m_lBatch = 0;
-
-	private String m_sDtSnap = null;
-
-	private String m_sPkg = null;
-
-	public boolean hasUid() {
-		return m_lUid > 0;
-	}
-
-	public void setElemNm(String p_s) {
-		setField(ATTRIB.elem, p_s);
-	}
-
-	public void setRole(String p_s) {
-		setField(ATTRIB.rol, p_s);
-	}
-
-	public void setStamp(long p_l) {
-		m_lStamp = p_l;
-	}
-
-	public void setUid(long p_l) {
-		m_lUid = p_l;
-	}
-
-	public void setSnap(long p_l) {
-		m_lLastSnap = p_l;
-	}
-
-	public void setBatchNum(long p_l) {
-		m_lBatch = p_l;
-	}
-
-	public void setSnapDate(String p_s) {
-		m_sDtSnap = p_s;
-	}
-
-	public void setPackage() {
-		m_sPkg = this.getClass().getPackage().getName();
-	}
-
-	public String getElemNm() {
-		return getField(ATTRIB.elem);
-	}
-
-	public String getRole() {
-		return getField(ATTRIB.rol);
-	}
-
-	public long getStamp() {
-		return m_lStamp;
-	}
-
-	public long getUid() {
-		return m_lUid;
-	}
-
-	public long getSnap() {
-		return m_lLastSnap;
-	}
-
-	public long getBatchNum() {
-		return m_lBatch;
-	}
-
-	public String getSnapDate() {
-		return m_sDtSnap;
-	}
-
-	public BaseBusinessObject() {
-		this((String) null);
-	}
-
-	protected BaseBusinessObject(String p_sElem) {
-		this(p_sElem, -1);
-	}
-
-	protected BaseBusinessObject(String p_sElem, long p_lUid) {
-		setField(ATTRIB.elem, p_sElem);
-		m_lUid = p_lUid;
-		
-		if (null != getElemNm()) {
-			return;
-		}
-		
-		String sClass = getClass().getSimpleName();
-		
-		if (null == p_sElem) {
-			setField(ATTRIB.elem, sClass);
-		}
-	} // ________________________________
-
-	protected BaseBusinessObject(BobjStdDTO p_oDto) throws Exception {
-		this(p_oDto.elementNm());
-		if (p_oDto.isList())
-			return;
-		commonFieldsFromDTO(this, p_oDto);
-	} // ________________________________
-
-	private static final void commonFieldsFromDTO(BaseBusinessObject p_obj,
-			BobjStdDTO p_oDto) throws Exception {
-		for (ATTRIB oCurr : ATTRIB.values())
-			p_obj.setField(oCurr, p_oDto.getAttr(oCurr.toString()));
-
-		String sAux = p_oDto.getAttr(HIDDEN.uid.toString());
-		if (null != sAux)
-			p_obj.m_lUid = Long.parseLong(sAux);
-
-		sAux = p_oDto.getAttr(HIDDEN.stamp.toString());
-		if (null != sAux)
-			p_obj.m_lStamp = Long.parseLong(sAux);
-
-		sAux = p_oDto.getAttr(HIDDEN.snap.toString());
-		if (null != sAux)
-			p_obj.m_lLastSnap = Long.parseLong(sAux);
-
-		sAux = p_oDto.getAttr(HIDDEN.batch.toString());
-		p_obj.setBatchNum((null != sAux) ? Long.parseLong(sAux) : 0);
-
-		// Special treatment for package - only needed for root BaseBusinessObj
-		// this is so only to make XML more compact
-		p_obj.m_sPkg = p_oDto.getAttr(BobjStdDTO.BOBJ_PACKAGE);
-	} // ________________________________
-
-	public static final BaseBusinessObject getFromDTO(BobjStdDTO p_oDto)
-			throws Exception {
-		return BaseBusinessObject.fromDTO(p_oDto);
-	} // ________________________________
-
-	private static BaseBusinessObject fromDTO(BobjStdDTO p_oDto) throws Exception {
-		if (null == p_oDto)
-			return null;
-
-		Class oClass = Class.forName(p_oDto.fullClassName());
-		Constructor CC = oClass
-				.getConstructor(new Class[] { BobjStdDTO.class });
-		BaseBusinessObject oRet = (BaseBusinessObject) CC
-				.newInstance(new Object[] { p_oDto });
-
-		commonFieldsFromDTO(oRet, p_oDto);
-		return oRet;
-	} // ________________________________
-
-	private void putStdAtts(BobjStdDTO p_oRet) {
-		try {
-			p_oRet.addAttr(ATTRIB.rol.toString(), getRole());
-			// if (this instanceof XtfStorable)
-			// p_oRet.addAttr(HIDDEN.type.toString(),((XtfStorable)this).getSnapType());
-			if (m_lStamp > 0)
-				p_oRet
-						.addAttr(HIDDEN.stamp.toString(), Long
-								.toString(m_lStamp));
-			if (m_lLastSnap > 0)
-				p_oRet.addAttr(HIDDEN.snap.toString(), Long
-						.toString(m_lLastSnap));
-			if (!Util.isNullString(m_sDtSnap))
-				p_oRet.addAttr(HIDDEN.dtSnap.toString(), m_sDtSnap);
-			if (getBatchNum() > 0)
-				p_oRet.addAttr(HIDDEN.batch.toString(), Long
-						.toString(getBatchNum()));
-			if (!Util.isNullString(m_sPkg))
-				p_oRet.addAttr(BobjStdDTO.BOBJ_PACKAGE, m_sPkg);
-		} catch (Exception e1) {
-		}
-	} // ________________________________
-
-	public static final BobjStdDTO getDtoList(Class p_Class,
-			List<? extends BaseBusinessObject> p_oBobList) throws Exception {
-		
-		if (null == p_oBobList || p_oBobList.isEmpty()) {
-			return null;
-		}
-		
-		// Create a list of DTOs from the BaseBusinessObject list...
-		List<BobjStdDTO> dtoList = new ArrayList<BobjStdDTO>();
-		for (BaseBusinessObject oCurr : p_oBobList) {
-			dtoList.add(oCurr.toDTO());
-		}
-		
-		// Package up the DTO list in a parent DTO and return ...
-		return new BobjStdDTO(p_Class.getSimpleName(), null, dtoList);
-	} // __________________________________
-
-	public static BaseBusinessObject getRoleFromList(String p_sRole,
-			List<? extends BaseBusinessObject> p_oL) {
-		if (null == p_sRole)
-			return null;
-		if (null == p_oL)
-			return null;
-		for (BaseBusinessObject oCurr : p_oL)
-			if (p_sRole.equals(oCurr.getRole()))
-				return oCurr;
-		return null;
-	} // __________________________________
-} // ____________________________________________________________________________

Deleted: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BobjStdDTO.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BobjStdDTO.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/BobjStdDTO.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,533 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.soa.esb.util;
-
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.OutputStream;
-import java.io.Serializable;
-import java.lang.reflect.Constructor;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.EnumMap;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.transform.OutputKeys;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * {@link org.jboss.soa.esb.util.BaseBusinessObject} Data Transfer Object.
- * <p/>
- * {@link org.jboss.soa.esb.util.BaseBusinessObject} implementations use this
- * class to create a serialized XML representation of their data.  They do this
- * in their {@link org.jboss.soa.esb.util.BaseBusinessObject#toDTO()} method 
- * implementation.
- * <p/>
- * This serialized XML form is used for object persistense.  The DTO is also
- * decorated with the following properties to aid lookup and processing
- * of their persisted form:
- * <ul>
- * 	<li><b>{@link #getUid() UID}</b> //TODO: Define!!</li>
- * 	<li><b>{@link #getStamp()() Stamp}</b> //TODO: Define!!</li>
- * 	<li><b>{@link #getSnap()() Snap}</b> //TODO: Define!!</li>
- * 	<li><b>{@link #getSnapType()()() SnapType}</b> //TODO: Define!!</li>
- * 	<li><b>{@link #getSnapDate()()()() SnapDate}</b> //TODO: Define!!</li>
- * 	<li><b>{@link #getBatch()()() Batch}</b> //TODO: Define!!</li>
- * </ul>
- * 
- * @see #getFromXml(String) 
- * @author <a href="mailto:schifest at gmail.com">Esteban Shifman</a>
- */
-
- at SuppressWarnings("serial")
-public class BobjStdDTO implements Serializable {
-	private static final transient String s_sCharset = "ISO-8859-1";
-
-	public static String getCharset() {
-		return s_sCharset;
-	}
-
-	private static final transient String s_sEncoding = "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>";
-
-	// Some attribute names for the toXML() and fromXML()
-	public final static String BOBJ_PACKAGE = "__BobjPkg";
-
-	public final static String BOBJ_CLASS = "__Class";
-
-	protected String m_sClassNm;
-
-	protected String m_sElemNm;
-
-	protected Map<String, Object> m_oAtts;
-
-	protected List<BobjStdDTO> m_oChild;
-
-	protected String[][] m_saaLocators;
-
-	public void setLocators(String[][] p_saa) {
-		m_saaLocators = p_saa;
-	}
-
-	public String[][] getLocators() {
-		return m_saaLocators;
-	}
-
-	// Getters
-	public String classNm() {
-		return m_sClassNm;
-	}
-
-	public String elementNm() {
-		return m_sElemNm;
-	}
-
-	public boolean isList() {
-		return null != m_oChild;
-	}
-
-	public boolean isEmpty() {
-		return (isList()) ? (m_oChild).isEmpty() : m_oAtts.isEmpty();
-	}
-
-	protected BobjStdDTO(String p_sClassNm, String p_sElemNm,
-			List<BobjStdDTO> p_oList) {
-		initialize(p_sClassNm, p_sElemNm, p_oList);
-	}
-
-	private void initialize(String p_sClassNm, String p_sElemNm,
-			List<BobjStdDTO> p_oList) {
-		m_sClassNm = p_sClassNm;
-		m_sElemNm = (null != p_sElemNm) ? p_sElemNm : m_sClassNm
-				.substring(1 + m_sClassNm.lastIndexOf("."));
-		m_oChild = p_oList;
-		if (null == m_oChild)
-			m_oAtts = new HashMap<String, Object>();
-	} // __________________________________
-
-	private BobjStdDTO(Element p_n) throws Exception {
-		String sElem = p_n.getNodeName();
-
-		String sClass = null;
-		try {
-			sClass = p_n.getAttribute(BOBJ_CLASS);
-		} catch (Exception eC) {
-		}
-		sClass = (null == sClass) ? sElem : ("".equals(sClass)) ? sElem
-				: sClass;
-		p_n.removeAttribute(BOBJ_CLASS);
-
-		String sList = null;
-		try {
-			sList = p_n.getAttribute("List");
-		} catch (Exception eL) {
-		}
-		boolean m_bList = (null == sList) ? false : ("".equals(sList)) ? false
-				: true;
-		p_n.removeAttribute("List");
-
-		NodeList NL = p_n.getChildNodes();
-		int iQch = NL.getLength();
-		if (m_bList) {
-			List<BobjStdDTO> olCh = new ArrayList<BobjStdDTO>();
-			for (int i1 = 0; i1 < iQch; i1++) {
-				Node oCurr = NL.item(i1);
-				if (Node.ELEMENT_NODE != oCurr.getNodeType())
-					continue;
-				BobjStdDTO oThisCh = new BobjStdDTO((Element) NL.item(i1));
-				oThisCh.m_sElemNm = oThisCh.m_sClassNm = sClass;
-				olCh.add(oThisCh);
-			}
-			initialize(sClass, sElem, olCh);
-			return;
-		}
-
-		initialize(sClass, sElem, null);
-		this.addMap(mapFromAtts(p_n.getAttributes()));
-
-		for (int i1 = 0; i1 < iQch; i1++) {
-			Node oCurr = NL.item(i1);
-			if (Node.ELEMENT_NODE != oCurr.getNodeType())
-				continue;
-			this.addDto(((Element) oCurr).getNodeName(), new BobjStdDTO(
-					((Element) oCurr)));
-		}
-	} // __________________________________
-
-	private void setLongAttr(String p_s, long pL) {
-		try {
-			addAttr(p_s, Long.toString(pL));
-		} catch (Exception e) {
-			e.printStackTrace();
-		}
-	} // __________________________________
-
-	private void setStringAttr(String p_s, String pVal) {
-		try {
-			addAttr(p_s, pVal);
-		} catch (Exception e) {
-			e.printStackTrace();
-		}
-	} // __________________________________
-
-	private long attrAsLong(String p_s) {
-		try {
-			String sVal = getAttr(p_s);
-			if (!Util.isNullString(sVal))
-				return Long.parseLong(sVal);
-		} catch (Exception e) {/* OK just fall through and return default */
-		}
-		return 0;
-	} // __________________________________
-
-	private String attrAsString(String p_s) {
-		try {
-			return getAttr(p_s);
-		} catch (Exception e) {/* OK just fall through and return default */
-		}
-		return null;
-	} // __________________________________
-
-	public long getStamp() {
-		return attrAsLong(BaseBusinessObject.HIDDEN.stamp.toString());
-	}
-
-	public long getUid() {
-		return attrAsLong(BaseBusinessObject.HIDDEN.uid.toString());
-	}
-
-	public long getSnap() {
-		return attrAsLong(BaseBusinessObject.HIDDEN.snap.toString());
-	}
-
-	public long getBatch() {
-		return attrAsLong(BaseBusinessObject.HIDDEN.batch.toString());
-	}
-
-	public String getSnapType() {
-		return attrAsString(BaseBusinessObject.HIDDEN.type.toString());
-	}
-
-	public String getSnapDate() {
-		return attrAsString(BaseBusinessObject.HIDDEN.dtSnap.toString());
-	}
-
-	public void setStamp(long pL) {
-		setLongAttr(BaseBusinessObject.HIDDEN.stamp.toString(), pL);
-	}
-
-	public void setUid(long pL) {
-		setLongAttr(BaseBusinessObject.HIDDEN.uid.toString(), pL);
-	}
-
-	public void setSnap(long pL) {
-		setLongAttr(BaseBusinessObject.HIDDEN.snap.toString(), pL);
-	}
-
-	public void setBatch(long pL) {
-		setLongAttr(BaseBusinessObject.HIDDEN.batch.toString(), pL);
-	}
-
-	public void setSnapType(String pS) {
-		setStringAttr(BaseBusinessObject.HIDDEN.type.toString(), pS);
-	}
-
-	public void setSnapDate(String pS) {
-		setStringAttr(BaseBusinessObject.HIDDEN.dtSnap.toString(), pS);
-	}
-
-	public String fullClassName() {
-		String sPkg = "";
-		try {
-			sPkg = getAttr(BobjStdDTO.BOBJ_PACKAGE);
-		} catch (Exception e) {/* just leave it empty */
-		}
-		String sConstrPkg = (sPkg.endsWith(".")) ? sPkg : sPkg + ".";
-		return sConstrPkg + classNm();
-	} // __________________________________
-
-	public List<? extends BaseBusinessObject> getChildObjList(String p_sElem,
-			Class pCls) throws Exception {
-		BobjStdDTO oChDto = this.getDTO(p_sElem);
-		if (null == oChDto)
-			return null;
-		if (!oChDto.isList())
-			throw new Exception("Child DTO is not List");
-		return oChDto.listDtoToList(pCls);
-	} // __________________________________
-
-	private List<BaseBusinessObject> listDtoToList(Class pCls) throws Exception {
-		if (!isList())
-			throw new Exception("BObjStdDTO is not a List");
-		Class[] oaCls = { BobjStdDTO.class };
-		Constructor CC = pCls.getConstructor(oaCls);
-		List<BaseBusinessObject> LL = new ArrayList<BaseBusinessObject>();
-		Object[] oaParms = new BobjStdDTO[1];
-		for (BobjStdDTO oCurr : m_oChild) {
-			oaParms[0] = oCurr;
-			LL.add((BaseBusinessObject) CC.newInstance(oaParms));
-		}
-		return (LL.size() > 0) ? LL : null;
-	} // __________________________________
-
-	public Map<String, Object> getAttrMap() throws Exception {
-		return m_oAtts;
-	} // __________________________________
-
-	public BobjStdDTO getDTO(String p_sKey) throws Exception {
-		if (isList())
-			throw new Exception("BObjStdDTO is a List");
-		Object oRet = m_oAtts.get(p_sKey);
-		if (null == oRet)
-			return null;
-		if (oRet instanceof BobjStdDTO)
-			return (BobjStdDTO) oRet;
-		throw new Exception("Value is not BObjStdDTO");
-	} // __________________________________
-
-	public String getAttr(String p_sAttrName) throws Exception {
-		if (isList()) {
-			throw new UnsupportedOperationException("BObjStdDTO is a List.  Cannot call getAttr method.  Use isList to check!");
-		}
-		Object oRet = m_oAtts.get(p_sAttrName);
-		if (null == oRet) {
-			return null;
-		}
-		if (oRet instanceof String) {
-			return (String) oRet;
-		}
-		throw new IllegalArgumentException("p_sAttrName is not an attribute");
-	} // __________________________________
-
-	@SuppressWarnings("unchecked")
-	public void addAttr(String p_sKey, String p_sAtt) throws Exception {
-		if (isList())
-			throw new Exception("BObjStdDTO is a List");
-		if (null == p_sKey)
-			return;
-		m_oAtts.remove(p_sKey);
-		if (null != p_sAtt)
-			if (p_sAtt.trim().length() > 0)
-				m_oAtts.put(p_sKey, p_sAtt.trim());
-	} // __________________________________
-
-	@SuppressWarnings("unchecked")
-	public void addDto(String p_sKey, BobjStdDTO p_oDto) throws Exception {
-		if (isList())
-			throw new Exception("BObjStdDTO is a List");
-		if (null == p_sKey)
-			return;
-		m_oAtts.remove(p_sKey);
-		if (null == p_oDto)
-			return;
-		if (p_oDto.isEmpty())
-			return;
-		p_oDto.m_sElemNm = p_sKey;
-		m_oAtts.put(p_sKey, p_oDto);
-	} // __________________________________
-
-	@SuppressWarnings("unchecked")
-	private void addMap(Map<String, Object> p_oM) throws Exception {
-		if (isList())
-			throw new Exception("BObjStdDTO is a List");
-		if (null == p_oM)
-			return;
-		for (Map.Entry<String, Object> oCurr : p_oM.entrySet())
-			m_oAtts.put(oCurr.getKey(), oCurr.getValue());
-	} // __________________________________
-
-	public String toXml() throws Exception {
-		return toXml(false);
-	}
-
-	public String toXml(boolean p_bDecl) throws Exception {
-		Document oDoc = toDoc();
-		oDoc.normalize();
-		DOMSource src = new DOMSource(oDoc);
-
-		OutputStream oStrm = new ByteArrayOutputStream(1000);
-		StreamResult res = new StreamResult(oStrm);
-
-		Transformer oTf = TransformerFactory.newInstance().newTransformer();
-		oTf.setOutputProperty(OutputKeys.INDENT, "no");
-		oTf.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, (p_bDecl) ? "no"
-				: "yes");
-
-		oTf.setOutputProperty(OutputKeys.ENCODING, s_sCharset);
-		oTf.transform(src, res);
-		return oStrm.toString();
-	} // __________________________________
-
-	public Document toDoc() {
-		DocumentBuilder oDB = null;
-		try {
-			oDB = DocumentBuilderFactory.newInstance().newDocumentBuilder();
-		} catch (Exception e) {
-		}
-		Document oDoc = oDB.newDocument();
-		oDoc.appendChild(toElement(oDoc));
-		return oDoc;
-	} // __________________________________
-
-	public Node toElement(Document p_oDoc) {
-		return (isList()) ? listToElement(p_oDoc) : mapToElement(p_oDoc);
-	} // __________________________________
-
-	private Node mapToElement(Document p_oDoc) {
-		if (null == m_oAtts)
-			return null;
-		Element onRet = p_oDoc.createElement(m_sElemNm);
-		for (Map.Entry<String, Object> oCurr : m_oAtts.entrySet()) {
-			if (oCurr.getValue() instanceof BobjStdDTO) {
-				onRet.appendChild(((BobjStdDTO) oCurr.getValue())
-						.toElement(p_oDoc));
-				continue;
-			} else
-				// System.out.println("Elem<"+sKey+">
-				// Val<"+oVal.toString()+">");
-				onRet.setAttribute(oCurr.getKey(), oCurr.getValue().toString());
-		}
-
-		boolean bPutClass = (null != m_sClassNm)
-				&& (!m_sElemNm.equals(m_sClassNm));
-		if (bPutClass)
-			onRet.setAttribute(BOBJ_CLASS, m_sClassNm);
-		else
-			onRet.removeAttribute(BOBJ_CLASS);
-
-		return onRet;
-	} // __________________________________
-
-	private Node listToElement(Document p_oDoc) {
-		if (null == m_oChild)
-			return null;
-		if (m_oChild.isEmpty())
-			return null;
-
-		Element onRet = p_oDoc.createElement(m_sElemNm);
-		onRet.setAttribute("List", "yes");
-		if (!m_sElemNm.equals(m_sClassNm))
-			onRet.setAttribute(BOBJ_CLASS, m_sClassNm);
-
-		for (BobjStdDTO oCurr : m_oChild) {
-			oCurr.m_sClassNm = null;
-			oCurr.m_sElemNm = "it";
-			onRet.appendChild(oCurr.toElement(p_oDoc));
-		}
-		return onRet;
-	} // __________________________________
-
-	public static synchronized BobjStdDTO getFromXml(String xmlBob)
-			throws Exception {
-		
-		if(Util.isNullString(xmlBob)) {
-			throw new IllegalArgumentException("null or empty 'xmlBob' arg in call.");
-		}
-		
-		StringBuffer sb = new StringBuffer(s_sEncoding).append("\n")
-				.append(xmlBob);
-		DocumentBuilder oDB = DocumentBuilderFactory.newInstance()
-				.newDocumentBuilder();
-		Document oDoc = oDB.parse(new ByteArrayInputStream(sb.toString()
-				.getBytes(s_sCharset)));
-		return new BobjStdDTO(oDoc.getDocumentElement());
-	} // __________________________________
-
-	private static synchronized Map<String, Object> mapFromAtts(
-			NamedNodeMap p_oNnm) {
-		if (null == p_oNnm)
-			return null;
-		int iQatt = p_oNnm.getLength();
-		if (iQatt < 1)
-			return null;
-		Map<String, Object> omAtts = new HashMap<String, Object>();
-		for (int i2 = 0; i2 < iQatt; i2++) {
-			Node nAtt = p_oNnm.item(i2);
-			omAtts.put(nAtt.getNodeName(), nAtt.getNodeValue());
-		}
-		return omAtts;
-	} // __________________________________
-
-	public void Dump(String p_sTitle) throws Exception {
-		System.out.println(p_sTitle);
-		Dump(0);
-	} // __________________________________
-
-	public void Dump(int p_iLev) throws Exception {
-		byte[] ba = new byte[3 * p_iLev];
-		Arrays.fill(ba, (byte) ' ');
-		String sTab = new String(ba);
-		System.out.print(sTab + "Elem " + m_sElemNm + "  Class " + m_sClassNm);
-		if (isList()) {
-			System.out.println("  LIST");
-			for (BobjStdDTO oCurr : m_oChild)
-				oCurr.Dump(1 + p_iLev);
-			return;
-		}
-		System.out.print("\n" + sTab);
-
-		for (EnumMap.Entry<String, Object> oCurr : m_oAtts.entrySet()) {
-			if (oCurr.getValue() instanceof String)
-				System.out.print("   " + oCurr.getKey() + "<"
-						+ oCurr.getValue() + ">");
-		}
-		System.out.println();
-		for (EnumMap.Entry<String, Object> oCurr : m_oAtts.entrySet()) {
-			if (oCurr.getValue() instanceof BobjStdDTO)
-				((BobjStdDTO) oCurr.getValue()).Dump(1 + p_iLev);
-		}
-	} // __________________________________
-	
-	public BaseBusinessObject getBobj(String p_sObj)
-	  { if (null == p_sObj)   return null;
-	    try
-	    { BobjStdDTO oDto = this.getDTO(p_sObj);
-	      return BaseBusinessObject.getFromDTO(oDto);
-	    }
-	    catch (Exception e) {return null; }
-	  } //__________________________________
-	
-	@SuppressWarnings("unchecked")
-	public void addBobj(String p_sKey, BaseBusinessObject p_oBob) throws Exception
-	  { if (isList()) throw new Exception("BObjStdDTO is a List");
-	    if (null == p_sKey)     return;
-	  	m_oAtts.remove(p_sKey);
-	    if (null == p_oBob)     return;
-	    BobjStdDTO oDto = p_oBob.toDTO();
-	    if (oDto.isEmpty())     return;
-	    oDto.m_sElemNm=p_sKey;
-	    m_oAtts.put(p_sKey,oDto);
-	  } //__________________________________
-} // ____________________________________________________________________________

Deleted: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/NagiosStandaloneHeartbeat.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/NagiosStandaloneHeartbeat.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/util/NagiosStandaloneHeartbeat.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,38 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-
-
-
-package org.jboss.soa.esb.util;
-
-public class NagiosStandaloneHeartbeat
-{
-	public NagiosStandaloneHeartbeat
-		(String pNagiosServer
-		,int	pPort
-		,String pService
-		,String pDescription
-		)
-	{
-
-	}
-}

Deleted: labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,113 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.soa.esb.util;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.jboss.internal.soa.esb.util.StreamUtils;
-
-/**
- * BaseBusinessObject unit tests.
- * @author <a href="mailto:tom.fennelly at jboss.com">tom.fennelly at jboss.com</a>
- */
-public class BaseBusinessObjectUnitTest extends TestCase {
-
-	private TestBob bob;
-	
-	protected void setUp() throws Exception {
-		bob = new TestBob("blah", 1234L);
-		// Set the base properties...
-		bob.setBatchNum(1234);
-		bob.setElemNm("whoosh");
-		bob.setPackage();
-		bob.setRole("sweeper");
-		bob.setSnap(1234);
-		bob.setSnapDate("12/12/2000");
-		bob.setStamp(1234);
-		bob.setUid(1234);
-	}
-
-	public void test_BaseBusinessObject() throws Exception {
-		
-		// ToDTO the bob and back again...
-		BobjStdDTO dtoBefore = bob.toDTO();
-		bob = (TestBob) BaseBusinessObject.getFromDTO(dtoBefore);
-
-		// Check the base properties...
-		assertEquals(1234, bob.getBatchNum());
-		assertEquals(null, bob.getElemNm()); // REVIEW: What happened to "whoosh"
-		assertEquals("sweeper", bob.getRole());
-		assertEquals(1234, bob.getSnap());
-		assertEquals(null, bob.getSnapDate()); // REVIEW: WHat happened to the snap date of "12/12/2000"
-		assertEquals(1234, bob.getStamp());
-		assertEquals(1234, bob.getUid());
-		
-		BobjStdDTO dtoAfter = bob.toDTO();
-		assertEquals(TestBob.MY_BOB_PROP_VAL, dtoAfter.getAttr(TestBob.MY_BOB_PROP));
-		assertNotSame(dtoBefore.toXml(), dtoAfter.toXml()); // REVIEW: Would have expected these to be the same!!
-		
-		// Construct using the default constructor...
-		bob = new TestBob();
-		assertEquals("TestBob", bob.getElemNm());
-	}
-	
-	public void test_getDtoList() throws Exception {
-		List<BaseBusinessObject> bobList = new ArrayList<BaseBusinessObject>();
-		
-		bobList.add(new TestBob());
-		bobList.add(new TestBob());
-		bobList.add(new TestBob());
-		
-		BobjStdDTO dto = BaseBusinessObject.getDtoList(TestBob.class, bobList);
-		String expected = new String(StreamUtils.readStream(getClass().getResourceAsStream("BaseBusinessObjectUnitTest_testfile1.xml")));
-		assertEquals(expected, dto.toXml());
-	}
-	
-	public void test_getRoleFromList() throws Exception {
-		List<BaseBusinessObject> bobList = new ArrayList<BaseBusinessObject>();
-		
-		bobList.add(new TestBob());
-		bobList.add(new TestBob());
-		bobList.add(new TestBob());
-		
-		bobList.get(0).setRole("role0");
-		bobList.get(1).setRole("role1");
-		bobList.get(2).setRole("role2");
-		
-		assertEquals(bobList.get(0), BaseBusinessObject.getRoleFromList("role0", bobList));
-		assertEquals(bobList.get(1), BaseBusinessObject.getRoleFromList("role1", bobList));
-		assertEquals(bobList.get(2), BaseBusinessObject.getRoleFromList("role2", bobList));
-
-		assertEquals(null, BaseBusinessObject.getRoleFromList(null, bobList));
-		assertEquals(null, BaseBusinessObject.getRoleFromList("blah", null));
-	}
-	
-	public void test_misc() {		
-		// Noddy methods - just touching to improve the coverage figures :-)
-		bob.toString();
-		bob.locator();
-		bob.allLocators();
-	}
-}

Deleted: labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest_testfile1.xml
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest_testfile1.xml	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BaseBusinessObjectUnitTest_testfile1.xml	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1 +0,0 @@
-<TestBob List="yes"><it myBobProp="myBobProp-hello"/><it myBobProp="myBobProp-hello"/><it myBobProp="myBobProp-hello"/></TestBob>
\ No newline at end of file

Deleted: labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,152 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.soa.esb.util;
-
-import java.util.List;
-
-import junit.framework.TestCase;
-
-import org.jboss.internal.soa.esb.util.StreamUtils;
-import org.jboss.soa.esb.StringUtils;
-import org.jboss.soa.esb.W3CDomUtils;
-import org.jboss.soa.esb.common.bizclasses.Address;
-import org.w3c.dom.Document;
-
-/**
- * BobjStdDTO unit tests.
- * @author <a href="mailto:tom.fennelly at jboss.com">tom.fennelly at jboss.com</a>
- */
-public class BobjStdDTOUnitTest extends TestCase {
-
-	public void test_getFromXml_String() throws Exception {
-		try {
-			BobjStdDTO.getFromXml(null);
-			fail("expected IllegalArgumentException");
-		} catch(IllegalArgumentException e) {
-			// expected
-		}
-		try {
-			BobjStdDTO.getFromXml(" ");
-			fail("expected IllegalArgumentException");
-		} catch(IllegalArgumentException e) {
-			// expected
-		}
-		
-		String source = new String(StreamUtils.readStream(
-				getClass().getResourceAsStream("BobjStdDTOUnitTest_testfile1.xml")));
-		BobjStdDTO rootBob = BobjStdDTO.getFromXml(source);
-		
-		// Check the attributes on the root element of the serialised object representation...
-		assertEquals("Brum", rootBob.getAttr("fmlyN"));
-		assertEquals("Daniel", rootBob.getAttr("givN"));
-		assertEquals("Mr.", rootBob.getAttr("pfx"));
-		assertEquals("the 1st.", rootBob.getAttr("sfx"));
-		assertTrue(!rootBob.isEmpty());
-		assertTrue(!rootBob.isList());
-
-		// Check the nested Address - this is a "List"....
-		BobjStdDTO childBob = rootBob.getDTO("Laddr");
-		assertNotNull(childBob);
-		assertTrue(!childBob.isEmpty());
-		assertTrue(childBob.isList());
-		// Address is a list type. Calling getAttr should result in an exception...
-		try {
-			childBob.getAttr("xx");
-			fail("expected UnsupportedOperationException");
-		} catch (UnsupportedOperationException e) {
-			// expected
-		}
-		assertEquals("Address", childBob.m_sClassNm);
-		assertEquals(null, childBob.m_oAtts);
-		
-		// Run a few more checks...
-		childBob = rootBob.getDTO("Lpho");
-		assertNotNull(childBob);
-		childBob = rootBob.getDTO("Lemail");
-		assertNotNull(childBob);
-		
-		// TODO: Add tests for the locator and batch "stuff"!
-	}
-
-	public void test_toDoc() throws Exception {
-		String source = new String(StreamUtils.readStream(
-				getClass().getResourceAsStream("BobjStdDTOUnitTest_testfile1.xml")));
-		BobjStdDTO bob = BobjStdDTO.getFromXml(source);
-		
-		// Call toDoc on the Bob, serialise it and compare the serialised 
-		// form to the original input.  They should match...
-		Document doc = bob.toDoc();
-		String serialisedVer = W3CDomUtils.serialize(doc);
-		assertTrue(StringUtils.equalsIgnoreLinebreaks(source, serialisedVer, false));
-	}
-	
-	public void test_getChildObjList() throws Exception {
-		String source = new String(StreamUtils.readStream(
-				getClass().getResourceAsStream("BobjStdDTOUnitTest_testfile1.xml")));
-		BobjStdDTO dto = BobjStdDTO.getFromXml(source);
-				
-		
-		List<? extends BaseBusinessObject> bobList = dto.getChildObjList("Laddr", Address.class);
-		
-		assertEquals(1, bobList.size());
-		assertTrue(bobList.get(0) instanceof Address);
-		Address address = (Address) bobList.get(0);
-		assertEquals("Argentina", address.getField(Address.ATTRIB.cntry));
-		assertEquals("1642", address.getField(Address.ATTRIB.postalZip));
-		assertEquals("Buenos Aires", address.getField(Address.ATTRIB.provSt));
-		assertEquals("Balcarce", address.getField(Address.ATTRIB.strLine1));
-		assertEquals(null, address.getField(Address.ATTRIB.strLine2));
-		assertEquals("50", address.getField(Address.ATTRIB.strNum));
-		assertEquals(null, address.getField(Address.ATTRIB.suite));
-		assertEquals("San Isidro", address.getField(Address.ATTRIB.twnCty1));
-		assertEquals(null, address.getField(Address.ATTRIB.twnCty2));
-		assertEquals(2, address.getPhoneCount());
-		assertEquals("(416)555-1212", address.getPhoneAt(0).toString());
-		assertEquals("+54(11)4555-1111 Ext 7", address.getPhoneAt(1).toString());
-		
-	}
-	
-	public void test_MiscTests() throws Exception {
-		String source = new String(StreamUtils.readStream(
-				getClass().getResourceAsStream("BobjStdDTOUnitTest_testfile1.xml")));
-		BobjStdDTO bob = BobjStdDTO.getFromXml(source);
-
-		// Calling dump simply to improve the coverage figures - this is a dev utility method
-		// so testing this isn't so important...
-		bob.Dump(0);
-		
-		// Check the setter and getter methods.  This is a bit anal but makes a 
-		// big diff on the coverage figures for this class...
-		bob.setUid(1234);
-		assertEquals(1234, bob.getUid());
-		bob.setBatch(1234);
-		assertEquals(1234, bob.getBatch());
-		bob.setSnap(1234);
-		assertEquals(1234, bob.getSnap());
-		bob.setStamp(1234);
-		assertEquals(1234, bob.getStamp());
-		bob.setSnapDate("30/12/1990");
-		assertEquals("30/12/1990", bob.getSnapDate());
-		bob.setSnapType("blah");
-		assertEquals("blah", bob.getSnapType());
-	}	
-}

Deleted: labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest_testfile1.xml
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest_testfile1.xml	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/BobjStdDTOUnitTest_testfile1.xml	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,18 +0,0 @@
-<Person fmlyN="Brum" givN="Daniel" pfx="Mr." sfx="the 1st.">
-<Laddr List="yes" __Class="Address">
-<it cntry="Argentina" postalZip="1642" provSt="Buenos Aires" strLine1="Balcarce" strNum="50" twnCty1="San Isidro">
-<Lpho List="yes" __Class="Telephone">
-<it city="416" num="555-1212" rol="torIP"/>
-<it city="11" cntry="54" ext="7" num="4555-1111" rol="home"/>
-</Lpho>
-</it>
-</Laddr>
-<Lpho List="yes" __Class="Telephone">
-<it city="416" cntry="1" num="555-1212" rol="basement"/>
-<it city="416" num="666-4444" rol="cell"/>
-</Lpho>
-<Lemail List="yes" __Class="OneValue">
-<it rol="home" v="myaddr at gmail.com"/>
-<it rol="work" v="john.smith at jboss.com"/>
-</Lemail>
-</Person>
\ No newline at end of file

Deleted: labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/TestBob.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/TestBob.java	2006-12-05 11:03:58 UTC (rev 8062)
+++ labs/jbossesb/trunk/product/core/rosetta/tests/src/org/jboss/soa/esb/util/TestBob.java	2006-12-05 12:12:49 UTC (rev 8063)
@@ -1,51 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.soa.esb.util;
-
-import junit.framework.TestCase;
-
-class TestBob extends BaseBusinessObject {
-	
-	public static final String MY_BOB_PROP = "myBobProp";
-	public static final String MY_BOB_PROP_VAL = "myBobProp-hello";
-
-	public TestBob() {
-		super();
-	}
-	
-	public TestBob(String elementName, long uid) {
-		super(elementName, uid);
-	}
-
-	public TestBob(BobjStdDTO dto) throws Exception {
-		super(dto);
-		TestCase.assertEquals(MY_BOB_PROP_VAL, dto.getAttr(MY_BOB_PROP));
-	}
-	
-	public BobjStdDTO toDTO() throws Exception {
-		BobjStdDTO dto = super.toDTO();
-		
-		dto.addAttr(MY_BOB_PROP, MY_BOB_PROP_VAL);
-		
-		return dto;
-	}
-}
\ No newline at end of file

Modified: labs/jbossesb/trunk/product/docs/ProgrammersGuide.odt
===================================================================
(Binary files differ)




More information about the jboss-svn-commits mailing list