Mercurial > hg > Members > tatsuki > JungleXMLReader
changeset 13:2ecced397007
commit
author | one |
---|---|
date | Sat, 25 Oct 2014 19:42:44 +0900 |
parents | 67305f53aad0 |
children | 54ac3718ab24 |
files | src/main/java/jp/ac/u_ryukyu/cr/ie/tatsuki/bbs/JuGrix.java src/test/java/jp/ac/u_ryukyu/cr/ie/tatsuki/functionTest/roleIdsTest.java |
diffstat | 2 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/src/main/java/jp/ac/u_ryukyu/cr/ie/tatsuki/bbs/JuGrix.java Sat Oct 25 17:10:03 2014 +0900 +++ b/src/main/java/jp/ac/u_ryukyu/cr/ie/tatsuki/bbs/JuGrix.java Sat Oct 25 19:42:44 2014 +0900 @@ -5,7 +5,6 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; -import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.Jungle; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.JungleTree; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.store.NodePath; import jp.ac.u_ryukyu.ie.cr.shoshi.jungle.store.impl.TreeNode; @@ -55,7 +54,7 @@ public Iterator<String> personIds(LinkedList<String> ids){ - LinkedList<String> personIds = new LinkedList(); + LinkedList<String> personIds = new LinkedList<String>(); for (String id : ids) { personIds.addAll(personIdsSearch(id)); @@ -294,7 +293,7 @@ if (!chilrenOrgIdsIterator.hasNext()) return new NullIterator(); - TreeNode chilerenOrgIds = chilrenOrgIdsIterator.next().left(); + //TreeNode chilerenOrgIds = chilrenOrgIdsIterator.next().left(); Iterator<Pair<TreeNode,NodePath>> chilrenOrgIdIterator = ifTraverser.find( (TreeNode node) -> {
--- a/src/test/java/jp/ac/u_ryukyu/cr/ie/tatsuki/functionTest/roleIdsTest.java Sat Oct 25 17:10:03 2014 +0900 +++ b/src/test/java/jp/ac/u_ryukyu/cr/ie/tatsuki/functionTest/roleIdsTest.java Sat Oct 25 19:42:44 2014 +0900 @@ -16,12 +16,13 @@ Iterator<String> orgIds = jugrix.roleIds("o:6"); orgIds.hasNext(); Assert.assertEquals(orgIds.next(),"r:18"); - + Assert.assertFalse(orgIds.hasNext()); + Iterator<String> personIds = jugrix.roleIds("p:1"); personIds.hasNext(); - Assert.assertEquals(personIds.next(),"r:34"); + Assert.assertEquals(personIds.next(),"r:10"); personIds.hasNext(); - Assert.assertEquals(personIds.next(),"r:10"); + Assert.assertEquals(personIds.next(),"r:34"); } }