Package org.jboss.seam.wiki.plugin.forum

Examples of org.jboss.seam.wiki.plugin.forum.TopicHome


                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);
                home.newTopic();
            }
        }.run();

        new FacesRequest() {

            protected void beforeRequest() {
                setParameter("cid", conversationId);
            }

            protected void updateModelValues() throws Exception {
                WikiNodeDAO nodeDAO = (WikiNodeDAO)getInstance(WikiNodeDAO.class);
                WikiDirectory forumDir = nodeDAO.findWikiDirectory(102l);
                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);

                home.getInstance().setName("New Topic");
                home.getTextEditor().setValue("This is a new topic.");

                assert invokeMethod("#{topicHome.persist}") == null;

                Long newId = (Long)getValue("#{topicHome.instance.id}");
View Full Code Here


                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);
                home.newTopic();
            }
        }.run();

        new FacesRequest() {

            protected void beforeRequest() {
                setParameter("cid", conversationId);
            }

            protected void updateModelValues() throws Exception {
                WikiNodeDAO nodeDAO = (WikiNodeDAO)getInstance(WikiNodeDAO.class);
                WikiDirectory forumDir = nodeDAO.findWikiDirectory(102l);
                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);

                home.getInstance().setName("New Topic");
                home.getTextEditor().setValue("This is a new topic.");
                home.setSticky(true);

                assert invokeMethod("#{topicHome.persist}") == null;
               
                Long newId = (Long)getValue("#{topicHome.instance.id}");
View Full Code Here

                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);
                home.newTopic();
            }
        }.run();

        new FacesRequest() {

            protected void beforeRequest() {
                setParameter("cid", conversationId);
            }

            protected void updateModelValues() throws Exception {
                WikiNodeDAO nodeDAO = (WikiNodeDAO)getInstance(WikiNodeDAO.class);
                WikiDirectory forumDir = nodeDAO.findWikiDirectory(102l);
                Contexts.getPageContext().set("currentDirectory", forumDir);
                Contexts.getPageContext().set("currentDocument", forumDir.getDefaultFile());
            }

            protected void invokeApplication() throws Exception {
                TopicHome home = (TopicHome)getInstance(TopicHome.class);

                home.getInstance().setName("New Topic");
                home.getTextEditor().setValue("This is a new topic.");
                home.getInstance().setEnableComments(false);

                assert invokeMethod("#{topicHome.persist}") == null;

                Long newId = (Long)getValue("#{topicHome.instance.id}");
View Full Code Here

TOP

Related Classes of org.jboss.seam.wiki.plugin.forum.TopicHome

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.