[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

[webdav-jp:1085] Re: PUT メソッドでのコレクション上書き



岩田です。

On Sat, 9 Oct 2004 18:06:19 +0900 you wrote:

> ・PUT自体は、リクエストを構成する内容に「リソースの種類」などの属性は持たな
> い
> ・リクエストを受け取った側は、対象となるURIに対応するものが存在する場合は、
> リクエストがどのようなリソース(リソースなのかコレクションなのか)に対するも
> のかを判断する
> ・既存のものが「リソース」であれば、8.7.1 に示すとおり
> ・既存のものが「リソース」でなければ、8.7.2 に示すとおり

RFC の該当部分

  8.7.1 PUT for Non-Collection Resources
  8.7.2 PUT for Collections

宮本さんは上記をそれぞれ

  8.7.1 非コレクション・リソースに対する PUT
  8.7.2 コレクションに対する PUT

と解釈されているようですが、内容的には

  8.7.1 非コレクション・リソースを PUT する場合
  8.7.2 コレクションを PUT する場合

ではないでしょうか?

8.7.2 には次のように「コレクションを PUT する方法はここに規定しない。
PUT じゃなく MKCOL を使ってちょうだい」と書かれています。

As defined in the HTTP/1.1 specification [RFC2068], the "PUT method
requests that the enclosed entity be stored under the supplied
Request-URI." Since submission of an entity representing a collection
would implicitly encode creation and deletion of resources, this
specification intentionally does not define a transmission format for
creating a collection using PUT. Instead, the MKCOL method is defined
to create collections.

これを「コレクションに対する PUT」として読むと意味が通じないですよね。