Standards
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Go Back   Web Development Archives Mailing Lists Standards

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Web Development Archives Sponsor:
  #1  
Old July 30th, 2008, 11:01 AM
Florent Batard via cvs-syncmail
Guest
Dev Archives Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
2006/unicorn/org/w3c/unicorn/tests TaskTest.java,1.2,1.3

Update of /
In directory

Modified Files:
TaskTest.java
Log Message:
Some test for the expansion algorithm and XMLBeans reading of the tasklist

Index: TaskTest.java

RCS file: /,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
TaskTest.java 30 Jul 2008 14:19:06 -0000 1.2
TaskTest.java 30 Jul 2008 14:45:51 -0000 1.3
@@ -6,8 +6,6 @@

import java.io.File;
import java.io.IException;
-import java.util.ArrayList;
-import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;

@@ -15,7 +13,8 @@
import ;
import ;
import org.w3c.unicorn.tasklist.Task;
-import ;
+import ;
+
/**
* @author shenril
*
@@ -27,15 +26,18 @@
*/
public static void main(String[] args) {
try {
- TasklistDocument (new File(""));
- Task aTask=new Task(tasklist.getTasklist().getTaskArray(0));
+ TasklistDocument (new File(""));
+ TaskListUnmarshallerBeans unmarshaller=new TaskListUnmarshallerBeans();
+ Task aTask=new Task();
+ aTask.setTree(unmarshaller.ExpandTree(tasklist.get Tasklist().getTaskArray(0)));
Map<String, TaskTask = new LinkedHashMap<String, Task>();
for(TaskType myTask : tasklist.getTasklist().getTaskArray()){
- Task bTask=new Task(myTask);
+ Task bTask=new Task();
+ aTask.setTree(unmarshaller.ExpandTree(myTask));
Task.put(bTask.getID(), bTask);
}
- aTask.setRoot(aTask.expandNode(Task, aTask.getRoot()));
- aTask.displayTree(aTask.getRoot());
+ aTask.setTree(aTask.expandNode(Task, aTask.getTree()));
+ aTask.displayTree(aTask.getTree());
} catch (XmlException e) {
e.printStackTrace();
} catch (IException e) {

Reply With Quote
Reply

Viewing: Web Development Archives Mailing Lists Standards > 2006/unicorn/org/w3c/unicorn/tests TaskTest.java,1.2,1.3


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 3 Hosted by Hostway
For more Enterprise Application Development news, visit eWeek