Package com.ecyrd.jspwiki.attachment

Examples of com.ecyrd.jspwiki.attachment.Attachment


               
                CacheEntry e = aEvent.getEntry();
               
                if( e != null )
                {
                    Attachment item = (Attachment) e.getContent();

                    if( item != null )
                    {
                        m_allItems.remove( item.getName() );
                    }
                }
            }
        }
View Full Code Here


            if( log.isDebugEnabled() )
            {
                log.debug( "attachment cache entry updated: " + aEvent.getKey() );
            }

            Attachment item = (Attachment) aEvent.getEntry().getContent();

            if( item != null )
            {
                // Item added or replaced.
                m_allItems.put( item.getName(), item );
            }
            else
            {
                m_allItems.remove( aEvent.getKey() );
            }
View Full Code Here

        }

        try
        {
            AttachmentManager mgr = engine.getAttachmentManager();
            Attachment        att = mgr.getAttachmentInfo( context, src );

            if( att != null )
            {
                src = context.getURL( WikiContext.ATTACH, att.getName() );
            }
        }
        catch( ProviderException e )
        {
            throw new PluginException( "Attachment info failed: "+e.getMessage() );
View Full Code Here

        {
            Collection atts = m_engine.getAttachmentManager().getAllAttachments();

            for( Iterator i = atts.iterator(); i.hasNext(); )
            {
                Attachment att = (Attachment)i.next();

                String pageName = att.getParentName();

                if( !pageNames.contains(pageName) )
                    pageNames.add( pageName );
            }
        }
View Full Code Here

            WikiPage page = m_engine.getPage( pageName );
            Collection attachments = m_engine.getAttachmentManager().listAttachments(page);

            for( Iterator i = attachments.iterator(); i.hasNext(); )
            {
                Attachment att = (Attachment) i.next();

                DavPath thisPath = new DavPath( "/" );

                thisPath.append( att.getName() );

                AttachmentItem ai = new AttachmentItem( this, thisPath, att );

                result.add( ai );
            }
View Full Code Here

        {
            String attName = path.getPath();

            try
            {
                Attachment att = m_engine.getAttachmentManager().getAttachmentInfo( attName );

                if( att != null )
                {
                    AttachmentItem ai = new AttachmentItem( this, path, att );
View Full Code Here

                m_iterator = atts.iterator();

                if( m_iterator.hasNext() )
                {
                    Attachment  att = (Attachment) m_iterator.next();

                    WikiContext context = (WikiContext)m_wikiContext.clone();
                    context.setPage( att );
                    pageContext.setAttribute( WikiTagBase.ATTR_CONTEXT,
                                              context,
View Full Code Here

            }
        }

        if( m_iterator != null && m_iterator.hasNext() )
        {
            Attachment att = (Attachment) m_iterator.next();

            WikiContext context = (WikiContext)m_wikiContext.clone();
            context.setPage( att );
            pageContext.setAttribute( WikiTagBase.ATTR_CONTEXT,
                                      context,
View Full Code Here

                                //
                                continue;
                            }
                        }

                        Attachment att = getAttachmentInfo( page, attachmentName,
                                                            WikiProvider.LATEST_VERSION );

                        //
                        //  Sanity check - shouldn't really be happening, unless
                        //  you mess with the repository directly.
View Full Code Here

           
            Collection c = listAttachments( new WikiPage( m_engine, pageId ) );

            for( Iterator it = c.iterator(); it.hasNext(); )
            {
                Attachment att = (Attachment) it.next();

                if( att.getLastModified().after( timestamp ) )
                {
                    list.add( att );
                }
            }
        }
View Full Code Here

TOP

Related Classes of com.ecyrd.jspwiki.attachment.Attachment

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.