zoukankan      html  css  js  c++  java
  • RSS接触 RSS中的XML文档

    整个文档的格式为(摘自百度百科):

    <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
    <rss version="2.0">
        <!-- 以下为频道信息及新闻列表 -->  
        <channel>
            <!-- 频道总体信息:开始 -->  
            <!-- 频道标题 -->   
            <title>Lift Off News</title>  
            <!-- 频道链接的总地址 -->  
            <link>http://liftoff.msfc.nasa.gov/</link>   
            <!-- 频道描述文字 -->  
            <description>Liftoff to Space Exploration.</description>
            <!-- 频道使用的语言(zh-cn表示简体中文) -->
            <language>en-us</language>  
            <!-- 频道发布的时间 -->   
            <pubDate>Tue, 10 Jun 2003 04:00:00 GMT</pubDate>  
            <!-- 频道最后更新的时间-->   
            <lastBuildDate>Tue, 10 Jun 2003 09:41:01 GMT</lastBuildDate>
            <docs>http://blogs.law.harvard.edu/tech/rss</docs>  
            <!-- 频道生成器 -->
            <generator>Weblog Editor 2.0</generator>
            <managingEditor>editor@example.com</managingEditor>
            <webMaster>webmaster@example.com</webMaster>  
            <ttl>5</ttl>   
            <!-- 频道总体信息:结束 -->  
            <!-- 每条RSS新闻信息都包含在item节点中, -->  
            <item>
                <!-- 新闻标题 -->  
                <title>Star City</title>   
                <!-- 新闻链接地址 -->  
                <link>http://liftoff.msfc.nasa.gov/news/2003/news-starcity.asp</link>  
                <!-- 新闻内容简要描述 -->  
                <description>How do Americans get ready to work with Russians aboard the   International Space Station? They take a crash course in culture, language   and protocol at Russia's Star City.</description>   
                <!-- 新闻发布时间 -->   
                <pubDate>Tue, 03 Jun 2003 09:39:21 GMT</pubDate>  
                <!-- 新闻目录 -->   
                <category>IT</category>   
                <!-- 新闻作者 -->  
                <author>bill</author>  
                <guid>http://liftoff.msfc.nasa.gov/2003/06/03.html#item573</guid>
            </item>  
            <item>
                <title>Space Exploration</title>  
                <link>http://liftoff.msfc.nasa.gov/</link>
                <description>Sky watchers in Europe, Asia, and parts of Alaska and Canada   will experience a partial eclipse of the Sun on Saturday, May 31st.</description>
                <pubDate>Fri, 30 May 2003 11:06:42 GMT</pubDate>   
                <guid>http://liftoff.msfc.nasa.gov/2003/05/30.html#item572</guid>    
    
            </item> 
        </channel>  
    </rss>
  • 相关阅读:
    HashMap源码分析
    LinkedList源码分析
    ArrayList源码学习
    Java容器知识总结
    Collections 工具类和 Arrays 工具类常见方法
    Java基础知识
    MySQL高级之索引优化分析
    MySQL命令大全
    Java IO
    SpringCloud笔记
  • 原文地址:https://www.cnblogs.com/liszt/p/2013123.html
Copyright © 2011-2022 走看看