Package org.apache.lenya.cms.publishing

Examples of org.apache.lenya.cms.publishing.PublishingEnvironment


        File servletContext = new File(servletContextPath);
        assert servletContext.exists();
        this.servletContext = servletContext;

        // FIXME: remove PublishingEnvironment from publication
        environment = new PublishingEnvironment(servletContextPath, id);

        File configFile = new File(getDirectory(), CONFIGURATION_FILE);
        DefaultConfigurationBuilder builder = new DefaultConfigurationBuilder();

        Configuration config;
View Full Code Here


        File servletContext = new File(servletContextPath);
        assert servletContext.exists();
        this.servletContext = servletContext;

        // FIXME: remove PublishingEnvironment from publication
        environment = new PublishingEnvironment(servletContextPath, id);

        File configFile = new File(getDirectory(), CONFIGURATION_FILE);
        DefaultConfigurationBuilder builder = new DefaultConfigurationBuilder();

        Configuration config;
View Full Code Here

            String publicationPath = PublishingEnvironment.getPublicationPath(contextPath,
                    publicationId);

            Parameters taskParameters = new Parameters();

            PublishingEnvironment environment = new PublishingEnvironment(contextPath, publicationId);

            // read default parameters from PublishingEnvironment
            taskParameters.setParameter("authoring-path", environment.getAuthoringPath());

            taskParameters.setParameter("tree-authoring-path", environment.getTreeAuthoringPath());

            taskParameters.setParameter("live-path", environment.getLivePath());

            taskParameters.setParameter("tree-live-path", environment.getTreeLivePath());

            taskParameters.merge(getParameters());

            parameterize(taskParameters);
View Full Code Here

            String publicationPath = PublishingEnvironment.getPublicationPath(contextPath,
                    publicationId);

            Parameters taskParameters = new Parameters();

            PublishingEnvironment environment = new PublishingEnvironment(contextPath, publicationId);

            // read default parameters from PublishingEnvironment
            taskParameters.setParameter("authoring-path", environment.getAuthoringPath());
            taskParameters.setParameter("tree-authoring-path", environment.getTreeAuthoringPath());
            taskParameters.setParameter("live-path", environment.getLivePath());
            taskParameters.setParameter("tree-live-path", environment.getTreeLivePath());

            taskParameters.merge(getParameters());
            parameterize(taskParameters);

            String sourcesString =
View Full Code Here

            return null;
        }

        publicationPath = PublishingEnvironment.getPublicationPath(contextPath, publicationId);

        PublishingEnvironment environment = new PublishingEnvironment(publicationPath);

        // set parameters using the request parameters
        log.debug("\n<parameters>");

        for (Enumeration e = request.getParameterNames(); e.hasMoreElements();) {
            String name = (String) e.nextElement();
            log.debug("\n  Parameter: " + name + " = " + request.getParameter(name));
        }

        log.debug("\n</parameters>");

        String articlePathParameter = request.getParameter(ARTICLE_FILE);
        String newDossierId = request.getParameter(DOSSIER_ID);

        String articlePath = publicationPath + environment.getAuthoringPath() + File.separator +
            articlePathParameter;

        String dossierBasePath = publicationPath + environment.getAuthoringPath() + File.separator +
            "dossiers" + File.separator;

        String newDossierPath = dossierBasePath + newDossierId + File.separator + "index.xml";

        File articleFile = new File(articlePath);
View Full Code Here

        File servletContext = new File(servletContextPath);
        assert servletContext.exists();
        this.servletContext = servletContext;
       
        // FIXME: remove PublishingEnvironment from publication
        environment = new PublishingEnvironment(servletContextPath, id);
    }
View Full Code Here

            if (publicationId.equals("")) {
                publicationDirectory = new File(".");
                buildFile = new File(buildFileName);
            }
            else {
                PublishingEnvironment environment
                    = new PublishingEnvironment(servletContextPath, publicationId);
                publicationDirectory = environment.getPublicationDirectory();
                buildFile = new File(publicationDirectory, buildFileName);
            }
           
            target = getParameters().getParameter(TARGET, null);
View Full Code Here

            String publicationPath = PublishingEnvironment.getPublicationPath(contextPath,
                    publicationId);

            Parameters taskParameters = new Parameters();

            PublishingEnvironment environment = new PublishingEnvironment(contextPath, publicationId);

            // read default parameters from PublishingEnvironment
            taskParameters.setParameter("authoring-path", environment.getAuthoringPath());

            taskParameters.merge(getParameters());
            parameterize(taskParameters);

            String sourcesString = getParameters().getParameter("sources");
View Full Code Here

     * @param contextPath DOCUMENT ME!
     */
    public void execute(String contextPath) {
        try {
            String publicationId = getParameters().getParameter("publication-id");
            PublishingEnvironment environment = new PublishingEnvironment(contextPath, publicationId);
            String publicationPath = environment.getPublicationPath();
            String authoringPath = environment.getAuthoringPath();
            clearNewsletter(publicationPath, authoringPath);
        } catch (Exception e) {
            log.error("Clearing newsletter failed: ", e);
        }
    }
View Full Code Here

            if (publicationId.equals("")) {
                publicationDirectory = new File(".");
                buildFile = new File(buildFileName);
            } else {
                PublishingEnvironment environment =
                    new PublishingEnvironment(
                        servletContextPath,
                        publicationId);
                publicationDirectory = environment.getPublicationDirectory();
                buildFile = new File(publicationDirectory, buildFileName);
            }

            target = getParameters().getParameter(TARGET, null);
View Full Code Here

TOP

Related Classes of org.apache.lenya.cms.publishing.PublishingEnvironment

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.