/
868.txt
70 lines (54 loc) · 3.02 KB
/
868.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
[1] [DFN[[CODE(HTTP)@en[[[BREW]]]]]] は、[[珈琲ポット]]を制御する命令を送信することを表す[[要求メソッド]]です。
* 仕様書
[REFS[
- [2] [CITE@en[RFC 2324 - Hyper Text Coffee Pot Control Protocol (HTCPCP/1.0)]] ([TIME[2014-10-06 15:21:16 +09:00]] 版) <http://tools.ietf.org/html/rfc2324#section-2.1.1>
- [4] [CITE@en[RFC 7168 - The Hyper Text Coffee Pot Control Protocol for Tea Efflux Appliances (HTCPCP-TEA)]]
( ([TIME[2014-04-02 07:55:01 +09:00]] 版))
<http://tools.ietf.org/html/rfc7168#section-2.1>
]REFS]
* 意味
[3] [[HTCPCP]] においては [CODE(HTTP)@en[[[BREW]]]] は [CODE(HTTP)@en[[[POST]]]]
と等価ですが、「post」は[[珈琲]]の[[商標]]であるため [SRC[>>2]]、代替として追加されました。
* 構文
[5] [CODE(HTTP)@en[[[BREW]]]]/[CODE(HTTP)@en[[[POST]]]] [[要求]]の [[payload body]]
には、 [CODE(MIME)@en[[[application/coffee-pot-command]]]] を使います [SRC[>>2]]。
* 処理モデル
[6] [[HTCPCP]] [[珈琲ポット]][[鯖]]は、 [CODE(HTTP)@en[[[POST]]]] と
[CODE(HTTP)@en[[[BREW]]]] を等価として扱わなければ[['''なりません''']] [SRC[>>2]]。
* 歴史
[FIG(quote)[
[FIGCAPTION[
[7] RFC 2324 (HTCPCP/1.0) 2.1.1 The BREW method, and the use of POST
]FIGCAPTION]
> Commands to control a coffee pot are sent from client to coffee
server using either the BREW or POST method, and a message body with
Content-Type set to "application/coffee-pot-command".
珈琲ポットを制御する命令は、
クライアントから珈琲鯖に
[CODE(HTTP)[BREW]] method 又は
[CODE(HTTP)[[[POST]]]] method を使って、
メッセージ本体の [CODE(HTTP)[[[Content-Type]]]]
を [CODE(MIME)[[[application/coffee-pot-command]]]]
に設定して送信します。
> A coffee pot server MUST accept both the BREW and POST method
equivalently. However, the use of POST for causing actions to happen
is deprecated.
珈琲ポット鯖は、 [CODE(HTTP)[BREW]]
method も [CODE(HTTP)[POST]] method も同等に受け入れなければ'''なりません'''。
しかし、行動を起こす時に [CODE(HTTP)[POST]]
を使用することは非推奨です。
> Coffee pots heat water using electronic mechanisms, so there is no
fire. Thus, no firewalls are necessary, and firewall control policy
is irrelevant. However, POST may be a trademark for coffee, and so
the BREW method has been added. The BREW method may be used with
other HTTP-based protocols (e.g., the Hyper Text Brewery Control
Protocol).
珈琲ポットは電子的機構を使って水を熱するので、
火は使いません。従って、[[防火壁]]は不要であり、
防火壁制御方針も無関係です。しかし、
[CODE(HTTP)[POST]] は珈琲に関しては商標かもしれないので、
[CODE(HTTP)[BREW]] method が追加されました。
[CODE(HTTP)[BREW]] method は他の HTTP
を基にしたプロトコル (例えばハイパーテキスト醸造制御プロトコル)
でも使われるかもしれません。
]FIG]