GenericObjectList replacementObject,
GenericObject replacementObject,
	public void replace(		String objectText,		GenericObjectList replacementObject,		boolean matchSubstring)		throws IllegalArgumentException {		if (objectText == null || replacementObject == null) {			throw new IllegalArgumentException("null argument");		}		ListIterator listIterator = this.listIterator();		LinkedList ll = new LinkedList();		while (listIterator.hasNext()) {			Object obj = listIterator.next();			if (GenericObject.isMySubclass(obj.getClass())) {				GenericObject gobj = (GenericObject) obj;				if (gobj.getClass().equals(replacementObject.getClass())) {					if ((!matchSubstring)						&& gobj.encode().compareTo(objectText) == 0) {						// Found the object that we want,						ll.add(obj);					} else if (						matchSubstring							&& gobj.encode().indexOf(objectText) >= 0) {						ll.add(obj);					} else {						gobj.replace(							objectText,							replacementObject,							matchSubstring);					}				}			} else if (GenericObjectList.isMySubclass(obj.getClass())) {				GenericObjectList gobj = (GenericObjectList) obj;				if (gobj.getClass().equals(replacementObject.getClass())) {					if ((!matchSubstring)						&& gobj.encode().compareTo(objectText) == 0) {						// Found the object that we want,						ll.add(obj);					} else if (						matchSubstring							&& gobj.encode().indexOf(objectText) >= 0) {						ll.add(obj);					} else {						gobj.replace(							objectText,							replacementObject,							matchSubstring);					}				}			}		}		for (int i = 0; i < ll.size(); i++) {			Object obj = ll.get(i);			this.remove(obj);			this.add(i, (Object) replacementObject);		}	}