inquery 1.0.0 → 1.0.5
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 +5 -5
- data/CHANGELOG.md +30 -0
- data/LICENSE +2 -2
- data/README.md +35 -2
- data/RUBY_VERSION +1 -1
- data/Rakefile +2 -2
- data/VERSION +1 -1
- data/doc/Inquery.html +7 -7
- data/doc/Inquery/Exceptions.html +6 -6
- data/doc/Inquery/Exceptions/Base.html +6 -6
- data/doc/Inquery/Exceptions/InvalidRelation.html +6 -6
- data/doc/Inquery/Exceptions/UnknownCallSignature.html +6 -6
- data/doc/Inquery/Mixins.html +9 -9
- data/doc/Inquery/Mixins/RawSqlUtils.html +116 -0
- data/doc/Inquery/Mixins/RelationValidation.html +37 -31
- data/doc/Inquery/Mixins/RelationValidation/ClassMethods.html +11 -11
- data/doc/Inquery/Mixins/SchemaValidation.html +6 -6
- data/doc/Inquery/Mixins/SchemaValidation/ClassMethods.html +136 -12
- data/doc/Inquery/Query.html +105 -34
- data/doc/Inquery/Query/Chainable.html +78 -8
- data/doc/_index.html +18 -11
- data/doc/class_list.html +3 -3
- data/doc/css/style.css +12 -8
- data/doc/file.README.html +54 -22
- data/doc/file_list.html +2 -2
- data/doc/frames.html +2 -2
- data/doc/index.html +54 -22
- data/doc/js/app.js +69 -3
- data/doc/method_list.html +42 -10
- data/doc/top-level-namespace.html +6 -6
- data/inquery.gemspec +11 -11
- data/lib/inquery.rb +1 -0
- data/lib/inquery/mixins/raw_sql_utils.rb +23 -0
- data/lib/inquery/mixins/relation_validation.rb +14 -5
- data/lib/inquery/mixins/schema_validation.rb +14 -3
- data/lib/inquery/query.rb +9 -2
- data/lib/inquery/query/chainable.rb +5 -0
- metadata +20 -18
@@ -6,15 +6,15 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Inquery::Mixins::RelationValidation
|
8
8
|
|
9
|
-
— Documentation by YARD 0.9.
|
9
|
+
— Documentation by YARD 0.9.25
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
13
|
-
<link rel="stylesheet" href="../../css/style.css" type="text/css"
|
13
|
+
<link rel="stylesheet" href="../../css/style.css" type="text/css" />
|
14
14
|
|
15
|
-
<link rel="stylesheet" href="../../css/common.css" type="text/css"
|
15
|
+
<link rel="stylesheet" href="../../css/common.css" type="text/css" />
|
16
16
|
|
17
|
-
<script type="text/javascript"
|
17
|
+
<script type="text/javascript">
|
18
18
|
pathId = "Inquery::Mixins::RelationValidation";
|
19
19
|
relpath = '../../';
|
20
20
|
</script>
|
@@ -104,23 +104,28 @@
|
|
104
104
|
|
105
105
|
</p>
|
106
106
|
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
<
|
111
|
-
|
112
|
-
|
113
|
-
|
107
|
+
|
108
|
+
<h2>
|
109
|
+
Constant Summary
|
110
|
+
<small><a href="#" class="constants_summary_toggle">collapse</a></small>
|
111
|
+
</h2>
|
112
|
+
|
113
|
+
<dl class="constants">
|
114
|
+
|
115
|
+
<dt id="OPTIONS_SCHEMA-constant" class="">OPTIONS_SCHEMA =
|
116
|
+
|
117
|
+
</dt>
|
118
|
+
<dd><pre class="code"><span class='const'>Schemacop</span><span class='op'>::</span><span class='const'>Schema</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span> <span class='kw'>do</span>
|
114
119
|
<span class='id identifier rubyid_opt'>opt</span> <span class='symbol'>:class</span><span class='comma'>,</span> <span class='symbol'>:string</span>
|
115
120
|
<span class='id identifier rubyid_opt'>opt</span> <span class='symbol'>:fields</span><span class='comma'>,</span> <span class='symbol'>:integer</span>
|
116
121
|
<span class='id identifier rubyid_opt'>opt</span> <span class='symbol'>:default_select</span><span class='comma'>,</span> <span class='symbol'>:symbol</span>
|
117
122
|
<span class='id identifier rubyid_opt'>opt</span> <span class='symbol'>:default</span><span class='comma'>,</span> <span class='symbol'>:object</span><span class='comma'>,</span> <span class='label'>classes:</span> <span class='lbracket'>[</span><span class='const'>Proc</span><span class='comma'>,</span> <span class='const'>FalseClass</span><span class='rbracket'>]</span>
|
118
123
|
<span class='kw'>end</span></pre></dd>
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
+
|
125
|
+
<dt id="DEFAULT_OPTIONS-constant" class="">DEFAULT_OPTIONS =
|
126
|
+
|
127
|
+
</dt>
|
128
|
+
<dd><pre class="code"><span class='lbrace'>{</span>
|
124
129
|
<span class='comment'># Allows to restrict the class (attribute `klass`) of the relation. Use
|
125
130
|
</span> <span class='comment'># `nil` to not perform any checks. The `class` attribute will also be
|
126
131
|
</span> <span class='comment'># taken to infer a default if no relation is given and you didn't
|
@@ -145,8 +150,9 @@
|
|
145
150
|
</span> <span class='comment'># behavior.
|
146
151
|
</span> <span class='label'>default_select:</span> <span class='symbol'>:id</span>
|
147
152
|
<span class='rbrace'>}</span></pre></dd>
|
148
|
-
|
149
|
-
|
153
|
+
|
154
|
+
</dl>
|
155
|
+
|
150
156
|
|
151
157
|
|
152
158
|
|
@@ -221,15 +227,6 @@ options specified at class level using the <code>relation</code> method.</p>
|
|
221
227
|
<pre class="lines">
|
222
228
|
|
223
229
|
|
224
|
-
54
|
225
|
-
55
|
226
|
-
56
|
227
|
-
57
|
228
|
-
58
|
229
|
-
59
|
230
|
-
60
|
231
|
-
61
|
232
|
-
62
|
233
230
|
63
|
234
231
|
64
|
235
232
|
65
|
@@ -262,10 +259,19 @@ options specified at class level using the <code>relation</code> method.</p>
|
|
262
259
|
92
|
263
260
|
93
|
264
261
|
94
|
265
|
-
95
|
262
|
+
95
|
263
|
+
96
|
264
|
+
97
|
265
|
+
98
|
266
|
+
99
|
267
|
+
100
|
268
|
+
101
|
269
|
+
102
|
270
|
+
103
|
271
|
+
104</pre>
|
266
272
|
</td>
|
267
273
|
<td>
|
268
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/relation_validation.rb', line
|
274
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/relation_validation.rb', line 63</span>
|
269
275
|
|
270
276
|
<span class='kw'>def</span> <span class='id identifier rubyid_validate_relation!'>validate_relation!</span><span class='lparen'>(</span><span class='id identifier rubyid_relation'>relation</span><span class='rparen'>)</span>
|
271
277
|
<span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="#DEFAULT_OPTIONS-constant" title="Inquery::Mixins::RelationValidation::DEFAULT_OPTIONS (constant)">DEFAULT_OPTIONS</a></span></span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
|
@@ -319,9 +325,9 @@ options specified at class level using the <code>relation</code> method.</p>
|
|
319
325
|
</div>
|
320
326
|
|
321
327
|
<div id="footer">
|
322
|
-
Generated on
|
328
|
+
Generated on Wed Nov 25 13:57:22 2020 by
|
323
329
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
324
|
-
0.9.
|
330
|
+
0.9.25 (ruby-2.6.2).
|
325
331
|
</div>
|
326
332
|
|
327
333
|
</div>
|
@@ -6,15 +6,15 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Inquery::Mixins::RelationValidation::ClassMethods
|
8
8
|
|
9
|
-
— Documentation by YARD 0.9.
|
9
|
+
— Documentation by YARD 0.9.25
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
13
|
-
<link rel="stylesheet" href="../../../css/style.css" type="text/css"
|
13
|
+
<link rel="stylesheet" href="../../../css/style.css" type="text/css" />
|
14
14
|
|
15
|
-
<link rel="stylesheet" href="../../../css/common.css" type="text/css"
|
15
|
+
<link rel="stylesheet" href="../../../css/common.css" type="text/css" />
|
16
16
|
|
17
|
-
<script type="text/javascript"
|
17
|
+
<script type="text/javascript">
|
18
18
|
pathId = "Inquery::Mixins::RelationValidation::ClassMethods";
|
19
19
|
relpath = '../../../';
|
20
20
|
</script>
|
@@ -156,13 +156,13 @@ on. See <span class='object_link'><a href="../RelationValidation.html#OPTIONS_SC
|
|
156
156
|
<pre class="lines">
|
157
157
|
|
158
158
|
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
159
|
+
55
|
160
|
+
56
|
161
|
+
57
|
162
|
+
58</pre>
|
163
163
|
</td>
|
164
164
|
<td>
|
165
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/relation_validation.rb', line
|
165
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/relation_validation.rb', line 55</span>
|
166
166
|
|
167
167
|
<span class='kw'>def</span> <span class='id identifier rubyid_relation'>relation</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
|
168
168
|
<span class='const'><span class='object_link'><a href="../RelationValidation.html#OPTIONS_SCHEMA-constant" title="Inquery::Mixins::RelationValidation::OPTIONS_SCHEMA (constant)">OPTIONS_SCHEMA</a></span></span><span class='period'>.</span><span class='id identifier rubyid_validate!'>validate!</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
|
@@ -178,9 +178,9 @@ on. See <span class='object_link'><a href="../RelationValidation.html#OPTIONS_SC
|
|
178
178
|
</div>
|
179
179
|
|
180
180
|
<div id="footer">
|
181
|
-
Generated on
|
181
|
+
Generated on Wed Nov 25 13:57:22 2020 by
|
182
182
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
183
|
-
0.9.
|
183
|
+
0.9.25 (ruby-2.6.2).
|
184
184
|
</div>
|
185
185
|
|
186
186
|
</div>
|
@@ -6,15 +6,15 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Inquery::Mixins::SchemaValidation
|
8
8
|
|
9
|
-
— Documentation by YARD 0.9.
|
9
|
+
— Documentation by YARD 0.9.25
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
13
|
-
<link rel="stylesheet" href="../../css/style.css" type="text/css"
|
13
|
+
<link rel="stylesheet" href="../../css/style.css" type="text/css" />
|
14
14
|
|
15
|
-
<link rel="stylesheet" href="../../css/common.css" type="text/css"
|
15
|
+
<link rel="stylesheet" href="../../css/common.css" type="text/css" />
|
16
16
|
|
17
|
-
<script type="text/javascript"
|
17
|
+
<script type="text/javascript">
|
18
18
|
pathId = "Inquery::Mixins::SchemaValidation";
|
19
19
|
relpath = '../../';
|
20
20
|
</script>
|
@@ -116,9 +116,9 @@
|
|
116
116
|
</div>
|
117
117
|
|
118
118
|
<div id="footer">
|
119
|
-
Generated on
|
119
|
+
Generated on Wed Nov 25 13:57:22 2020 by
|
120
120
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
121
|
-
0.9.
|
121
|
+
0.9.25 (ruby-2.6.2).
|
122
122
|
</div>
|
123
123
|
|
124
124
|
</div>
|
@@ -6,15 +6,15 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Inquery::Mixins::SchemaValidation::ClassMethods
|
8
8
|
|
9
|
-
— Documentation by YARD 0.9.
|
9
|
+
— Documentation by YARD 0.9.25
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
13
|
-
<link rel="stylesheet" href="../../../css/style.css" type="text/css"
|
13
|
+
<link rel="stylesheet" href="../../../css/style.css" type="text/css" />
|
14
14
|
|
15
|
-
<link rel="stylesheet" href="../../../css/common.css" type="text/css"
|
15
|
+
<link rel="stylesheet" href="../../../css/common.css" type="text/css" />
|
16
16
|
|
17
|
-
<script type="text/javascript"
|
17
|
+
<script type="text/javascript">
|
18
18
|
pathId = "Inquery::Mixins::SchemaValidation::ClassMethods";
|
19
19
|
relpath = '../../../';
|
20
20
|
</script>
|
@@ -115,6 +115,50 @@
|
|
115
115
|
|
116
116
|
|
117
117
|
|
118
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
119
|
+
|
120
|
+
</li>
|
121
|
+
|
122
|
+
|
123
|
+
<li class="public ">
|
124
|
+
<span class="summary_signature">
|
125
|
+
|
126
|
+
<a href="#schema2-instance_method" title="#schema2 (instance method)">#<strong>schema2</strong>(*args, &block) ⇒ Object </a>
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
</span>
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
141
|
+
|
142
|
+
</li>
|
143
|
+
|
144
|
+
|
145
|
+
<li class="public ">
|
146
|
+
<span class="summary_signature">
|
147
|
+
|
148
|
+
<a href="#schema3-instance_method" title="#schema3 (instance method)">#<strong>schema3</strong>(reference = nil, **options, &block) ⇒ Object </a>
|
149
|
+
|
150
|
+
|
151
|
+
|
152
|
+
</span>
|
153
|
+
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
118
162
|
<span class="summary_desc"><div class='inline'></div></span>
|
119
163
|
|
120
164
|
</li>
|
@@ -138,6 +182,52 @@
|
|
138
182
|
|
139
183
|
|
140
184
|
|
185
|
+
</h3><div class="docstring">
|
186
|
+
<div class="discussion">
|
187
|
+
|
188
|
+
|
189
|
+
</div>
|
190
|
+
</div>
|
191
|
+
<div class="tags">
|
192
|
+
|
193
|
+
|
194
|
+
<p class="tag_title">See Also:</p>
|
195
|
+
<ul class="see">
|
196
|
+
|
197
|
+
<li><span class='object_link'><a href="#schema2-instance_method" title="Inquery::Mixins::SchemaValidation::ClassMethods#schema2 (method)">#schema2</a></span></li>
|
198
|
+
|
199
|
+
</ul>
|
200
|
+
|
201
|
+
</div><table class="source_code">
|
202
|
+
<tr>
|
203
|
+
<td>
|
204
|
+
<pre class="lines">
|
205
|
+
|
206
|
+
|
207
|
+
25
|
208
|
+
26
|
209
|
+
27</pre>
|
210
|
+
</td>
|
211
|
+
<td>
|
212
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/schema_validation.rb', line 25</span>
|
213
|
+
|
214
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_schema'>schema</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
215
|
+
<span class='id identifier rubyid_schema2'>schema2</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
216
|
+
<span class='kw'>end</span></pre>
|
217
|
+
</td>
|
218
|
+
</tr>
|
219
|
+
</table>
|
220
|
+
</div>
|
221
|
+
|
222
|
+
<div class="method_details ">
|
223
|
+
<h3 class="signature " id="schema2-instance_method">
|
224
|
+
|
225
|
+
#<strong>schema2</strong>(*args, &block) ⇒ <tt>Object</tt>
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
|
230
|
+
|
141
231
|
</h3><table class="source_code">
|
142
232
|
<tr>
|
143
233
|
<td>
|
@@ -146,17 +236,51 @@
|
|
146
236
|
|
147
237
|
12
|
148
238
|
13
|
149
|
-
14
|
150
|
-
15
|
151
|
-
16</pre>
|
239
|
+
14</pre>
|
152
240
|
</td>
|
153
241
|
<td>
|
154
242
|
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/schema_validation.rb', line 12</span>
|
155
243
|
|
156
|
-
<span class='kw'>def</span> <span class='id identifier
|
157
|
-
<span class='id identifier
|
244
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_schema2'>schema2</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
245
|
+
<span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__schema'>_schema</span> <span class='op'>=</span> <span class='const'>Schemacop</span><span class='op'>::</span><span class='const'>Schema</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
246
|
+
<span class='kw'>end</span></pre>
|
247
|
+
</td>
|
248
|
+
</tr>
|
249
|
+
</table>
|
250
|
+
</div>
|
251
|
+
|
252
|
+
<div class="method_details ">
|
253
|
+
<h3 class="signature " id="schema3-instance_method">
|
254
|
+
|
255
|
+
#<strong>schema3</strong>(reference = nil, **options, &block) ⇒ <tt>Object</tt>
|
256
|
+
|
158
257
|
|
159
|
-
|
258
|
+
|
259
|
+
|
260
|
+
|
261
|
+
</h3><table class="source_code">
|
262
|
+
<tr>
|
263
|
+
<td>
|
264
|
+
<pre class="lines">
|
265
|
+
|
266
|
+
|
267
|
+
16
|
268
|
+
17
|
269
|
+
18
|
270
|
+
19
|
271
|
+
20
|
272
|
+
21
|
273
|
+
22</pre>
|
274
|
+
</td>
|
275
|
+
<td>
|
276
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/mixins/schema_validation.rb', line 16</span>
|
277
|
+
|
278
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_schema3'>schema3</span><span class='lparen'>(</span><span class='id identifier rubyid_reference'>reference</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_options'>options</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
279
|
+
<span class='kw'>if</span> <span class='id identifier rubyid_reference'>reference</span>
|
280
|
+
<span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__schema'>_schema</span> <span class='op'>=</span> <span class='const'>Schemacop</span><span class='op'>::</span><span class='const'>Schema3</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='symbol'>:reference</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_merge'>merge</span><span class='lparen'>(</span><span class='label'>path:</span> <span class='id identifier rubyid_reference'>reference</span><span class='rparen'>)</span><span class='rparen'>)</span>
|
281
|
+
<span class='kw'>else</span>
|
282
|
+
<span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid__schema'>_schema</span> <span class='op'>=</span> <span class='const'>Schemacop</span><span class='op'>::</span><span class='const'>Schema3</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='symbol'>:hash</span><span class='comma'>,</span> <span class='op'>**</span><span class='id identifier rubyid_options'>options</span><span class='comma'>,</span> <span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
283
|
+
<span class='kw'>end</span>
|
160
284
|
<span class='kw'>end</span></pre>
|
161
285
|
</td>
|
162
286
|
</tr>
|
@@ -168,9 +292,9 @@
|
|
168
292
|
</div>
|
169
293
|
|
170
294
|
<div id="footer">
|
171
|
-
Generated on
|
295
|
+
Generated on Wed Nov 25 13:57:22 2020 by
|
172
296
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
173
|
-
0.9.
|
297
|
+
0.9.25 (ruby-2.6.2).
|
174
298
|
</div>
|
175
299
|
|
176
300
|
</div>
|
data/doc/Inquery/Query.html
CHANGED
@@ -6,15 +6,15 @@
|
|
6
6
|
<title>
|
7
7
|
Class: Inquery::Query
|
8
8
|
|
9
|
-
— Documentation by YARD 0.9.
|
9
|
+
— Documentation by YARD 0.9.25
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
13
|
-
<link rel="stylesheet" href="../css/style.css" type="text/css"
|
13
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" />
|
14
14
|
|
15
|
-
<link rel="stylesheet" href="../css/common.css" type="text/css"
|
15
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" />
|
16
16
|
|
17
|
-
<script type="text/javascript"
|
17
|
+
<script type="text/javascript">
|
18
18
|
pathId = "Inquery::Query";
|
19
19
|
relpath = '../';
|
20
20
|
</script>
|
@@ -89,7 +89,7 @@
|
|
89
89
|
|
90
90
|
<dl>
|
91
91
|
<dt>Includes:</dt>
|
92
|
-
<dd><span class='object_link'><a href="Mixins/SchemaValidation.html" title="Inquery::Mixins::SchemaValidation (module)">Mixins::SchemaValidation</a></span></dd>
|
92
|
+
<dd><span class='object_link'><a href="Mixins/RawSqlUtils.html" title="Inquery::Mixins::RawSqlUtils (module)">Mixins::RawSqlUtils</a></span>, <span class='object_link'><a href="Mixins/SchemaValidation.html" title="Inquery::Mixins::SchemaValidation (module)">Mixins::SchemaValidation</a></span></dd>
|
93
93
|
</dl>
|
94
94
|
|
95
95
|
|
@@ -241,6 +241,29 @@
|
|
241
241
|
<span class="summary_desc"><div class='inline'><p>Override this method to perform the actual query.</p>
|
242
242
|
</div></span>
|
243
243
|
|
244
|
+
</li>
|
245
|
+
|
246
|
+
|
247
|
+
<li class="public ">
|
248
|
+
<span class="summary_signature">
|
249
|
+
|
250
|
+
<a href="#connection-instance_method" title="#connection (instance method)">#<strong>connection</strong> ⇒ Object </a>
|
251
|
+
|
252
|
+
|
253
|
+
|
254
|
+
</span>
|
255
|
+
|
256
|
+
|
257
|
+
|
258
|
+
|
259
|
+
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
|
264
|
+
<span class="summary_desc"><div class='inline'><p>Provides a connection to the database.</p>
|
265
|
+
</div></span>
|
266
|
+
|
244
267
|
</li>
|
245
268
|
|
246
269
|
|
@@ -348,6 +371,13 @@
|
|
348
371
|
|
349
372
|
|
350
373
|
|
374
|
+
|
375
|
+
|
376
|
+
|
377
|
+
|
378
|
+
|
379
|
+
|
380
|
+
|
351
381
|
<div id="constructor_details" class="method_details_list">
|
352
382
|
<h2>Constructor Details</h2>
|
353
383
|
|
@@ -377,22 +407,22 @@ was a validation schema specified).</p>
|
|
377
407
|
<pre class="lines">
|
378
408
|
|
379
409
|
|
380
|
-
21
|
381
410
|
22
|
382
411
|
23
|
383
412
|
24
|
384
413
|
25
|
385
414
|
26
|
386
|
-
27
|
415
|
+
27
|
416
|
+
28</pre>
|
387
417
|
</td>
|
388
418
|
<td>
|
389
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
419
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 22</span>
|
390
420
|
|
391
421
|
<span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_params'>params</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
|
392
422
|
<span class='ivar'>@params</span> <span class='op'>=</span> <span class='id identifier rubyid_params'>params</span>
|
393
423
|
|
394
|
-
<span class='kw'>if</span> <span class='
|
395
|
-
<span class='
|
424
|
+
<span class='kw'>if</span> <span class='id identifier rubyid__schema'>_schema</span>
|
425
|
+
<span class='ivar'>@params</span> <span class='op'>=</span> <span class='id identifier rubyid__schema'>_schema</span><span class='period'>.</span><span class='id identifier rubyid_validate!'>validate!</span><span class='lparen'>(</span><span class='ivar'>@params</span><span class='rparen'>)</span>
|
396
426
|
<span class='kw'>end</span>
|
397
427
|
<span class='kw'>end</span></pre>
|
398
428
|
</td>
|
@@ -418,7 +448,7 @@ was a validation schema specified).</p>
|
|
418
448
|
|
419
449
|
</h3><div class="docstring">
|
420
450
|
<div class="discussion">
|
421
|
-
<p>Returns the value of attribute params
|
451
|
+
<p>Returns the value of attribute params.</p>
|
422
452
|
|
423
453
|
|
424
454
|
</div>
|
@@ -432,12 +462,12 @@ was a validation schema specified).</p>
|
|
432
462
|
<pre class="lines">
|
433
463
|
|
434
464
|
|
435
|
-
5
|
436
465
|
6
|
437
|
-
7
|
466
|
+
7
|
467
|
+
8</pre>
|
438
468
|
</td>
|
439
469
|
<td>
|
440
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
470
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 6</span>
|
441
471
|
|
442
472
|
<span class='kw'>def</span> <span class='id identifier rubyid_params'>params</span>
|
443
473
|
<span class='ivar'>@params</span>
|
@@ -480,12 +510,12 @@ and runs <code>call</code> on it.</p>
|
|
480
510
|
<pre class="lines">
|
481
511
|
|
482
512
|
|
483
|
-
15
|
484
513
|
16
|
485
|
-
17
|
514
|
+
17
|
515
|
+
18</pre>
|
486
516
|
</td>
|
487
517
|
<td>
|
488
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
518
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 16</span>
|
489
519
|
|
490
520
|
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
|
491
521
|
<span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span>
|
@@ -521,12 +551,12 @@ and runs <code>call</code> and <code>process</code> on it.</p>
|
|
521
551
|
<pre class="lines">
|
522
552
|
|
523
553
|
|
524
|
-
9
|
525
554
|
10
|
526
|
-
11
|
555
|
+
11
|
556
|
+
12</pre>
|
527
557
|
</td>
|
528
558
|
<td>
|
529
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
559
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 10</span>
|
530
560
|
|
531
561
|
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_run'>run</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
|
532
562
|
<span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_run'>run</span>
|
@@ -567,12 +597,12 @@ and runs <code>call</code> and <code>process</code> on it.</p>
|
|
567
597
|
<pre class="lines">
|
568
598
|
|
569
599
|
|
570
|
-
35
|
571
600
|
36
|
572
|
-
37
|
601
|
+
37
|
602
|
+
38</pre>
|
573
603
|
</td>
|
574
604
|
<td>
|
575
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
605
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 36</span>
|
576
606
|
|
577
607
|
<span class='kw'>def</span> <span class='id identifier rubyid_call'>call</span>
|
578
608
|
<span class='id identifier rubyid_fail'>fail</span> <span class='const'>NotImplementedError</span>
|
@@ -580,6 +610,47 @@ and runs <code>call</code> and <code>process</code> on it.</p>
|
|
580
610
|
</td>
|
581
611
|
</tr>
|
582
612
|
</table>
|
613
|
+
</div>
|
614
|
+
|
615
|
+
<div class="method_details ">
|
616
|
+
<h3 class="signature " id="connection-instance_method">
|
617
|
+
|
618
|
+
#<strong>connection</strong> ⇒ <tt>Object</tt>
|
619
|
+
|
620
|
+
|
621
|
+
|
622
|
+
|
623
|
+
|
624
|
+
</h3><div class="docstring">
|
625
|
+
<div class="discussion">
|
626
|
+
<p>Provides a connection to the database. May be overridden if a different
|
627
|
+
connection is desired. Defaults to <code>ActiveRecord::Base.connection</code>.</p>
|
628
|
+
|
629
|
+
|
630
|
+
</div>
|
631
|
+
</div>
|
632
|
+
<div class="tags">
|
633
|
+
|
634
|
+
|
635
|
+
</div><table class="source_code">
|
636
|
+
<tr>
|
637
|
+
<td>
|
638
|
+
<pre class="lines">
|
639
|
+
|
640
|
+
|
641
|
+
53
|
642
|
+
54
|
643
|
+
55</pre>
|
644
|
+
</td>
|
645
|
+
<td>
|
646
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 53</span>
|
647
|
+
|
648
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_connection'>connection</span>
|
649
|
+
<span class='const'>ActiveRecord</span><span class='op'>::</span><span class='const'>Base</span><span class='period'>.</span><span class='id identifier rubyid_connection'>connection</span>
|
650
|
+
<span class='kw'>end</span></pre>
|
651
|
+
</td>
|
652
|
+
</tr>
|
653
|
+
</table>
|
583
654
|
</div>
|
584
655
|
|
585
656
|
<div class="method_details ">
|
@@ -608,12 +679,12 @@ easyer access.</p>
|
|
608
679
|
<pre class="lines">
|
609
680
|
|
610
681
|
|
611
|
-
46
|
612
682
|
47
|
613
|
-
48
|
683
|
+
48
|
684
|
+
49</pre>
|
614
685
|
</td>
|
615
686
|
<td>
|
616
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
687
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 47</span>
|
617
688
|
|
618
689
|
<span class='kw'>def</span> <span class='id identifier rubyid_osparams'>osparams</span>
|
619
690
|
<span class='ivar'>@osparams</span> <span class='op'>||=</span> <span class='const'>OpenStruct</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_params'>params</span><span class='rparen'>)</span>
|
@@ -648,12 +719,12 @@ easyer access.</p>
|
|
648
719
|
<pre class="lines">
|
649
720
|
|
650
721
|
|
651
|
-
40
|
652
722
|
41
|
653
|
-
42
|
723
|
+
42
|
724
|
+
43</pre>
|
654
725
|
</td>
|
655
726
|
<td>
|
656
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
727
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 41</span>
|
657
728
|
|
658
729
|
<span class='kw'>def</span> <span class='id identifier rubyid_process'>process</span><span class='lparen'>(</span><span class='id identifier rubyid_results'>results</span><span class='rparen'>)</span>
|
659
730
|
<span class='id identifier rubyid_results'>results</span>
|
@@ -688,12 +759,12 @@ easyer access.</p>
|
|
688
759
|
<pre class="lines">
|
689
760
|
|
690
761
|
|
691
|
-
30
|
692
762
|
31
|
693
|
-
32
|
763
|
+
32
|
764
|
+
33</pre>
|
694
765
|
</td>
|
695
766
|
<td>
|
696
|
-
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line
|
767
|
+
<pre class="code"><span class="info file"># File 'lib/inquery/query.rb', line 31</span>
|
697
768
|
|
698
769
|
<span class='kw'>def</span> <span class='id identifier rubyid_run'>run</span>
|
699
770
|
<span class='id identifier rubyid_process'>process</span><span class='lparen'>(</span><span class='id identifier rubyid_call'>call</span><span class='rparen'>)</span>
|
@@ -708,9 +779,9 @@ easyer access.</p>
|
|
708
779
|
</div>
|
709
780
|
|
710
781
|
<div id="footer">
|
711
|
-
Generated on
|
782
|
+
Generated on Wed Nov 25 13:57:22 2020 by
|
712
783
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
713
|
-
0.9.
|
784
|
+
0.9.25 (ruby-2.6.2).
|
714
785
|
</div>
|
715
786
|
|
716
787
|
</div>
|