-
Notifications
You must be signed in to change notification settings - Fork 4
/
953.txt
216 lines (150 loc) · 6.47 KB
/
953.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
[1] [[RSS]] の [DFN[[CODE(XMLe)@en[[[pubDate]]]] [[チャンネル要素]]]]は、
[[チャンネル]]の[[内容]]の[[出版日]]を表します [SRC@en[[[RSS 2.0]]]]。
[CODE(XMLe)@en[[[item]]]] [[要素]]の[[子要素]]の
[DFN[[CODE(XMLe)@en[[[pubDate]]]] [[要素]]]]は、
[[項目]]の[[出版日]]を表します [SRC@en[[[RSS 2.0]]]]。
:[[要素名]]:[CODE(XMLe)@en[[[pubDate]]]]
(publication date ([[出版日]]) より)
:文脈:[[チャンネル要素]]が認められる文脈、
[CODE(XMLe)@en[[[item]]]] [[要素]]の[[子要素]]として
:[[内容モデル]]:[[RFC 822の日付形式]]
:[[属性]]:
仕様書:
-[CITE@en[RSS 2.0 Specification (version 2.0.10)]] ([TIME[2008-11-21 13:42:42 +09:00]] 版)
-- <http://www.rssboard.org/rss-specification#optionalChannelElements>
-- <http://www.rssboard.org/rss-specification#hrelementsOfLtitemgt>
-- <http://www.rssboard.org/rss-specification#ltpubdategtSubelementOfLtitemgt>
-[CITE@en[RSS Best Practices Profile]]
--<http://www.rssboard.org/rss-profile#element-channel-pubdate>
--<http://www.rssboard.org/rss-profile#element-channel-item-pubdate>
* 意味
[2] [CODE(XMLe)@en[[[pubDate]]]] [[要素]]は[[チャンネル]]の[[出版日]]を表します。
「[[チャンネル]]の[[出版日]]」について、 [[RSS 2.0]] 仕様書は次のような例を示しています。
[[New York Times]] は毎日発行されます。ですので、発行日は24時間毎に変化します。
この変換する時というのが、[[チャンネル]]の [CODE(XMLe)@en[[[pubDate]]]]
が変化する時です。
;; [3] わかったようなわからないような説明ですね。
[8] [CODE(XMLe)@en[[[item]]]] [[要素]]の[[子要素]]の
[CODE(XMLe)@en[[[pubDate]]]] [[要素]]は、[[項目]]が[[出版]]された時を表します
[SRC@en[[[RSS 2.0]]]]。
* 内容
[10] [CODE(XMLe)@en[[[pubDate]]]] の[[内容]]は [[RFC 822の日付形式]]です
[SRC@en[[[RSS 2.0]]]]。
[11] [CODE(XMLe)@en[[[channel]]]] [[要素]]の[[子要素]]である
[CODE(XMLe)@en[[[pubDate]]]] [[要素]]については、
[[4桁年号]]が利用可能であると明記されています [SRC@en[[[RSS 2.0]]]]。
[CODE(XMLe)@en[[[item]]]] [[要素]]の[[子要素]]である場合については例 (>>7)
に[[4桁年号]]を用いたものがありますが、利用可能と明記はされていません。
[12] 詳しくは [[RFC 822の日付形式]]の項を参照してください。
* 将来の日付
[9]
[[日付]]が将来の場合、[[集積器]]はその[[項目]]をその[[日付]]まで表示しないことにして構いません
[SRC@en[[[RSS 2.0]]]]。
[16] [[集積器]]は[[将来の日付]]の[[項目]]を無視する[['''べきです''']]
[SRC@en[[[RSS Best Practices Profile]]]]。
[17] [[出版者]]は[[項目]]が[[出版]]してよくなるまで[[フィード]]に含める[['''べきではありません''']]
[SRC@en[[[RSS Best Practices Profile]]]]。
[18] [[RSS Best Practices Profile]] によると、[[将来の日付]]を指定しても、
その日まで示さないでおくような[[集積器]]はありませんでした。
[19] [[電子メイル]]の場合から類推すると、日付の設定が間違っていて将来になっていることはわりとよくあるので、
そんな場合でも存在する[[項目]]が見れなくなってしまうことがないように、
将来のものは隠すような実装は難しいのではないでしょうか。
* 例
[4]
[PRE(XML example code)[
<pubDate>Sat, 07 Sep 2002 00:00:01 GMT</pubDate>
]PRE]
;; [[RSS 2.0]] 仕様書より、改
[7]
[PRE(XML example code)[
<pubDate>Sun, 19 May 2002 15:21:36 GMT</pubDate>
]PRE]
;; [[RSS 2.0]] 仕様書より
[13]
[PRE(XML example code)[
<pubDate>Mon, 15 Oct 2007 14:10:00 GMT</pubDate>
]PRE]
;; [[RSS Best Practices Profile]] より
[14]
[PRE(XML example code)[
<pubDate>Mon, 15 Oct 2007 08:10:00 -0600</pubDate>
]PRE]
;; [[RSS Best Practices Profile]] より
[15]
[PRE(XML example code)[
<pubDate>Sun, 14 Oct 2007 05:00:00 GMT</pubDate>
]PRE]
;; [[RSS Best Practices Profile]] より
[20] [CITE[Bloglines | News]] ([TIME[2009-03-07 18:14:50 +09:00]] 版) <http://www.bloglines.com/rss/about/news>
[PRE(XML bad example code)[
<pubDate>Thu, November 15 2008 16:55:15 PST</pubDate>
]PRE]
* 関連
[5] [[RSS]] の[[チャンネル要素]]としては他に [CODE(XMLe)@en[[[lastBuildDate]]]]
があります。
[6] [[Atom]] の似た[[要素]]として [CODE(XMLe)@en[[[published]]]]
や [CODE(XMLe)@en[[[updated]]]] があります。
[FIG(quote)[
[FIGCAPTION[
[21] ([TIME[2016-03-19 00:34:38 +09:00]] 版)
<http://blog.excite.co.jp/editorcafe/index.xml>
]FIGCAPTION]
>
> <pubDate>Sat, 12 Mar 2016 19:54:09 +0900</pubDate>
> <dc:date>2016-03-12T19:54:09+09:00</dc:date>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[22] ([TIME[2016-03-19 17:30:06 +09:00]] 版)
<http://finance.yahoo.com/rss/topfinstories>
]FIGCAPTION]
>
> <pubDate>Thu, 18 Feb 16 06:10:12 GMT</pubDate>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[23] ([TIME[2016-03-19 17:34:22 +09:00]] 版)
<http://xml.weather.yahoo.com/forecastrss?p=USCA1116&u=f>
]FIGCAPTION]
>
> <pubDate>Sat, 19 Mar 2016 12:56 am PDT</pubDate>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[24] ( ([TIME[2016-05-07 15:15:03 +09:00]]))
<https://daichkr.hatelabo.jp/antenna/960973446863607426/feed>
]FIGCAPTION]
> <pubDate>2016-05-07T05:30:00Z</pubDate>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[25] [CITE[RSS Feed for Macao SAR Official Gazette - National Laws / People's Central Government - Legislation]]
( ([TIME[2016-05-23 18:12:17 +09:00]]))
<http://en.io.gov.mo/RSS/bo/A/CatID/1000.aspx>
]FIGCAPTION]
> <pubDate>2009/12/20</pubDate>
]FIG]
[26] <http://www.kantei.go.jp/index-jnews.rdf>
[TIME[2018-04-24T17:07:37.500Z]]
> <pubDate>2018-04-13T10:31:00+09:00</pubDate>
[FIG(quote)[
[FIGCAPTION[
[27] ([TIME[2018-03-14 23:04:13 +09:00]])
<https://hojin-info.go.jp/hojin/common/data/HojinInfoRss.xml>
]FIGCAPTION]
> <pubDate>Wed Mar 14 23:04:13 JST 2018</pubDate>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[28] ([TIME[2018-04-28 00:00:18 +09:00]])
<http://www.sej.co.jp/rss/new_info.xml>
]FIGCAPTION]
> <pubDate>Sat, 28 Apr 2018 00:05:00 JST</pubDate>
]FIG]
[FIG(quote)[
[FIGCAPTION[
[29] ([TIME[2018-04-28 16:38:16 +09:00]])
<https://www.klchb.gov.tw/klchbw/Ct_Chronic/news/rss/rss.aspx>
]FIGCAPTION]
> <pubDate>2018/4/20 上午 09:34:01</pubDate>
]FIG]