Package org.jboss.seam.wiki.core.dao

Examples of org.jboss.seam.wiki.core.dao.TagDAO


        new FacesRequest() {

            protected void invokeApplication() throws Exception {
                WikiDirectory wikiRoot = (WikiDirectory)getInstance("wikiRoot");

                TagDAO dao = (TagDAO)getInstance(TagDAO.class);
                List<DisplayTagCount> tags = dao.findTagCounts(wikiRoot, null, 0, 1l);
                assert tags.size() == 3;
                assert tags.get(0).getTag().equals("Tag One");
                assert tags.get(0).getCount().equals(3l);
                assert tags.get(1).getTag().equals("Tag Two");
                assert tags.get(1).getCount().equals(2l);
View Full Code Here


        new FacesRequest() {

            protected void invokeApplication() throws Exception {
                WikiDirectory startDir = ((WikiNodeDAO)getInstance(WikiNodeDAO.class)).findWikiDirectory(4l);

                TagDAO dao = (TagDAO)getInstance(TagDAO.class);
                List<DisplayTagCount> tags = dao.findTagCounts(startDir, null, 2, 1l);

                assert tags.size() == 2;
                assert tags.get(0).getTag().equals("Tag One");
                assert tags.get(0).getCount().equals(1l);
                assert tags.get(1).getTag().equals("Tag Three");
View Full Code Here

        new FacesRequest() {

            protected void invokeApplication() throws Exception {
                WikiDirectory startDir = ((WikiNodeDAO)getInstance(WikiNodeDAO.class)).findWikiDirectory(3l);

                TagDAO dao = (TagDAO)getInstance(TagDAO.class);
                List<WikiFile> taggedFiles = dao.findWikFiles(startDir, null, "Tag One", WikiNode.SortableProperty.name, true);

                Assert.assertEquals(taggedFiles.size(), 3);

                Assert.assertEquals(taggedFiles.get(0).getName(), "One");
                Assert.assertEquals(taggedFiles.get(1).getName(), "Three");
View Full Code Here

TOP

Related Classes of org.jboss.seam.wiki.core.dao.TagDAO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.