dh_easy-router 0.0.6
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 +12 -0
- data/.travis.yml +7 -0
- data/.yardopts +1 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +6 -0
- data/LICENSE +21 -0
- data/README.md +20 -0
- data/Rakefile +22 -0
- data/dh_easy-router.gemspec +50 -0
- data/doc/DhEasy.html +117 -0
- data/doc/DhEasy/Core.html +117 -0
- data/doc/DhEasy/Core/Plugin.html +117 -0
- data/doc/DhEasy/Core/Plugin/FinisherBehavior.html +196 -0
- data/doc/DhEasy/Core/Plugin/ParserBehavior.html +196 -0
- data/doc/DhEasy/Core/Plugin/SeederBehavior.html +196 -0
- data/doc/DhEasy/Router.html +146 -0
- data/doc/DhEasy/Router/Finisher.html +345 -0
- data/doc/DhEasy/Router/Parser.html +366 -0
- data/doc/DhEasy/Router/Plugin.html +117 -0
- data/doc/DhEasy/Router/Plugin/Router.html +778 -0
- data/doc/DhEasy/Router/Seeder.html +345 -0
- data/doc/_index.html +224 -0
- data/doc/class_list.html +51 -0
- data/doc/css/common.css +1 -0
- data/doc/css/full_list.css +58 -0
- data/doc/css/style.css +496 -0
- data/doc/file.README.html +92 -0
- data/doc/file_list.html +56 -0
- data/doc/frames.html +17 -0
- data/doc/index.html +92 -0
- data/doc/js/app.js +303 -0
- data/doc/js/full_list.js +216 -0
- data/doc/js/jquery.js +4 -0
- data/doc/method_list.html +147 -0
- data/doc/top-level-namespace.html +110 -0
- data/lib/dh_easy/router.rb +14 -0
- data/lib/dh_easy/router/finisher.rb +38 -0
- data/lib/dh_easy/router/parser.rb +48 -0
- data/lib/dh_easy/router/plugin.rb +8 -0
- data/lib/dh_easy/router/plugin/router.rb +74 -0
- data/lib/dh_easy/router/seeder.rb +38 -0
- data/lib/dh_easy/router/version.rb +6 -0
- data/lib/dh_easy_override/core.rb +6 -0
- data/lib/dh_easy_override/core/plugin.rb +10 -0
- data/lib/dh_easy_override/core/plugin/finisher_behavior.rb +11 -0
- data/lib/dh_easy_override/core/plugin/parser_behavior.rb +11 -0
- data/lib/dh_easy_override/core/plugin/seeder_behavior.rb +11 -0
- metadata +220 -0
@@ -0,0 +1,196 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Module: DhEasy::Core::Plugin::SeederBehavior
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.20
|
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
|
+
pathId = "DhEasy::Core::Plugin::SeederBehavior";
|
19
|
+
relpath = '../../../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../../../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../../../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../../../class_list.html?1"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../../../_index.html">Index (S)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../../DhEasy.html" title="DhEasy (module)">DhEasy</a></span></span> » <span class='title'><span class='object_link'><a href="../../Core.html" title="DhEasy::Core (module)">Core</a></span></span> » <span class='title'><span class='object_link'><a href="../Plugin.html" title="DhEasy::Core::Plugin (module)">Plugin</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">SeederBehavior</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../../../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<div id="content"><h1>Module: DhEasy::Core::Plugin::SeederBehavior
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dl>
|
80
|
+
<dt>Defined in:</dt>
|
81
|
+
<dd>lib/dh_easy_override/core/plugin/seeder_behavior.rb</dd>
|
82
|
+
</dl>
|
83
|
+
|
84
|
+
</div>
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
<h2>
|
95
|
+
Instance Method Summary
|
96
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
97
|
+
</h2>
|
98
|
+
|
99
|
+
<ul class="summary">
|
100
|
+
|
101
|
+
<li class="public ">
|
102
|
+
<span class="summary_signature">
|
103
|
+
|
104
|
+
<a href="#seed-instance_method" title="#seed (instance method)">#<strong>seed</strong> ⇒ Object </a>
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
</span>
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
119
|
+
|
120
|
+
</li>
|
121
|
+
|
122
|
+
|
123
|
+
</ul>
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
|
128
|
+
<div id="instance_method_details" class="method_details_list">
|
129
|
+
<h2>Instance Method Details</h2>
|
130
|
+
|
131
|
+
|
132
|
+
<div class="method_details first">
|
133
|
+
<h3 class="signature first" id="seed-instance_method">
|
134
|
+
|
135
|
+
#<strong>seed</strong> ⇒ <tt>Object</tt>
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
</h3><div class="docstring">
|
142
|
+
<div class="discussion">
|
143
|
+
|
144
|
+
|
145
|
+
</div>
|
146
|
+
</div>
|
147
|
+
<div class="tags">
|
148
|
+
|
149
|
+
<p class="tag_title">Raises:</p>
|
150
|
+
<ul class="raise">
|
151
|
+
|
152
|
+
<li>
|
153
|
+
|
154
|
+
|
155
|
+
<span class='type'>(<tt>NotImplementedError</tt>)</span>
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
</li>
|
160
|
+
|
161
|
+
</ul>
|
162
|
+
|
163
|
+
</div><table class="source_code">
|
164
|
+
<tr>
|
165
|
+
<td>
|
166
|
+
<pre class="lines">
|
167
|
+
|
168
|
+
|
169
|
+
5
|
170
|
+
6
|
171
|
+
7</pre>
|
172
|
+
</td>
|
173
|
+
<td>
|
174
|
+
<pre class="code"><span class="info file"># File 'lib/dh_easy_override/core/plugin/seeder_behavior.rb', line 5</span>
|
175
|
+
|
176
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_seed'>seed</span>
|
177
|
+
<span class='id identifier rubyid_raise'>raise</span> <span class='const'>NotImplementedError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>Must implement "seed" method.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
|
178
|
+
<span class='kw'>end</span></pre>
|
179
|
+
</td>
|
180
|
+
</tr>
|
181
|
+
</table>
|
182
|
+
</div>
|
183
|
+
|
184
|
+
</div>
|
185
|
+
|
186
|
+
</div>
|
187
|
+
|
188
|
+
<div id="footer">
|
189
|
+
Generated on Thu Dec 5 00:39:06 2019 by
|
190
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
191
|
+
0.9.20 (ruby-2.5.3).
|
192
|
+
</div>
|
193
|
+
|
194
|
+
</div>
|
195
|
+
</body>
|
196
|
+
</html>
|
@@ -0,0 +1,146 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Module: DhEasy::Router
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.20
|
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
|
+
pathId = "DhEasy::Router";
|
19
|
+
relpath = '../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../class_list.html?1"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../_index.html">Index (R)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../DhEasy.html" title="DhEasy (module)">DhEasy</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Router</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<div id="content"><h1>Module: DhEasy::Router
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dl>
|
80
|
+
<dt>Defined in:</dt>
|
81
|
+
<dd>lib/dh_easy/router.rb<span class="defines">,<br />
|
82
|
+
lib/dh_easy/router/parser.rb,<br /> lib/dh_easy/router/plugin.rb,<br /> lib/dh_easy/router/seeder.rb,<br /> lib/dh_easy/router/version.rb,<br /> lib/dh_easy/router/finisher.rb,<br /> lib/dh_easy/router/plugin/router.rb</span>
|
83
|
+
</dd>
|
84
|
+
</dl>
|
85
|
+
|
86
|
+
</div>
|
87
|
+
|
88
|
+
<h2>Defined Under Namespace</h2>
|
89
|
+
<p class="children">
|
90
|
+
|
91
|
+
|
92
|
+
<strong class="modules">Modules:</strong> <span class='object_link'><a href="Router/Plugin.html" title="DhEasy::Router::Plugin (module)">Plugin</a></span>
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Router/Finisher.html" title="DhEasy::Router::Finisher (class)">Finisher</a></span>, <span class='object_link'><a href="Router/Parser.html" title="DhEasy::Router::Parser (class)">Parser</a></span>, <span class='object_link'><a href="Router/Seeder.html" title="DhEasy::Router::Seeder (class)">Seeder</a></span>
|
97
|
+
|
98
|
+
|
99
|
+
</p>
|
100
|
+
|
101
|
+
|
102
|
+
<h2>
|
103
|
+
Constant Summary
|
104
|
+
<small><a href="#" class="constants_summary_toggle">collapse</a></small>
|
105
|
+
</h2>
|
106
|
+
|
107
|
+
<dl class="constants">
|
108
|
+
|
109
|
+
<dt id="VERSION-constant" class="">VERSION =
|
110
|
+
<div class="docstring">
|
111
|
+
<div class="discussion">
|
112
|
+
|
113
|
+
<p>Gem version</p>
|
114
|
+
|
115
|
+
|
116
|
+
</div>
|
117
|
+
</div>
|
118
|
+
<div class="tags">
|
119
|
+
|
120
|
+
|
121
|
+
</div>
|
122
|
+
</dt>
|
123
|
+
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>0.0.6</span><span class='tstring_end'>"</span></span></pre></dd>
|
124
|
+
|
125
|
+
</dl>
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
</div>
|
137
|
+
|
138
|
+
<div id="footer">
|
139
|
+
Generated on Thu Dec 5 00:39:06 2019 by
|
140
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
141
|
+
0.9.20 (ruby-2.5.3).
|
142
|
+
</div>
|
143
|
+
|
144
|
+
</div>
|
145
|
+
</body>
|
146
|
+
</html>
|
@@ -0,0 +1,345 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Class: DhEasy::Router::Finisher
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.20
|
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
|
+
pathId = "DhEasy::Router::Finisher";
|
19
|
+
relpath = '../../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../../class_list.html?1"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../../_index.html">Index (F)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../DhEasy.html" title="DhEasy (module)">DhEasy</a></span></span> » <span class='title'><span class='object_link'><a href="../Router.html" title="DhEasy::Router (module)">Router</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Finisher</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<div id="content"><h1>Class: DhEasy::Router::Finisher
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
<dl>
|
70
|
+
<dt>Inherits:</dt>
|
71
|
+
<dd>
|
72
|
+
<span class="inheritName">Object</span>
|
73
|
+
|
74
|
+
<ul class="fullTree">
|
75
|
+
<li>Object</li>
|
76
|
+
|
77
|
+
<li class="next">DhEasy::Router::Finisher</li>
|
78
|
+
|
79
|
+
</ul>
|
80
|
+
<a href="#" class="inheritanceTree">show all</a>
|
81
|
+
|
82
|
+
</dd>
|
83
|
+
</dl>
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
<dl>
|
91
|
+
<dt>Includes:</dt>
|
92
|
+
<dd><span class='object_link'><a href="Plugin/Router.html" title="DhEasy::Router::Plugin::Router (module)">Plugin::Router</a></span></dd>
|
93
|
+
</dl>
|
94
|
+
|
95
|
+
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
<dl>
|
101
|
+
<dt>Defined in:</dt>
|
102
|
+
<dd>lib/dh_easy/router/finisher.rb</dd>
|
103
|
+
</dl>
|
104
|
+
|
105
|
+
</div>
|
106
|
+
|
107
|
+
<h2>Overview</h2><div class="docstring">
|
108
|
+
<div class="discussion">
|
109
|
+
|
110
|
+
<p>Finisher router designed to execute all finisher classes.</p>
|
111
|
+
|
112
|
+
|
113
|
+
</div>
|
114
|
+
</div>
|
115
|
+
<div class="tags">
|
116
|
+
|
117
|
+
|
118
|
+
</div>
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
<h2>Instance Attribute Summary</h2>
|
125
|
+
|
126
|
+
<h3 class="inherited">Attributes included from <span class='object_link'><a href="Plugin/Router.html" title="DhEasy::Router::Plugin::Router (module)">Plugin::Router</a></span></h3>
|
127
|
+
<p class="inherited"><span class='object_link'><a href="Plugin/Router.html#local_config-instance_method" title="DhEasy::Router::Plugin::Router#local_config (method)">#local_config</a></span></p>
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
<h2>
|
132
|
+
Instance Method Summary
|
133
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
134
|
+
</h2>
|
135
|
+
|
136
|
+
<ul class="summary">
|
137
|
+
|
138
|
+
<li class="public ">
|
139
|
+
<span class="summary_signature">
|
140
|
+
|
141
|
+
<a href="#route-instance_method" title="#route (instance method)">#<strong>route</strong>(opts = {}) ⇒ Object </a>
|
142
|
+
|
143
|
+
|
144
|
+
|
145
|
+
</span>
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
<span class="summary_desc"><div class='inline'>
|
156
|
+
<p>Execute the finisher class with options as described by router
|
157
|
+
configuration and calling class's instance `finish` method.</p>
|
158
|
+
</div></span>
|
159
|
+
|
160
|
+
</li>
|
161
|
+
|
162
|
+
|
163
|
+
</ul>
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
|
168
|
+
|
169
|
+
|
170
|
+
|
171
|
+
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
<h3 class="inherited">Methods included from <span class='object_link'><a href="Plugin/Router.html" title="DhEasy::Router::Plugin::Router (module)">Plugin::Router</a></span></h3>
|
176
|
+
<p class="inherited"><span class='object_link'><a href="Plugin/Router.html#class_defined%3F-instance_method" title="DhEasy::Router::Plugin::Router#class_defined? (method)">#class_defined?</a></span>, <span class='object_link'><a href="Plugin/Router.html#config-instance_method" title="DhEasy::Router::Plugin::Router#config (method)">#config</a></span>, <span class='object_link'><a href="Plugin/Router.html#get_class-instance_method" title="DhEasy::Router::Plugin::Router#get_class (method)">#get_class</a></span>, <span class='object_link'><a href="Plugin/Router.html#initialize-instance_method" title="DhEasy::Router::Plugin::Router#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="Plugin/Router.html#initialize_hook_router_plugin_router-instance_method" title="DhEasy::Router::Plugin::Router#initialize_hook_router_plugin_router (method)">#initialize_hook_router_plugin_router</a></span></p>
|
177
|
+
|
178
|
+
|
179
|
+
|
180
|
+
<div id="instance_method_details" class="method_details_list">
|
181
|
+
<h2>Instance Method Details</h2>
|
182
|
+
|
183
|
+
|
184
|
+
<div class="method_details first">
|
185
|
+
<h3 class="signature first" id="route-instance_method">
|
186
|
+
|
187
|
+
#<strong>route</strong>(opts = {}) ⇒ <tt>Object</tt>
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
</h3><div class="docstring">
|
194
|
+
<div class="discussion">
|
195
|
+
|
196
|
+
<div class="note notetag">
|
197
|
+
<strong>Note:</strong>
|
198
|
+
<div class='inline'>
|
199
|
+
<p>Requires the route class to implement `finish` instance method.</p>
|
200
|
+
</div>
|
201
|
+
</div>
|
202
|
+
|
203
|
+
|
204
|
+
<p>Execute the finisher class with options as described by router</p>
|
205
|
+
|
206
|
+
<pre class="code ruby"><code class="ruby">configuration and calling class's instance `finish` method.
|
207
|
+
</code></pre>
|
208
|
+
|
209
|
+
|
210
|
+
</div>
|
211
|
+
</div>
|
212
|
+
<div class="tags">
|
213
|
+
<p class="tag_title">Parameters:</p>
|
214
|
+
<ul class="param">
|
215
|
+
|
216
|
+
<li>
|
217
|
+
|
218
|
+
<span class='name'>opts</span>
|
219
|
+
|
220
|
+
|
221
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
222
|
+
|
223
|
+
|
224
|
+
<em class="default">(defaults to: <tt>{}</tt>)</em>
|
225
|
+
|
226
|
+
|
227
|
+
—
|
228
|
+
<div class='inline'>
|
229
|
+
<p>({}) Finisher initializer options (see DhEasy::Core::Plugin::Finisher).</p>
|
230
|
+
</div>
|
231
|
+
|
232
|
+
</li>
|
233
|
+
|
234
|
+
</ul>
|
235
|
+
|
236
|
+
<p class="tag_title">Raises:</p>
|
237
|
+
<ul class="raise">
|
238
|
+
|
239
|
+
<li>
|
240
|
+
|
241
|
+
|
242
|
+
<span class='type'>(<tt>ArgumentError</tt>)</span>
|
243
|
+
|
244
|
+
|
245
|
+
|
246
|
+
—
|
247
|
+
<div class='inline'>
|
248
|
+
<p>`<a href=":context">opts</a>` is `nil`.</p>
|
249
|
+
</div>
|
250
|
+
|
251
|
+
</li>
|
252
|
+
|
253
|
+
<li>
|
254
|
+
|
255
|
+
|
256
|
+
<span class='type'>(<tt>ArgumentError</tt>)</span>
|
257
|
+
|
258
|
+
|
259
|
+
|
260
|
+
—
|
261
|
+
<div class='inline'>
|
262
|
+
<p>`page_type` doesn't exists within routes.</p>
|
263
|
+
</div>
|
264
|
+
|
265
|
+
</li>
|
266
|
+
|
267
|
+
<li>
|
268
|
+
|
269
|
+
|
270
|
+
<span class='type'>(<tt>NameError</tt>)</span>
|
271
|
+
|
272
|
+
|
273
|
+
|
274
|
+
—
|
275
|
+
<div class='inline'>
|
276
|
+
<p>A class with name equal to route's `class` attribute doesn't
|
277
|
+
exists.</p>
|
278
|
+
</div>
|
279
|
+
|
280
|
+
</li>
|
281
|
+
|
282
|
+
</ul>
|
283
|
+
|
284
|
+
</div><table class="source_code">
|
285
|
+
<tr>
|
286
|
+
<td>
|
287
|
+
<pre class="lines">
|
288
|
+
|
289
|
+
|
290
|
+
19
|
291
|
+
20
|
292
|
+
21
|
293
|
+
22
|
294
|
+
23
|
295
|
+
24
|
296
|
+
25
|
297
|
+
26
|
298
|
+
27
|
299
|
+
28
|
300
|
+
29
|
301
|
+
30
|
302
|
+
31
|
303
|
+
32
|
304
|
+
33
|
305
|
+
34
|
306
|
+
35</pre>
|
307
|
+
</td>
|
308
|
+
<td>
|
309
|
+
<pre class="code"><span class="info file"># File 'lib/dh_easy/router/finisher.rb', line 19</span>
|
310
|
+
|
311
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_route'>route</span> <span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
|
312
|
+
<span class='id identifier rubyid_context'>context</span> <span class='op'>=</span> <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:context</span><span class='rbracket'>]</span>
|
313
|
+
<span class='kw'>if</span> <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:context</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
|
314
|
+
<span class='id identifier rubyid_raise'>raise</span> <span class='const'>ArgumentError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>Must send a context to the finisher.</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
|
315
|
+
<span class='kw'>end</span>
|
316
|
+
|
317
|
+
<span class='id identifier rubyid_class_name'>class_name</span> <span class='op'>=</span> <span class='kw'>nil</span>
|
318
|
+
<span class='id identifier rubyid_config'>config</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>finisher</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>routes</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_item'>item</span><span class='op'>|</span>
|
319
|
+
<span class='comment'># Validate class name
|
320
|
+
</span> <span class='id identifier rubyid_executor_class'>executor_class</span> <span class='op'>=</span> <span class='id identifier rubyid_get_class'>get_class</span> <span class='id identifier rubyid_item'>item</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>class</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span>
|
321
|
+
<span class='kw'>if</span> <span class='id identifier rubyid_executor_class'>executor_class</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
|
322
|
+
<span class='id identifier rubyid_raise'>raise</span> <span class='const'>NameError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Class \"</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_item'>item</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>class</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='embexpr_end'>}</span><span class='tstring_content'>\" doesn't exists, check your ae_easy config file.</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
323
|
+
<span class='kw'>end</span>
|
324
|
+
|
325
|
+
<span class='id identifier rubyid_executor_class'>executor_class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_finish'>finish</span>
|
326
|
+
<span class='kw'>end</span>
|
327
|
+
<span class='kw'>end</span></pre>
|
328
|
+
</td>
|
329
|
+
</tr>
|
330
|
+
</table>
|
331
|
+
</div>
|
332
|
+
|
333
|
+
</div>
|
334
|
+
|
335
|
+
</div>
|
336
|
+
|
337
|
+
<div id="footer">
|
338
|
+
Generated on Thu Dec 5 00:39:06 2019 by
|
339
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
340
|
+
0.9.20 (ruby-2.5.3).
|
341
|
+
</div>
|
342
|
+
|
343
|
+
</div>
|
344
|
+
</body>
|
345
|
+
</html>
|