Package org.apache.ecs.xml

Examples of org.apache.ecs.xml.XML


        }
    }
   
    private XML getChannelElement()
    {
        XML channel = new XML( "channel" );

        channel.addAttribute("rdf:about", m_feedURL );
       
        channel.addElement( new XML("link").addElement( m_feedURL ) );
       
        if( m_channelTitle != null )
            channel.addElement( new XML("title").addElement( format(m_channelTitle)) );
       
        if( m_channelDescription != null )
            channel.addElement( new XML("description").addElement( format(m_channelDescription)) );
       
        if( m_channelLanguage != null )
            channel.addElement( new XML("dc:language").addElement(m_channelLanguage) );

        channel.setPrettyPrint( true );
       
        channel.addElement( getRDFItems() );
       
        return channel;
    }
View Full Code Here


     {@inheritDoc}
     */
    @Override
    public String getString()
    {
        XML root = new XML("rdf:RDF");
       
        root.addAttribute( "xmlns:rdf", "http://www.w3.org/1999/02/22-rdf-syntax-ns#" );
        root.addAttribute( "xmlns", "http://purl.org/rss/1.0/" );
        root.addAttribute( "xmlns:dc", "http://purl.org/dc/elements/1.1/" );
        root.addAttribute( "xmlns:wiki", "http://purl.org/rss/1.0/modules/wiki/" );
       
        root.addElement( getChannelElement() );
       
        addItemList( root );
       
        root.setPrettyPrint( true );
               
        return root.toString();
    }
View Full Code Here

TOP

Related Classes of org.apache.ecs.xml.XML

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.