Examples of URLInformation


Examples of org.apache.lenya.cms.publication.URLInformation

     * @see org.apache.lenya.ac.impl.AbstractAccessControllerResolver#generateCacheKey(java.lang.String, org.apache.excalibur.source.SourceResolver)
     */
    protected Object generateCacheKey(String webappUrl, SourceResolver resolver)
        throws AccessControlException {
         
        URLInformation info = new URLInformation(webappUrl);

        String publicationId = info.getPublicationId();
        if (getLogger().isDebugEnabled()) {
      getLogger().debug(
        "Using first URL step (might be publication ID) as cache key: [" + publicationId + "]");
        }

View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

        // remove leading slash
        String url = webappUrl.substring(1);

        if (url.length() > 0) {

      URLInformation info = new URLInformation(webappUrl);
            String publicationId = info.getPublicationId();

            File contextDir = getContext();
            if (PublicationFactory
                .existsPublication(publicationId, contextDir.getAbsolutePath())) {
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

        }
        return entries;
    }

    protected String getPublicationName(Usecase usecase) {
        URLInformation info = new URLInformation(usecase.getSourceURL());
        return info.getPublicationId();
    }
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

    public void setup(SourceResolver resolver, Map objectModel, String src, Parameters params)
            throws ProcessingException, SAXException, IOException {
        super.setup(resolver, objectModel, src, params);

        String webappUrl = getWebappUrl(params, objectModel);
        URLInformation url = new URLInformation(webappUrl);
        this.area = url.getArea();
    }
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

        try {
            Session session = RepositoryUtil.getSession(this.manager, request);
            DocumentFactory factory = DocumentUtil.createDocumentFactory(this.manager, session);
            String webappUrl = getWebappUrl(params, objectModel);
            URLInformation info = new URLInformation(webappUrl);
            String pubId = info.getPublicationId();
            this.rewriter = new IncomingLinkRewriter(factory.getPublication(pubId));
        } catch (final Exception e) {
            throw new RuntimeException(e);
        }
    }
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

     *      org.apache.excalibur.source.SourceResolver)
     */
    protected Object generateCacheKey(String webappUrl, SourceResolver resolver)
            throws AccessControlException {

        URLInformation info = new URLInformation(webappUrl);

        String publicationId = info.getPublicationId();
        if (getLogger().isDebugEnabled()) {
            getLogger().debug("Using first URL step (might be publication ID) as cache key: ["
                    + publicationId + "]");
        }

View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

        // remove leading slash
        String url = webappUrl.substring(1);

        if (url.length() > 0) {

            URLInformation info = new URLInformation(webappUrl);
            String pubId = info.getPublicationId();

            ContextUtility util = null;
            try {
                util = (ContextUtility) this.manager.lookup(ContextUtility.ROLE);
                Request request = util.getRequest();
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

*/
public class IndexSite extends AbstractUsecase {

    public void doExecute() throws Exception {
        String url = getSourceURL();
        URLInformation info = new URLInformation(url);
        String pubId = info.getPublicationId();

        DocumentFactory factory = getDocumentFactory();
        Publication pub = factory.getPublication(pubId);
        Area area = pub.getArea(info.getArea());

        Document[] docs = area.getDocuments();

        IndexUpdater updater = null;
        try {
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

            Request request = ObjectModelHelper.getRequest(objectModel);
            this.factory = DocumentUtil.getDocumentFactory(this.manager, request);
            this.linkResolver = (LinkResolver) this.manager.lookup(LinkResolver.ROLE);

            String webappUrl = ServletHelper.getWebappURI(request);
            URLInformation url = new URLInformation(webappUrl);
            this.pubId = url.getPublicationId();
            this.area = url.getArea();

        } catch (ServiceException e) {
            throw new ProcessingException(e);
        }
    }
View Full Code Here

Examples of org.apache.lenya.cms.publication.URLInformation

            String pubId = null;
            if (par.isParameter(PARAM_PUB)) {
                pubId = par.getParameter(PARAM_PUB);
            } else {
                String webappUrl = ServletHelper.getWebappURI(request);
                URLInformation info = new URLInformation(webappUrl);
                pubId = info.getPublicationId();
            }
            Publication pub = factory.getPublication(pubId);
            this.site = pub.getArea(area).getSite();

            if (this.path == null) {
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.