Package org.apache.lenya.cms.publication

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


                                docId,
                                language);
                        log.debug("url: " + url);
                    } else {
                        url =
                            builder.buildCanonicalUrl(
                                publication,
                                Publication.AUTHORING_AREA,
                                docId);
                        log.debug("url: " + url);
                    }
View Full Code Here


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

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

            Publication publication = envelope.getPublication();

            DocumentBuilder builder = publication.getDocumentBuilder();

            // Create canonical URL
            String canonicalUrl = builder
                    .buildCanonicalUrl(publication, area, documentId, language);

            if (getLogger().isDebugEnabled()) {
                getLogger().debug("Created canonicalURL: " + canonicalUrl);
            }
View Full Code Here

        throws ParameterException, DocumentBuildException, ExecutionException {
        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

        throws ParameterException, DocumentBuildException, ExecutionException {
        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

    // FIXME: if the resources differ for different languages, so iterate
    // on all languages

    String language = labels[0].getLanguage();
    String srcUrl =
      builder.buildCanonicalUrl(
        publication,
        getFirstarea(),
        srcDocumentid,
        language);
    Document srcDoc;
View Full Code Here

          + getFirstdocumentid());
      return;
    }

    String destUrl =
      builder.buildCanonicalUrl(
        publication,
        getSecarea(),
        destDocumentid,
        language);
    Document destDoc;
View Full Code Here

    Label[] labels = node.getLabels();
    for (int i = 0; i < labels.length; i++) {
      String language = labels[i].getLanguage();
      String url =
        builder.buildCanonicalUrl(
          publication,
          getFirstarea(),
          srcDocumentid,
          language);
      Document doc;
View Full Code Here

        String publisher,
        String rights)
        throws BuildException, DocumentBuildException, DocumentException {

        DocumentBuilder builder = getPublication().getDocumentBuilder();
        String url = builder.buildCanonicalUrl(getPublication(), area, documentId, lang);
        Document doc = builder.buildDocument(getPublication(), url);
        DublinCore dc = doc.getDublinCore();
        dc.setCreator(creator);
        dc.setTitle(title);
        dc.setDescription(description);
View Full Code Here

        labels = node.getLabels();
      }
      if (node == null | (labels != null && labels.length < 1)) {

        DocumentBuilder builder = publication.getDocumentBuilder();
        String url = builder.buildCanonicalUrl(publication, area, documentid, language);
        Document doc;
        try {
          doc = builder.buildDocument(publication, url);
        } catch (DocumentBuildException e) {
          throw new BuildException(e);
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.