Package org.jdom2

Examples of org.jdom2.Document.addContent()


        //
        //  Optional
        //
        channel.addContent( new Element("language").setText(getChannelLanguage()));
        channel.addContent( new Element("generator").setText("JSPWiki "+Release.VERSTR));

        String mail = engine.getVariable(m_wikiContext,RSSGenerator.PROP_RSS_AUTHOREMAIL);
        if( mail != null )
        {
            String editor = engine.getVariable( m_wikiContext,RSSGenerator.PROP_RSS_AUTHOR );
View Full Code Here


            String editor = engine.getVariable( m_wikiContext,RSSGenerator.PROP_RSS_AUTHOR );

            if( editor != null )
                mail = mail + " ("+editor+")";

            channel.addContent( new Element("managingEditor").setText(mail) );
        }

        //
        //  Items
        //
View Full Code Here

        //
        //  Items
        //

        channel.addContent( getItems() );

        //
        //  aaand output
        //
        XMLOutputter output = new XMLOutputter();
View Full Code Here

        text = escapeHTMLEntities( text );
        section = escapeHTMLEntities( section );
        Element el = new Element("a");
        el.setAttribute("class",CLASS_TYPES[type]);
        el.setAttribute("href",link+section);
        el.addContent(text);
        return el;
    }

    private Element makeLink( int type, String link, String text, String section, Iterator attributes )
    {
View Full Code Here

            //
            //  Mandatory elements
            //

            entryEl.addContent( getElement("id").setText( getEntryID(e)) );
            entryEl.addContent( getElement("title").setAttribute("type","html").setText( e.getTitle() ));
            entryEl.addContent( getElement("updated").setText( DateFormatUtils.formatUTC(p.getLastModified(),
                                                                                         RFC3339FORMAT )));
            //
            //  Optional elements
View Full Code Here

            //
            //  Mandatory elements
            //

            entryEl.addContent( getElement("id").setText( getEntryID(e)) );
            entryEl.addContent( getElement("title").setAttribute("type","html").setText( e.getTitle() ));
            entryEl.addContent( getElement("updated").setText( DateFormatUtils.formatUTC(p.getLastModified(),
                                                                                         RFC3339FORMAT )));
            //
            //  Optional elements
            //
View Full Code Here

                break;

            case LOCAL:
                el = new Element("a").setAttribute("class","footnote");
                el.setAttribute("name", "ref-"+m_context.getName()+"-"+link.substring(1));
                el.addContent("["+text+"]");
                break;

                //
                //  With the image, external and interwiki types we need to
                //  make sure nobody can put in Javascript or something else
View Full Code Here

            //  Mandatory elements
            //

            entryEl.addContent( getElement("id").setText( getEntryID(e)) );
            entryEl.addContent( getElement("title").setAttribute("type","html").setText( e.getTitle() ));
            entryEl.addContent( getElement("updated").setText( DateFormatUtils.formatUTC(p.getLastModified(),
                                                                                         RFC3339FORMAT )));
            //
            //  Optional elements
            //
View Full Code Here

                                                                                         RFC3339FORMAT )));
            //
            //  Optional elements
            //

            entryEl.addContent( getElement("author").addContent( getElement("name").setText( e.getAuthor() )));
            entryEl.addContent( getElement("link").setAttribute("rel","alternate").setAttribute("href",e.getURL()));
            entryEl.addContent( getElement("content").setAttribute("type","html").setText( e.getContent() ));

            //
            //  Check for enclosures
View Full Code Here

            //
            //  Optional elements
            //

            entryEl.addContent( getElement("author").addContent( getElement("name").setText( e.getAuthor() )));
            entryEl.addContent( getElement("link").setAttribute("rel","alternate").setAttribute("href",e.getURL()));
            entryEl.addContent( getElement("content").setAttribute("type","html").setText( e.getContent() ));

            //
            //  Check for enclosures
            //
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.