contentful 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +1 -0
- data/ChangeLog.md +6 -0
- data/Gemfile +5 -0
- data/README.md +1 -0
- data/contentful.gemspec +1 -1
- data/lib/contentful/array.rb +1 -2
- data/lib/contentful/asset.rb +3 -3
- data/lib/contentful/client.rb +15 -18
- data/lib/contentful/content_type.rb +1 -1
- data/lib/contentful/dynamic_entry.rb +6 -6
- data/lib/contentful/entry.rb +1 -1
- data/lib/contentful/error.rb +3 -3
- data/lib/contentful/field.rb +1 -1
- data/lib/contentful/file.rb +1 -1
- data/lib/contentful/link.rb +2 -2
- data/lib/contentful/locale.rb +1 -1
- data/lib/contentful/location.rb +1 -1
- data/lib/contentful/resource.rb +10 -11
- data/lib/contentful/resource_builder.rb +63 -39
- data/lib/contentful/space.rb +1 -1
- data/lib/contentful/support.rb +5 -3
- data/lib/contentful/version.rb +1 -1
- data/spec/fixtures/json_responses/includes.json +111 -0
- data/spec/fixtures/json_responses/link_array.json +43 -0
- data/spec/resource_building_spec.rb +20 -0
- data/spec/spec_helper.rb +5 -1
- metadata +138 -192
- data/.README.md.swp +0 -0
- data/do_request.sh +0 -5
- data/doc/Contentful.html +0 -131
- data/doc/Contentful/AccessDenied.html +0 -158
- data/doc/Contentful/Array.html +0 -346
- data/doc/Contentful/Asset.html +0 -315
- data/doc/Contentful/BadRequest.html +0 -158
- data/doc/Contentful/Client.html +0 -1407
- data/doc/Contentful/ContentType.html +0 -183
- data/doc/Contentful/DynamicEntry.html +0 -333
- data/doc/Contentful/Entry.html +0 -198
- data/doc/Contentful/Error.html +0 -413
- data/doc/Contentful/Field.html +0 -161
- data/doc/Contentful/File.html +0 -160
- data/doc/Contentful/Link.html +0 -275
- data/doc/Contentful/Locale.html +0 -161
- data/doc/Contentful/NotFound.html +0 -158
- data/doc/Contentful/Request.html +0 -669
- data/doc/Contentful/Resource.html +0 -606
- data/doc/Contentful/Resource/AssetFields.html +0 -413
- data/doc/Contentful/Resource/AssetFields/ClassMethods.html +0 -174
- data/doc/Contentful/Resource/ClassMethods.html +0 -271
- data/doc/Contentful/Resource/Fields.html +0 -398
- data/doc/Contentful/Resource/Fields/ClassMethods.html +0 -187
- data/doc/Contentful/Resource/SystemProperties.html +0 -444
- data/doc/Contentful/Resource/SystemProperties/ClassMethods.html +0 -174
- data/doc/Contentful/ResourceBuilder.html +0 -1400
- data/doc/Contentful/Response.html +0 -546
- data/doc/Contentful/ServerError.html +0 -158
- data/doc/Contentful/Space.html +0 -183
- data/doc/Contentful/Support.html +0 -198
- data/doc/Contentful/Unauthorized.html +0 -158
- data/doc/Contentful/UnparsableJson.html +0 -158
- data/doc/Contentful/UnparsableResource.html +0 -158
- data/doc/_index.html +0 -410
- data/doc/class_list.html +0 -54
- data/doc/css/common.css +0 -1
- data/doc/css/full_list.css +0 -57
- data/doc/css/style.css +0 -338
- data/doc/file.README.html +0 -214
- data/doc/file_list.html +0 -56
- data/doc/frames.html +0 -26
- data/doc/index.html +0 -214
- data/doc/js/app.js +0 -219
- data/doc/js/full_list.js +0 -178
- data/doc/js/jquery.js +0 -4
- data/doc/method_list.html +0 -533
- data/doc/top-level-namespace.html +0 -112
data/.README.md.swp
DELETED
Binary file
|
data/do_request.sh
DELETED
@@ -1,5 +0,0 @@
|
|
1
|
-
#!/bin/bash
|
2
|
-
curl -v -X PUT https://api.contentful.com/spaces/4pc8kedrdxbj/content_types/announcements \
|
3
|
-
-H 'Content-Type: application/vnd.contentful.management.v1+json' \
|
4
|
-
-H 'Authorization: Bearer bc02f3f03b57cbe01518f131e7a75d0cc767f5874425a367205b93563a93d78b' \
|
5
|
-
-d '{"name":"Announcements","description": "Announcements are delivered as push notifications directly to users devices", "displayField": "message", "fields":[ {"name": "Message", "id": "message", "type": "Text", "required": true}, {"name": "Description", "id": "description", "type": "Text"}, {"name": "Originator", "id": "originator", "type": "Symbol", "validations": [{"in": ["PGMC", "Clinical Lead for Acute Medicine", "Communications Team"]}]}]}'
|
data/doc/Contentful.html
DELETED
@@ -1,131 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
-
<head>
|
5
|
-
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
-
<title>
|
7
|
-
Module: Contentful
|
8
|
-
|
9
|
-
— Documentation by YARD 0.8.7.3
|
10
|
-
|
11
|
-
</title>
|
12
|
-
|
13
|
-
<link rel="stylesheet" href="css/style.css" type="text/css" charset="utf-8" />
|
14
|
-
|
15
|
-
<link rel="stylesheet" href="css/common.css" type="text/css" charset="utf-8" />
|
16
|
-
|
17
|
-
<script type="text/javascript" charset="utf-8">
|
18
|
-
hasFrames = window.top.frames.main ? true : false;
|
19
|
-
relpath = '';
|
20
|
-
framesUrl = "frames.html#!" + escape(window.location.href);
|
21
|
-
</script>
|
22
|
-
|
23
|
-
|
24
|
-
<script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
|
25
|
-
|
26
|
-
<script type="text/javascript" charset="utf-8" src="js/app.js"></script>
|
27
|
-
|
28
|
-
|
29
|
-
</head>
|
30
|
-
<body>
|
31
|
-
<div id="header">
|
32
|
-
<div id="menu">
|
33
|
-
|
34
|
-
<a href="_index.html">Index (C)</a> »
|
35
|
-
|
36
|
-
|
37
|
-
<span class="title">Contentful</span>
|
38
|
-
|
39
|
-
|
40
|
-
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
41
|
-
</div>
|
42
|
-
|
43
|
-
<div id="search">
|
44
|
-
|
45
|
-
<a class="full_list_link" id="class_list_link"
|
46
|
-
href="class_list.html">
|
47
|
-
Class List
|
48
|
-
</a>
|
49
|
-
|
50
|
-
<a class="full_list_link" id="method_list_link"
|
51
|
-
href="method_list.html">
|
52
|
-
Method List
|
53
|
-
</a>
|
54
|
-
|
55
|
-
<a class="full_list_link" id="file_list_link"
|
56
|
-
href="file_list.html">
|
57
|
-
File List
|
58
|
-
</a>
|
59
|
-
|
60
|
-
</div>
|
61
|
-
<div class="clear"></div>
|
62
|
-
</div>
|
63
|
-
|
64
|
-
<iframe id="search_frame"></iframe>
|
65
|
-
|
66
|
-
<div id="content"><h1>Module: Contentful
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
</h1>
|
71
|
-
|
72
|
-
<dl class="box">
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
<dt class="r1 last">Defined in:</dt>
|
82
|
-
<dd class="r1 last">lib/contentful/link.rb<span class="defines">,<br />
|
83
|
-
lib/contentful/file.rb,<br /> lib/contentful/array.rb,<br /> lib/contentful/entry.rb,<br /> lib/contentful/asset.rb,<br /> lib/contentful/error.rb,<br /> lib/contentful/space.rb,<br /> lib/contentful/field.rb,<br /> lib/contentful/locale.rb,<br /> lib/contentful/client.rb,<br /> lib/contentful/request.rb,<br /> lib/contentful/version.rb,<br /> lib/contentful/support.rb,<br /> lib/contentful/response.rb,<br /> lib/contentful/resource.rb,<br /> lib/contentful/content_type.rb,<br /> lib/contentful/dynamic_entry.rb,<br /> lib/contentful/resource/fields.rb,<br /> lib/contentful/resource_builder.rb,<br /> lib/contentful/resource/asset_fields.rb,<br /> lib/contentful/resource/system_properties.rb</span>
|
84
|
-
</dd>
|
85
|
-
|
86
|
-
</dl>
|
87
|
-
<div class="clear"></div>
|
88
|
-
|
89
|
-
<h2>Defined Under Namespace</h2>
|
90
|
-
<p class="children">
|
91
|
-
|
92
|
-
|
93
|
-
<strong class="modules">Modules:</strong> <span class='object_link'><a href="Contentful/Resource.html" title="Contentful::Resource (module)">Resource</a></span>, <span class='object_link'><a href="Contentful/Support.html" title="Contentful::Support (module)">Support</a></span>
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Contentful/AccessDenied.html" title="Contentful::AccessDenied (class)">AccessDenied</a></span>, <span class='object_link'><a href="Contentful/Array.html" title="Contentful::Array (class)">Array</a></span>, <span class='object_link'><a href="Contentful/Asset.html" title="Contentful::Asset (class)">Asset</a></span>, <span class='object_link'><a href="Contentful/BadRequest.html" title="Contentful::BadRequest (class)">BadRequest</a></span>, <span class='object_link'><a href="Contentful/Client.html" title="Contentful::Client (class)">Client</a></span>, <span class='object_link'><a href="Contentful/ContentType.html" title="Contentful::ContentType (class)">ContentType</a></span>, <span class='object_link'><a href="Contentful/DynamicEntry.html" title="Contentful::DynamicEntry (class)">DynamicEntry</a></span>, <span class='object_link'><a href="Contentful/Entry.html" title="Contentful::Entry (class)">Entry</a></span>, <span class='object_link'><a href="Contentful/Error.html" title="Contentful::Error (class)">Error</a></span>, <span class='object_link'><a href="Contentful/Field.html" title="Contentful::Field (class)">Field</a></span>, <span class='object_link'><a href="Contentful/File.html" title="Contentful::File (class)">File</a></span>, <span class='object_link'><a href="Contentful/Link.html" title="Contentful::Link (class)">Link</a></span>, <span class='object_link'><a href="Contentful/Locale.html" title="Contentful::Locale (class)">Locale</a></span>, <span class='object_link'><a href="Contentful/NotFound.html" title="Contentful::NotFound (class)">NotFound</a></span>, <span class='object_link'><a href="Contentful/Request.html" title="Contentful::Request (class)">Request</a></span>, <span class='object_link'><a href="Contentful/ResourceBuilder.html" title="Contentful::ResourceBuilder (class)">ResourceBuilder</a></span>, <span class='object_link'><a href="Contentful/Response.html" title="Contentful::Response (class)">Response</a></span>, <span class='object_link'><a href="Contentful/ServerError.html" title="Contentful::ServerError (class)">ServerError</a></span>, <span class='object_link'><a href="Contentful/Space.html" title="Contentful::Space (class)">Space</a></span>, <span class='object_link'><a href="Contentful/Unauthorized.html" title="Contentful::Unauthorized (class)">Unauthorized</a></span>, <span class='object_link'><a href="Contentful/UnparsableJson.html" title="Contentful::UnparsableJson (class)">UnparsableJson</a></span>, <span class='object_link'><a href="Contentful/UnparsableResource.html" title="Contentful::UnparsableResource (class)">UnparsableResource</a></span>
|
98
|
-
|
99
|
-
|
100
|
-
</p>
|
101
|
-
|
102
|
-
<h2>Constant Summary</h2>
|
103
|
-
|
104
|
-
<dl class="constants">
|
105
|
-
|
106
|
-
<dt id="VERSION-constant" class="">VERSION =
|
107
|
-
|
108
|
-
</dt>
|
109
|
-
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0.1.0</span><span class='tstring_end'>"</span></span></pre></dd>
|
110
|
-
|
111
|
-
</dl>
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
</div>
|
123
|
-
|
124
|
-
<div id="footer">
|
125
|
-
Generated on Tue Mar 11 09:25:52 2014 by
|
126
|
-
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
127
|
-
0.8.7.3 (ruby-1.9.3).
|
128
|
-
</div>
|
129
|
-
|
130
|
-
</body>
|
131
|
-
</html>
|
@@ -1,158 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
-
<head>
|
5
|
-
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
-
<title>
|
7
|
-
Exception: Contentful::AccessDenied
|
8
|
-
|
9
|
-
— Documentation by YARD 0.8.7.3
|
10
|
-
|
11
|
-
</title>
|
12
|
-
|
13
|
-
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
14
|
-
|
15
|
-
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
16
|
-
|
17
|
-
<script type="text/javascript" charset="utf-8">
|
18
|
-
hasFrames = window.top.frames.main ? true : false;
|
19
|
-
relpath = '../';
|
20
|
-
framesUrl = "../frames.html#!" + escape(window.location.href);
|
21
|
-
</script>
|
22
|
-
|
23
|
-
|
24
|
-
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
25
|
-
|
26
|
-
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
27
|
-
|
28
|
-
|
29
|
-
</head>
|
30
|
-
<body>
|
31
|
-
<div id="header">
|
32
|
-
<div id="menu">
|
33
|
-
|
34
|
-
<a href="../_index.html">Index (A)</a> »
|
35
|
-
<span class='title'><span class='object_link'><a href="../Contentful.html" title="Contentful (module)">Contentful</a></span></span>
|
36
|
-
»
|
37
|
-
<span class="title">AccessDenied</span>
|
38
|
-
|
39
|
-
|
40
|
-
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
41
|
-
</div>
|
42
|
-
|
43
|
-
<div id="search">
|
44
|
-
|
45
|
-
<a class="full_list_link" id="class_list_link"
|
46
|
-
href="../class_list.html">
|
47
|
-
Class List
|
48
|
-
</a>
|
49
|
-
|
50
|
-
<a class="full_list_link" id="method_list_link"
|
51
|
-
href="../method_list.html">
|
52
|
-
Method List
|
53
|
-
</a>
|
54
|
-
|
55
|
-
<a class="full_list_link" id="file_list_link"
|
56
|
-
href="../file_list.html">
|
57
|
-
File List
|
58
|
-
</a>
|
59
|
-
|
60
|
-
</div>
|
61
|
-
<div class="clear"></div>
|
62
|
-
</div>
|
63
|
-
|
64
|
-
<iframe id="search_frame"></iframe>
|
65
|
-
|
66
|
-
<div id="content"><h1>Exception: Contentful::AccessDenied
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
</h1>
|
71
|
-
|
72
|
-
<dl class="box">
|
73
|
-
|
74
|
-
<dt class="r1">Inherits:</dt>
|
75
|
-
<dd class="r1">
|
76
|
-
<span class="inheritName"><span class='object_link'><a href="Error.html" title="Contentful::Error (class)">Error</a></span></span>
|
77
|
-
|
78
|
-
<ul class="fullTree">
|
79
|
-
<li>Object</li>
|
80
|
-
|
81
|
-
<li class="next">StandardError</li>
|
82
|
-
|
83
|
-
<li class="next"><span class='object_link'><a href="Error.html" title="Contentful::Error (class)">Error</a></span></li>
|
84
|
-
|
85
|
-
<li class="next">Contentful::AccessDenied</li>
|
86
|
-
|
87
|
-
</ul>
|
88
|
-
<a href="#" class="inheritanceTree">show all</a>
|
89
|
-
|
90
|
-
</dd>
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
<dt class="r2 last">Defined in:</dt>
|
101
|
-
<dd class="r2 last">lib/contentful/error.rb</dd>
|
102
|
-
|
103
|
-
</dl>
|
104
|
-
<div class="clear"></div>
|
105
|
-
|
106
|
-
<h2>Overview</h2><div class="docstring">
|
107
|
-
<div class="discussion">
|
108
|
-
|
109
|
-
<p>403</p>
|
110
|
-
|
111
|
-
|
112
|
-
</div>
|
113
|
-
</div>
|
114
|
-
<div class="tags">
|
115
|
-
|
116
|
-
|
117
|
-
</div>
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
<h2>Instance Attribute Summary</h2>
|
124
|
-
|
125
|
-
<h3 class="inherited">Attributes inherited from <span class='object_link'><a href="Error.html" title="Contentful::Error (class)">Error</a></span></h3>
|
126
|
-
<p class="inherited"><span class='object_link'><a href="Error.html#response-instance_method" title="Contentful::Error#response (method)">#response</a></span></p>
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
<h2>Method Summary</h2>
|
137
|
-
|
138
|
-
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="Error.html" title="Contentful::Error (class)">Error</a></span></h3>
|
139
|
-
<p class="inherited"><span class='object_link'><a href="Error.html#%5B%5D-class_method" title="Contentful::Error.[] (method)">[]</a></span>, <span class='object_link'><a href="Error.html#initialize-instance_method" title="Contentful::Error#initialize (method)">#initialize</a></span></p>
|
140
|
-
|
141
|
-
<div id="constructor_details" class="method_details_list">
|
142
|
-
<h2>Constructor Details</h2>
|
143
|
-
|
144
|
-
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="Error.html#initialize-instance_method" title="Contentful::Error#initialize (method)">Contentful::Error</a></span></p>
|
145
|
-
|
146
|
-
</div>
|
147
|
-
|
148
|
-
|
149
|
-
</div>
|
150
|
-
|
151
|
-
<div id="footer">
|
152
|
-
Generated on Tue Mar 11 09:25:52 2014 by
|
153
|
-
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
154
|
-
0.8.7.3 (ruby-1.9.3).
|
155
|
-
</div>
|
156
|
-
|
157
|
-
</body>
|
158
|
-
</html>
|
data/doc/Contentful/Array.html
DELETED
@@ -1,346 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
|
-
<head>
|
5
|
-
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
-
<title>
|
7
|
-
Class: Contentful::Array
|
8
|
-
|
9
|
-
— Documentation by YARD 0.8.7.3
|
10
|
-
|
11
|
-
</title>
|
12
|
-
|
13
|
-
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
14
|
-
|
15
|
-
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
16
|
-
|
17
|
-
<script type="text/javascript" charset="utf-8">
|
18
|
-
hasFrames = window.top.frames.main ? true : false;
|
19
|
-
relpath = '../';
|
20
|
-
framesUrl = "../frames.html#!" + escape(window.location.href);
|
21
|
-
</script>
|
22
|
-
|
23
|
-
|
24
|
-
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
25
|
-
|
26
|
-
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
27
|
-
|
28
|
-
|
29
|
-
</head>
|
30
|
-
<body>
|
31
|
-
<div id="header">
|
32
|
-
<div id="menu">
|
33
|
-
|
34
|
-
<a href="../_index.html">Index (A)</a> »
|
35
|
-
<span class='title'><span class='object_link'><a href="../Contentful.html" title="Contentful (module)">Contentful</a></span></span>
|
36
|
-
»
|
37
|
-
<span class="title">Array</span>
|
38
|
-
|
39
|
-
|
40
|
-
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
41
|
-
</div>
|
42
|
-
|
43
|
-
<div id="search">
|
44
|
-
|
45
|
-
<a class="full_list_link" id="class_list_link"
|
46
|
-
href="../class_list.html">
|
47
|
-
Class List
|
48
|
-
</a>
|
49
|
-
|
50
|
-
<a class="full_list_link" id="method_list_link"
|
51
|
-
href="../method_list.html">
|
52
|
-
Method List
|
53
|
-
</a>
|
54
|
-
|
55
|
-
<a class="full_list_link" id="file_list_link"
|
56
|
-
href="../file_list.html">
|
57
|
-
File List
|
58
|
-
</a>
|
59
|
-
|
60
|
-
</div>
|
61
|
-
<div class="clear"></div>
|
62
|
-
</div>
|
63
|
-
|
64
|
-
<iframe id="search_frame"></iframe>
|
65
|
-
|
66
|
-
<div id="content"><h1>Class: Contentful::Array
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
</h1>
|
71
|
-
|
72
|
-
<dl class="box">
|
73
|
-
|
74
|
-
<dt class="r1">Inherits:</dt>
|
75
|
-
<dd class="r1">
|
76
|
-
<span class="inheritName">Object</span>
|
77
|
-
|
78
|
-
<ul class="fullTree">
|
79
|
-
<li>Object</li>
|
80
|
-
|
81
|
-
<li class="next">Contentful::Array</li>
|
82
|
-
|
83
|
-
</ul>
|
84
|
-
<a href="#" class="inheritanceTree">show all</a>
|
85
|
-
|
86
|
-
</dd>
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
<dt class="r2">Includes:</dt>
|
94
|
-
<dd class="r2"><span class='object_link'><a href="Resource.html" title="Contentful::Resource (module)">Resource</a></span>, <span class='object_link'><a href="Resource/SystemProperties.html" title="Contentful::Resource::SystemProperties (module)">Resource::SystemProperties</a></span>, Enumerable</dd>
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
<dt class="r1 last">Defined in:</dt>
|
101
|
-
<dd class="r1 last">lib/contentful/array.rb</dd>
|
102
|
-
|
103
|
-
</dl>
|
104
|
-
<div class="clear"></div>
|
105
|
-
|
106
|
-
<h2>Overview</h2><div class="docstring">
|
107
|
-
<div class="discussion">
|
108
|
-
|
109
|
-
<p>Resource Class for Arrays (e.g. search results) <a
|
110
|
-
href="https://www.contentful.com/developers/documentation/content-delivery-api/#arrays">www.contentful.com/developers/documentation/content-delivery-api/#arrays</a>
|
111
|
-
It also provides an #each method and includes Ruby's Enumerable module
|
112
|
-
(gives you methods like #min, #first, etc)</p>
|
113
|
-
|
114
|
-
|
115
|
-
</div>
|
116
|
-
</div>
|
117
|
-
<div class="tags">
|
118
|
-
|
119
|
-
|
120
|
-
</div>
|
121
|
-
<h2>Constant Summary</h2>
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
<h2>Constant Summary</h2>
|
127
|
-
|
128
|
-
<h3 class="inherited">Constants included
|
129
|
-
from <span class='object_link'><a href="Resource/SystemProperties.html" title="Contentful::Resource::SystemProperties (module)">Resource::SystemProperties</a></span></h3>
|
130
|
-
<p class="inherited"><span class='object_link'><a href="Resource/SystemProperties.html#SYS_COERCIONS-constant" title="Contentful::Resource::SystemProperties::SYS_COERCIONS (constant)">Resource::SystemProperties::SYS_COERCIONS</a></span></p>
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
<h3 class="inherited">Constants included
|
135
|
-
from <span class='object_link'><a href="Resource.html" title="Contentful::Resource (module)">Resource</a></span></h3>
|
136
|
-
<p class="inherited"><span class='object_link'><a href="Resource.html#COERCIONS-constant" title="Contentful::Resource::COERCIONS (constant)">Resource::COERCIONS</a></span></p>
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
<h2>Instance Attribute Summary</h2>
|
142
|
-
|
143
|
-
<h3 class="inherited">Attributes included from <span class='object_link'><a href="Resource/SystemProperties.html" title="Contentful::Resource::SystemProperties (module)">Resource::SystemProperties</a></span></h3>
|
144
|
-
<p class="inherited"><span class='object_link'><a href="Resource/SystemProperties.html#sys-instance_method" title="Contentful::Resource::SystemProperties#sys (method)">#sys</a></span></p>
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
<h3 class="inherited">Attributes included from <span class='object_link'><a href="Resource.html" title="Contentful::Resource (module)">Resource</a></span></h3>
|
149
|
-
<p class="inherited"><span class='object_link'><a href="Resource.html#client-instance_method" title="Contentful::Resource#client (method)">#client</a></span>, <span class='object_link'><a href="Resource.html#properties-instance_method" title="Contentful::Resource#properties (method)">#properties</a></span></p>
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
<h2>
|
154
|
-
Instance Method Summary
|
155
|
-
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
|
156
|
-
</h2>
|
157
|
-
|
158
|
-
<ul class="summary">
|
159
|
-
|
160
|
-
<li class="public ">
|
161
|
-
<span class="summary_signature">
|
162
|
-
|
163
|
-
<a href="#array%3F-instance_method" title="#array? (instance method)">- (Boolean) <strong>array?</strong> </a>
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
</span>
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
<span class="summary_desc"><div class='inline'>
|
178
|
-
<p>Only returns true for Contentful::Array.</p>
|
179
|
-
</div></span>
|
180
|
-
|
181
|
-
</li>
|
182
|
-
|
183
|
-
|
184
|
-
<li class="public ">
|
185
|
-
<span class="summary_signature">
|
186
|
-
|
187
|
-
<a href="#each-instance_method" title="#each (instance method)">- (Object) <strong>each</strong>(&block) </a>
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
</span>
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
<span class="summary_desc"><div class='inline'>
|
202
|
-
<p>Delegates to items#each.</p>
|
203
|
-
</div></span>
|
204
|
-
|
205
|
-
</li>
|
206
|
-
|
207
|
-
|
208
|
-
</ul>
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
<h3 class="inherited">Methods included from <span class='object_link'><a href="Resource/SystemProperties.html" title="Contentful::Resource::SystemProperties (module)">Resource::SystemProperties</a></span></h3>
|
222
|
-
<p class="inherited"><span class='object_link'><a href="Resource/SystemProperties.html#included-class_method" title="Contentful::Resource::SystemProperties.included (method)">included</a></span>, <span class='object_link'><a href="Resource/SystemProperties.html#initialize-instance_method" title="Contentful::Resource::SystemProperties#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="Resource/SystemProperties.html#inspect-instance_method" title="Contentful::Resource::SystemProperties#inspect (method)">#inspect</a></span></p>
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
<h3 class="inherited">Methods included from <span class='object_link'><a href="Resource.html" title="Contentful::Resource (module)">Resource</a></span></h3>
|
233
|
-
<p class="inherited"><span class='object_link'><a href="Resource.html#fields-instance_method" title="Contentful::Resource#fields (method)">#fields</a></span>, <span class='object_link'><a href="Resource.html#initialize-instance_method" title="Contentful::Resource#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="Resource.html#inspect-instance_method" title="Contentful::Resource#inspect (method)">#inspect</a></span>, <span class='object_link'><a href="Resource.html#sys-instance_method" title="Contentful::Resource#sys (method)">#sys</a></span></p>
|
234
|
-
|
235
|
-
|
236
|
-
<div id="instance_method_details" class="method_details_list">
|
237
|
-
<h2>Instance Method Details</h2>
|
238
|
-
|
239
|
-
|
240
|
-
<div class="method_details first">
|
241
|
-
<h3 class="signature first" id="array?-instance_method">
|
242
|
-
|
243
|
-
- (<tt>Boolean</tt>) <strong>array?</strong>
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
</h3><div class="docstring">
|
250
|
-
<div class="discussion">
|
251
|
-
|
252
|
-
<p>Only returns true for Contentful::Array</p>
|
253
|
-
|
254
|
-
|
255
|
-
</div>
|
256
|
-
</div>
|
257
|
-
<div class="tags">
|
258
|
-
|
259
|
-
<p class="tag_title">Returns:</p>
|
260
|
-
<ul class="return">
|
261
|
-
|
262
|
-
<li>
|
263
|
-
|
264
|
-
|
265
|
-
<span class='type'>(<tt>Boolean</tt>)</span>
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
</li>
|
270
|
-
|
271
|
-
</ul>
|
272
|
-
|
273
|
-
</div><table class="source_code">
|
274
|
-
<tr>
|
275
|
-
<td>
|
276
|
-
<pre class="lines">
|
277
|
-
|
278
|
-
|
279
|
-
18
|
280
|
-
19
|
281
|
-
20</pre>
|
282
|
-
</td>
|
283
|
-
<td>
|
284
|
-
<pre class="code"><span class="info file"># File 'lib/contentful/array.rb', line 18</span>
|
285
|
-
|
286
|
-
<span class='kw'>def</span> <span class='id identifier rubyid_array?'>array?</span>
|
287
|
-
<span class='kw'>true</span>
|
288
|
-
<span class='kw'>end</span></pre>
|
289
|
-
</td>
|
290
|
-
</tr>
|
291
|
-
</table>
|
292
|
-
</div>
|
293
|
-
|
294
|
-
<div class="method_details ">
|
295
|
-
<h3 class="signature " id="each-instance_method">
|
296
|
-
|
297
|
-
- (<tt>Object</tt>) <strong>each</strong>(&block)
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
</h3><div class="docstring">
|
304
|
-
<div class="discussion">
|
305
|
-
|
306
|
-
<p>Delegates to items#each</p>
|
307
|
-
|
308
|
-
|
309
|
-
</div>
|
310
|
-
</div>
|
311
|
-
<div class="tags">
|
312
|
-
|
313
|
-
|
314
|
-
</div><table class="source_code">
|
315
|
-
<tr>
|
316
|
-
<td>
|
317
|
-
<pre class="lines">
|
318
|
-
|
319
|
-
|
320
|
-
23
|
321
|
-
24
|
322
|
-
25</pre>
|
323
|
-
</td>
|
324
|
-
<td>
|
325
|
-
<pre class="code"><span class="info file"># File 'lib/contentful/array.rb', line 23</span>
|
326
|
-
|
327
|
-
<span class='kw'>def</span> <span class='id identifier rubyid_each'>each</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
328
|
-
<span class='id identifier rubyid_items'>items</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
329
|
-
<span class='kw'>end</span></pre>
|
330
|
-
</td>
|
331
|
-
</tr>
|
332
|
-
</table>
|
333
|
-
</div>
|
334
|
-
|
335
|
-
</div>
|
336
|
-
|
337
|
-
</div>
|
338
|
-
|
339
|
-
<div id="footer">
|
340
|
-
Generated on Tue Mar 11 09:25:52 2014 by
|
341
|
-
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
342
|
-
0.8.7.3 (ruby-1.9.3).
|
343
|
-
</div>
|
344
|
-
|
345
|
-
</body>
|
346
|
-
</html>
|