Module: Clouder
- Defined in:
- lib/clouder.rb,
lib/clouder/entity.rb
Overview
The Clouder module holds global server-wide functions.
Defined Under Namespace
Classes: Entity
Constant Summary collapse
- VERSION =
'0.5.3'
Class Method Summary collapse
-
.collections(uri) ⇒ Object
Returns an array of URIs of the resources exposed by the CloudKit server at the
uri
. -
.head(uri) ⇒ Object
Makes a HEAD request to the
uri
and returns a hash of headers contained in the response.
Class Method Details
.collections(uri) ⇒ Object
Returns an array of URIs of the resources exposed by the CloudKit server at the uri
.
Clouder.collection("http://localhost:9292")
=> [ "notes", "comments" ]
19 20 21 22 |
# File 'lib/clouder.rb', line 19 def Clouder.collections(uri) uris = Rest.get(File.join(uri, "cloudkit-meta"))["uris"] uris.map { |uri| uri.split("/").last } end |