Class: Calligraphy::Mkcol
- Inherits:
-
WebDavRequest
- Object
- WebDavRequest
- Calligraphy::Mkcol
- Defined in:
- lib/calligraphy/mkcol.rb
Instance Attribute Summary
Attributes inherited from WebDavRequest
#headers, #resource, #response
Instance Method Summary collapse
Methods inherited from WebDavRequest
Constructor Details
This class inherits a constructor from Calligraphy::WebDavRequest
Instance Method Details
#request ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/calligraphy/mkcol.rb', line 3 def request return :method_not_allowed if @resource.exists? return :conflict unless @resource.ancestor_exist? return :unsupported_media_type unless @resource.request_body.blank? @resource.create_collection set_content_location_header return :created end |