@SuppressWarnings({ "rawtypes", "unchecked" })
	public Object process(Object value) {
		// we're processing things which are either PhpObjects or which could contain PhpObjects.
		if (value instanceof PhpObject) {
			PhpObject tmpPHP = (PhpObject) value;
			value = tmpPHP.getRealObject();
		} else if (value instanceof ArrayList) {
			ArrayList tmpArr = (ArrayList) value;
			for (int i = 0; i < tmpArr.size(); i++) {
				Object tmpObj = tmpArr.get(i);
				if (needsProcessing(tmpObj)) {
					tmpObj = process(tmpObj);
					tmpArr.set(i,tmpObj);
				}
			}
		} else if (value instanceof LinkedHashMap) {
			LinkedHashMap lhm = (LinkedHashMap) value;
			Map<String,Object> tmpMap = lhm;
			for (Map.Entry<String,Object> entry : tmpMap.entrySet()) {
				String key = entry.getKey();
				Object tmpObj = entry.getValue();
				if (needsProcessing(tmpObj)) {
					tmpObj = process(tmpObj);
					lhm.put(key,tmpObj);
				}
			}
		}

		return value; // this ought to reflect any changes;
	}