Package org.apache.jetspeed.page.document

Examples of org.apache.jetspeed.page.document.DocumentNotFoundException


    {
        // get link
        Link link = (Link) getAllNodes().subset(Link.DOCUMENT_TYPE).get(name);
        if (link == null)
        {
            throw new DocumentNotFoundException("Jetspeed PSML link not found: " + name);
        }

        // check access
        if (checkAccess)
        {
View Full Code Here


    {
        // get documentSet
        DocumentSet documentSet = (DocumentSet) getAllNodes().subset(DocumentSet.DOCUMENT_TYPE).get(name);
        if (documentSet == null)
        {
            throw new DocumentNotFoundException("Jetspeed PSML document set not found: " + name);
        }

        // check access
        if (checkAccess)
        {
View Full Code Here

        // get pageSecurity
        PageSecurity pageSecurity = (PageSecurity) getAllNodes().subset(PageSecurity.DOCUMENT_TYPE).get(PageSecurity.DOCUMENT_TYPE);
        if (pageSecurity == null)
        {
            throw new DocumentNotFoundException("Jetspeed PSML page security not found: " + PageSecurity.DOCUMENT_TYPE);
        }
        return pageSecurity;
    }
View Full Code Here

            if (link != null)
            {
                return link;
            }
        }
        throw new DocumentNotFoundException("Link " + name + " not found at " + getPath());
    }
View Full Code Here

            Link link = (Link)getPersistenceBrokerTemplate().getObjectByQuery(query);
           
            // return link or throw exception
            if (link == null)
            {
                throw new DocumentNotFoundException("Link " + path + " not found.");
            }

            // check for view access on link
            link.checkAccess(JetspeedActions.VIEW);

            return link;
        }
        catch (DocumentNotFoundException dnfe)
        {
            throw dnfe;
        }
        catch (SecurityException se)
        {
            throw se;
        }
        catch (Exception e)
        {
            throw new DocumentNotFoundException("Link " + path + " not found.", e);
        }
    }
View Full Code Here

            PageSecurity document = (PageSecurity)getPersistenceBrokerTemplate().getObjectByQuery(query);
           
            // return page or throw exception
            if (document == null)
            {
                throw new DocumentNotFoundException("Document " + path + " not found.");
            }

            // check for view access on document
            document.checkAccess(JetspeedActions.VIEW);

            return document;
        }
        catch (DocumentNotFoundException dnfe)
        {
            throw dnfe;
        }
        catch (SecurityException se)
        {
            throw se;
        }
        catch (Exception e)
        {
            throw new DocumentNotFoundException("Document " + path + " not found.", e);
        }
    }
View Full Code Here

        {
            throw dnfe;
        }
        catch (Exception e)
        {
            throw new DocumentNotFoundException("Link " + linkPath + " not found.", e);
        }
    }
View Full Code Here

            FolderImpl folder = getNodeFolder(path);
            return folder.getLink(getNodeName(path));
        }
        catch (FolderNotFoundException fnfe)
        {
            throw new DocumentNotFoundException(fnfe.getMessage());
        }
    }
View Full Code Here

            FolderImpl folder = getNodeFolder(Folder.PATH_SEPARATOR);
            return folder.getPageSecurity();
        }
        catch (FolderNotFoundException fnfe)
        {
            throw new DocumentNotFoundException(fnfe.getMessage());
        }
    }
View Full Code Here

        // select link by name from cached links collection
        Link link = (Link)getLinksNodeSet().get(name);
        if (link == null)
        {
            throw new DocumentNotFoundException("Link not found: " + name);
        }

        // check for view access on link
        link.checkAccess(JetspeedActions.VIEW);
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.page.document.DocumentNotFoundException

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.