Examples of TitlePathManager


Examples of de.innovationgate.wgpublisher.url.TitlePathManager

      this.fileName = WGUtils.serializeCollection(this.pathElements.subList(fileNameIndex, elementsSize), "/");     
      return;
    }
   
    // Find out if we have a title path URL
    TitlePathManager tpm = (TitlePathManager) database.getAttribute(WGACore.DBATTRIB_TITLEPATHMANAGER);
    if (tpm != null && tpm.isGenerateTitlePathURLs()) {
        TitlePathManager.TitlePath url = tpm.parseTitlePathURL(pathElements.subList(1, pathElements.size()));
        if (url != null) {
            this.pathType = TYPE_TITLE_PATH;
            this.titlePathURL = url;
            this.mediaKey = core.getMediaKey(url.getMediaKey());
            if (url.getLanguage() == null) {
View Full Code Here

Examples of de.innovationgate.wgpublisher.url.TitlePathManager

      if (this.pathType != TYPE_TITLE_PATH && this.pathType != TYPE_TML) {
          return null;
      }
     
      if (this.pathType == TYPE_TITLE_PATH) {
            TitlePathManager tpm = (TitlePathManager) this.database.getAttribute(WGACore.DBATTRIB_TITLEPATHMANAGER);
            List titlePath = tpm.buildTitlePath(this.content, mediaKey.getKey(), new RequestLanguageChooser(this.database, req));
            if (titlePath != null) {
                path.append(WGUtils.serializeCollection(titlePath, "/"));
            }
            // Cannot build a title path. We use a normal content path instead.
            else {
View Full Code Here

Examples of de.innovationgate.wgpublisher.url.TitlePathManager

        return requestLanguage;
    }
   
    public WGContent getContentByTitlePath(HttpServletRequest request) throws WGAPIException, UnsupportedEncodingException {

        TitlePathManager tpm = (TitlePathManager) database.getAttribute(WGACore.DBATTRIB_TITLEPATHMANAGER);
        TitlePath titlePathURL = getTitlePathURL();
       
        WGContent pathContent = null;
        try {
            pathContent = tpm.findContentByTitlePath(titlePathURL, database, new RequestLanguageChooser(database, request), TitlePathManager.MODE_URL);
        }
        catch (RemainingPathElementException e) {
            // Cannot happen with MODE_URL of title path manager
        }
       
View Full Code Here

Examples of de.innovationgate.wgpublisher.url.TitlePathManager

            // Container addressed by some kind of content key?
            WGContent content = getContentByAnyKey(containerKeyLastElement, database, request);

            // Container addressed by Title path?
            if (content == null) {
                TitlePathManager tpm = (TitlePathManager) database.getAttribute(WGACore.DBATTRIB_TITLEPATHMANAGER);
                if (tpm != null && tpm.isGenerateTitlePathURLs()) {
                    TitlePathManager.TitlePath url = tpm.parseTitlePathURL(containerKeyElems);
                    if (url != null) {
                        path.setTitlePathURL(url);
                        content = path.getContentByTitlePath(request);
                    }
                }
View Full Code Here

Examples of de.innovationgate.wgpublisher.url.TitlePathManager

                setLastDesignEncoding(db.getDbReference(), currentDesignEncoding);
            }

            // Initialize title path url manager
            try {
                TitlePathManager titlePathManager = new TitlePathManager(db, this, db.getBooleanAttribute(DBATTRIB_TITLEPATHURL, false));
                db.setAttribute(DBATTRIB_TITLEPATHMANAGER, titlePathManager);
            }
            catch (Exception e) {
                getLog().error("Error initializing title path manager for database " + db.getDbReference(), 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.