Examples of PingTarget


Examples of org.apache.roller.weblogger.pojos.PingTarget

        }
       
        // Somewhat awkward, but the two loops save building a separate combined list.
        // Add disabled common ones with FALSE
        for (Iterator i = getCommonPingTargets().iterator(); i.hasNext();) {
            PingTarget pingTarget = (PingTarget) i.next();
            if (isEnabled.get(pingTarget.getId()) == null) {
                isEnabled.put(pingTarget.getId(), Boolean.FALSE);
            }
        }
       
        // Add disabled custom ones with FALSE
        for (Iterator i = getCustomPingTargets().iterator(); i.hasNext();) {
            PingTarget pingTarget = (PingTarget) i.next();
            if (isEnabled.get(pingTarget.getId()) == null) {
                isEnabled.put(pingTarget.getId(), Boolean.FALSE);
            }
        }
       
        if(isEnabled.size() > 0) {
            setPingStatus(isEnabled);
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

        // add any auto enabled ping targets
        PingTargetManager pingTargetMgr = roller.getPingTargetManager();
        AutoPingManager autoPingMgr = roller.getAutopingManager();
       
        Iterator pingTargets = pingTargetMgr.getCommonPingTargets().iterator();
        PingTarget pingTarget = null;
        while(pingTargets.hasNext()) {
            pingTarget = (PingTarget) pingTargets.next();
           
            if(pingTarget.isAutoEnabled()) {
                AutoPing autoPing = new AutoPing(
                        null, pingTarget, newWeblog);
                autoPingMgr.saveAutoPing(autoPing);
            }
        }
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

    /**
     * Save a new ping target.
     */
    public String save() {
       
        PingTarget pingTarget = createPingTarget();
       
        // Call private helper to validate ping target
        // If there are errors, go back to the target edit page.
        myValidate(pingTarget);
       
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

    }
   
   
    protected PingTarget createPingTarget() {
       
        return new PingTarget(
                null,
                getBean().getName(),
                getBean().getPingUrl(),
                null,
                false);
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

     *                         handled, not thrown.
     */
    private void processQueueEntry(PingQueueEntry pingQueueEntry) throws WebloggerException {
        if (logger.isDebugEnabled()) logger.debug("Processing ping queue entry: " + pingQueueEntry);
       
        PingTarget pingTarget = pingQueueEntry.getPingTarget();
        Weblog website = pingQueueEntry.getWebsite();
        boolean pingSucceeded = false;
        if (PingConfig.getLogPingsOnly()) {
            // Just log the ping and pretend it succeeded.
            logger.info("Logging simulated ping for ping queue entry " + pingQueueEntry);
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

            Matcher m = NESTED_BRACE_PAIR.matcher(thisTarget);
            if (m.matches() && m.groupCount() == 2) {
                String name = m.group(1).trim();
                String url = m.group(2).trim();
                logger.info("Creating common ping target '" + name + "' from configuration properties.");
                PingTarget pingTarget = new PingTarget(null, name, url, null, false);
                pingTargetMgr.savePingTarget(pingTarget);
            } else {
                logger.error("Unable to parse configured initial ping target '" + thisTarget + "'. Skipping this target. Check your setting of the property " + PINGS_INITIAL_COMMON_TARGETS_PROP);
            }
        }
View Full Code Here

Examples of org.apache.roller.weblogger.pojos.PingTarget

       
        // Within that set of targets, fail if there is a target
        // with the same name and that target doesn't
        // have the same id.
        for (Iterator i = brotherTargets.iterator(); i.hasNext();) {
            PingTarget brother = (PingTarget) i.next();
            // Fail if it has the same name but not the same id.
            if (brother.getName().equals(name) &&
                (id == null || !brother.getId().equals(id))) {
                return false;
            }
        }
        // No conflict found
        return true;
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.