Examples of DavItem


Examples of org.apache.wiki.dav.items.DavItem

    {
        Namespace davns = Namespace.getNamespace( "DAV:" );
       
        Element root = new Element("multistatus", davns);

        DavItem di = m_provider.getItem( dc.getPath() );

        if( di == null )
        {
            throw new FileNotFoundException( dc.getPath().toString() );
        }
       
        for( Iterator i = di.iterator(dc.getDepth()); i.hasNext(); )
        {
            di = (DavItem) i.next();
                   
            Element response = new Element("response", davns);

            response.addContent( new Element("href",davns).setText( di.getHref() ) );
                   
            Element props = new Element("prop", davns);
            Element failedprops = new Element("prop", davns );
           
            //
            //  Get the matching property set
            //
            Collection c = di.getPropertySet();
           
            if( askedprops == null )
            {
                for( Iterator j = c.iterator(); j.hasNext(); )
                {
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testGetPageURL()
        throws Exception
    {
        engine.saveText("TestPage", "foobar");
       
        DavItem di = m_provider.getItem( new DavPath("t/TestPage.txt") );
       
        assertNotNull( "No di", di );
        assertEquals("URL", "http://localhost/dav/raw/t/TestPage.txt", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL()
        throws Exception
    {
        engine.saveText("TestPage", "foobar");
   
        DavItem di = m_provider.getItem( new DavPath("") );
   
        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/dav/raw/", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL2()
        throws Exception
    {
        engine.saveText("TestPage", "foobar");

        DavItem di = m_provider.getItem( new DavPath("t/") );

        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/dav/raw/t/", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

        engine.saveText("TestPage", "foobar");
        Attachment att = new Attachment(engine,"TestPage","deceit of the tribbles.txt");
       
        engine.getAttachmentManager().storeAttachment( att, engine.makeAttachmentFile() );
       
        DavItem di = m_provider.getItem( new DavPath("TestPage/deceit of the tribbles.txt") );
       
        assertNotNull( "No di", di );
        assertEquals("URL", "http://localhost/attach/TestPage/deceit%20of%20the%20tribbles.txt",
                     di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL()
        throws Exception
    {
        engine.saveText("TestPage", "foobar");
   
        DavItem di = m_provider.getItem( new DavPath("") );
   
        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/attach/", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL2()
        throws Exception
    {
        engine.saveText("TestPage", "foobar");

        DavItem di = m_provider.getItem( new DavPath("TestPage/") );

        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/attach/TestPage/", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testGetPageURL()
    throws Exception
    {
        engine.saveText("TestPage", "foobar");
           
        DavItem di = m_provider.getItem( new DavPath("t/TestPage.html") );
           
        assertNotNull( "No di", di );
        assertEquals("URL", "http://localhost/dav/html/t/TestPage.html", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL()
    throws Exception
    {
        engine.saveText("TestPage", "foobar");
       
        DavItem di = m_provider.getItem( new DavPath("") );
       
        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/dav/html/", di.getHref() );
    }
View Full Code Here

Examples of org.apache.wiki.dav.items.DavItem

    public void testDirURL2()
    throws Exception
    {
        engine.saveText("TestPage", "foobar");

        DavItem di = m_provider.getItem( new DavPath("t/") );

        assertNotNull( "No di", di );
        assertTrue( "DI is of wrong type", di instanceof DirectoryItem );
        assertEquals("URL", "http://localhost/dav/html/t/", di.getHref() );
    }
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.