2006/unicorn/src/org/w3c/unicorn UnicornClient.java,1.4,1.5

Update of /sources/public/2006/unicorn/src/org/w3c/unicorn
In directory hutz:/tmp/cvs-serv22144/src/org/w3c/unicorn

Modified Files:
	UnicornClient.java 
Log Message:
uses MessageList

Index: UnicornClient.java
===================================================================
RCS file: /sources/public/2006/unicorn/src/org/w3c/unicorn/UnicornClient.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- UnicornClient.java	24 Sep 2009 17:39:16 -0000	1.4
+++ UnicornClient.java	6 Oct 2009 08:20:52 -0000	1.5
@@ -17,7 +17,7 @@
 import org.w3c.unicorn.input.URIInputParameter;
 import org.w3c.unicorn.output.OutputFactory;
 import org.w3c.unicorn.output.OutputModule;
-import org.w3c.unicorn.util.Message;
+import org.w3c.unicorn.util.MessageList;
 import org.w3c.unicorn.util.Property;
 
 public class UnicornClient {
@@ -70,7 +70,7 @@
 		Map<String, Object> mapOfStringObject = new LinkedHashMap<String, Object>();
 		Map<String, String> specificParameters = new Hashtable<String, String>();
 		Map<String, String> outputParameters   = new Hashtable<String, String>();
-		ArrayList<Message> messages = new ArrayList<Message>();
+		MessageList messages = new MessageList();
 
 		// Retrieve parameter prefixes from unicorn.properties
 		String paramPrefix = Property.get("UNICORN_PARAMETER_PREFIX");
@@ -92,11 +92,12 @@
 				String paramName = param[0].substring(paramPrefix.length());
 				if (paramName.equals("lang")) {
 					outputParameters.put(paramName, param[1]);
+					messages.setLang(param[1]);
 					aUnicornCall.setLang(param[1] + "," + Property.get("DEFAULT_LANGUAGE"));
 				} else if (paramName.equals("task")) {
 					String task = Action.getTask(param[1], messages);
 					if (!task.equals(param[1])) {
-						mapOfStringObject.put("default_task", Framework.mapOfTask.get(Framework.mapOfTask.getDefaultTaskId()));
+						mapOfStringObject.put("default_task", Framework.getDefaultTask());
 					}
 					aUnicornCall.setTask(task);
 				} else if (outputParams.contains(paramName)) {

Received on Tuesday, 6 October 2009 08:20:58 UTC