Examples of saveComment()


Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

        testComment.setWeblogEntry(getManagedWeblogEntry(entry));
        testComment.setStatus(WeblogEntryComment.APPROVED);
       
        // store testComment
        WeblogEntryManager mgr = WebloggerFactory.getWeblogger().getWeblogEntryManager();
        mgr.saveComment(testComment);
       
        // flush to db
        WebloggerFactory.getWeblogger().flush();
       
        // query for object
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

            try {              
                if(!WeblogEntryComment.SPAM.equals(comment.getStatus()) ||
                        !WebloggerRuntimeConfig.getBooleanProperty("comments.ignoreSpam.enabled")) {
                   
                    WeblogEntryManager mgr = WebloggerFactory.getWeblogger().getWeblogEntryManager();
                    mgr.saveComment(comment);
                    WebloggerFactory.getWeblogger().flush();
                   
                    // Send email notifications only to subscribers if comment is 100% valid
                    boolean notifySubscribers = (validationScore == 100);
                    MailUtil.sendEmailNotification(comment, messages, messageUtils, notifySubscribers);
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                // save, commit, send response
                if(!WeblogEntryComment.SPAM.equals(comment.getStatus()) ||
                        !WebloggerRuntimeConfig.getBooleanProperty("trackbacks.ignoreSpam.enabled")) {
                   
                    WeblogEntryManager mgr = WebloggerFactory.getWeblogger().getWeblogEntryManager();
                    mgr.saveComment(comment);
                    WebloggerFactory.getWeblogger().flush();
                   
                    // only invalidate the cache if comment isn't moderated
                    if(!weblog.getCommentModerationRequired()) {
                        // Clear all caches associated with comment
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                if (weblog.hasUserPermission(rses.getAuthenticatedUser(), WeblogPermission.POST)) {
                    String content = Utilities.streamToString(request.getInputStream());
                    c.setContent(content);
                    // don't update the posttime when updating the comment
                    c.setPostTime(c.getPostTime());
                    wmgr.saveComment(c);
                    roller.flush();

                    c = wmgr.getComment(request.getParameter("id"));
                    content = Utilities.escapeHTML(c.getContent());
                    content = WordUtils.wrap(content, 72);
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                // mark/unmark spam
                if (spamIds.contains(ids[i]) &&
                        !WeblogEntryComment.SPAM.equals(comment.getStatus())) {
                    log.debug("Marking as spam - "+comment.getId());
                    comment.setStatus(WeblogEntryComment.SPAM);
                    wmgr.saveComment(comment);
                   
                    flushList.add(comment.getWeblogEntry().getWebsite());
                } else if(WeblogEntryComment.SPAM.equals(comment.getStatus())) {
                    log.debug("Marking as approved - "+comment.getId());
                    comment.setStatus(WeblogEntryComment.APPROVED);
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                   
                    flushList.add(comment.getWeblogEntry().getWebsite());
                } else if(WeblogEntryComment.SPAM.equals(comment.getStatus())) {
                    log.debug("Marking as approved - "+comment.getId());
                    comment.setStatus(WeblogEntryComment.APPROVED);
                    wmgr.saveComment(comment);
                   
                    flushList.add(comment.getWeblogEntry().getWebsite());
                }
            }
           
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                            approvedComments.add(comment);
                        }
                       
                        log.debug("Marking as approved - "+comment.getId());
                        comment.setStatus(WeblogEntryComment.APPROVED);
                        wmgr.saveComment(comment);
                       
                        flushList.add(comment);
                        reindexList.add(comment.getWeblogEntry());
                       
                    } else if(spamIds.contains(ids[i])) {
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                        reindexList.add(comment.getWeblogEntry());
                       
                    } else if(spamIds.contains(ids[i])) {
                        log.debug("Marking as spam - "+comment.getId());
                        comment.setStatus(WeblogEntryComment.SPAM);
                        wmgr.saveComment(comment);
                       
                        flushList.add(comment);
                        reindexList.add(comment.getWeblogEntry());

                    } else if(!WeblogEntryComment.DISAPPROVED.equals(comment.getStatus())) {
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogEntryManager.saveComment()

                        reindexList.add(comment.getWeblogEntry());

                    } else if(!WeblogEntryComment.DISAPPROVED.equals(comment.getStatus())) {
                        log.debug("Marking as disapproved - "+comment.getId());
                        comment.setStatus(WeblogEntryComment.DISAPPROVED);
                        wmgr.saveComment(comment);
                       
                        flushList.add(comment);
                        reindexList.add(comment.getWeblogEntry());
                    }
                }
View Full Code Here

Examples of org.apache.roller.weblogger.business.WeblogManager.saveComment()

        testComment.setWeblogEntry(getManagedWeblogEntry(entry));
        testComment.setStatus(WeblogEntryComment.APPROVED);
       
        // store testComment
        WeblogManager mgr = WebloggerFactory.getWeblogger().getWeblogManager();
        mgr.saveComment(testComment);
       
        // flush to db
        WebloggerFactory.getWeblogger().flush();
       
        // query for object
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.