Examples of buildDocument()


Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

            builder.buildCanonicalUrl(
                publication,
                destinationArea,
                destinationDocumentId,
                destinationLanguage);
        Document destinationDocument = builder.buildDocument(publication, destinationUrl);
       
        publication.copyDocument(sourceDocument, destinationDocument);
       
        assertTrue(destinationDocument.exists());
       
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

                    Publication.LIVE_AREA,
                    documentId,
                    language);
        try {
            result =
                builder.buildDocument(envelope.getPublication(), url).exists();
        } catch (PublicationException e) {
            throw new SAXException(e);
        }
        return result;
    }
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

            DocumentBuilder builder = publication.getDocumentBuilder();

            String srcUrl =
                builder.buildCanonicalUrl(publication, document.getArea(), documentid, language);
            Document srcDoc = builder.buildDocument(publication, srcUrl);
            File newFile = srcDoc.getFile();
            filename = newFile.getAbsolutePath();

        } else {
            filename = document.getFile().getAbsolutePath();
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

        PageEnvelope envelope = PageEnvelopeFactory.getInstance().getPageEnvelope(objectModel);
        Publication publication = envelope.getPublication();
        DocumentBuilder builder = publication.getDocumentBuilder();
        String url = builder.buildCanonicalUrl(publication, area, documentId, language);
        Document document = builder.buildDocument(publication, url);

        WorkflowFactory factory = WorkflowFactory.newInstance();

        if (factory.hasWorkflow(document)) {
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

        Publication publication = PublicationFactory.getPublication(resolver, request);

        DocumentBuilder builder = publication.getDocumentBuilder();
        if (builder.isDocument(publication, url)) {

          Document document = builder.buildDocument(publication, url);
          WorkflowFactory factory = WorkflowFactory.newInstance();

          if (factory.hasWorkflow(document)) {
            SynchronizedWorkflowInstances instance =
              factory.buildSynchronizedInstance(document);
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

                            getLogger().debug(this.indent + "webapp URL: [" + webappUrl + "]");
                            getLogger().debug(this.indent + "anchor:     [" + anchor + "]");
                        }
                        if (builder.isDocument(publication, webappUrl)) {

                            Document targetDocument = builder.buildDocument(publication, webappUrl);

                            if (getLogger().isDebugEnabled()) {
                                getLogger().debug(this.indent + "Resolved target document: ["
                                        + targetDocument + "]");
                            }
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

                            String currentAreaUrl = builder.buildCanonicalUrl(publication,
                                    getCurrentDocument().getArea(),
                                    targetDocument.getId(),
                                    targetDocument.getLanguage());
                            targetDocument = builder.buildDocument(publication, currentAreaUrl);

                            if (targetDocument.exists()) {
                                rewriteLink(newAttrs, targetDocument, anchor, queryString);
                            } else {
                                setIgnoreAElement(true);
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

        Publication publication = getPublication(webappUrl);
        DocumentBuilder builder = publication.getDocumentBuilder();
        String url = null;
        try {
            if (builder.isDocument(publication, webappUrl)) {
                Document document = builder.buildDocument(publication, webappUrl);
                if (document.existsInAnyLanguage()) {
                    url = "/" + document.getArea() + document.getId();
                    if (getLogger().isDebugEnabled()) {
                        getLogger().debug("    Document exists");
                        getLogger().debug("    Document ID: [" + document.getId() + "]");
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

        String id = getParameters().getParameter(PARAMETER_DOCUMENT_ID);
        String language = getParameters().getParameter(PARAMETER_DOCUMENT_LANGUAGE);
        DocumentBuilder builder = getPublication().getDocumentBuilder();
        String url =
            builder.buildCanonicalUrl(getPublication(), Publication.AUTHORING_AREA, id, language);
        Document document = builder.buildDocument(getPublication(), url);
        return document;
    }

}
View Full Code Here

Examples of org.apache.lenya.cms.publication.DocumentBuilder.buildDocument()

        String id = getParameters().getParameter(PARAMETER_DOCUMENT_ID);
        String language = getParameters().getParameter(PARAMETER_DOCUMENT_LANGUAGE);
        DocumentBuilder builder = getPublication().getDocumentBuilder();
        String url =
            builder.buildCanonicalUrl(getPublication(), Publication.LIVE_AREA, id, language);
        Document document = builder.buildDocument(getPublication(), url);
        return document;
    }

}
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.