nucleon 0.2.1 → 0.2.2

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.
Files changed (144) hide show
  1. checksums.yaml +4 -4
  2. data/VERSION +1 -1
  3. data/lib/core/config.rb +1 -1
  4. data/lib/core/core.rb +2 -2
  5. data/lib/core/environment.rb +9 -6
  6. data/lib/core/facade.rb +2 -2
  7. data/lib/core/gems.rb +13 -6
  8. data/lib/core/manager.rb +12 -5
  9. data/lib/core/mixin/action/commit.rb +12 -6
  10. data/lib/core/mixin/action/project.rb +15 -28
  11. data/lib/core/mixin/action/push.rb +14 -5
  12. data/lib/core/mixin/action/registration.rb +277 -28
  13. data/lib/core/mixin/macro/object_interface.rb +3 -3
  14. data/lib/core/mixin/sub_config.rb +1 -1
  15. data/lib/core/plugin/action.rb +20 -51
  16. data/lib/core/plugin/base.rb +41 -8
  17. data/lib/core/plugin/project.rb +55 -8
  18. data/lib/nucleon/action/project/add.rb +6 -20
  19. data/lib/nucleon/action/project/create.rb +2 -2
  20. data/lib/nucleon/action/project/remove.rb +3 -3
  21. data/lib/nucleon/action/project/save.rb +3 -3
  22. data/lib/nucleon/action/project/update.rb +2 -2
  23. data/lib/nucleon/extension/project.rb +16 -0
  24. data/lib/nucleon/project/git.rb +1 -0
  25. data/lib/nucleon/project/github.rb +19 -7
  26. data/nucleon.gemspec +120 -2
  27. data/rdoc/site/0.2.1/ARCHITECTURE_rdoc.html +640 -0
  28. data/rdoc/site/0.2.1/Hash.html +353 -0
  29. data/rdoc/site/0.2.1/Kernel.html +420 -0
  30. data/rdoc/site/0.2.1/Nucleon.html +674 -0
  31. data/rdoc/site/0.2.1/Nucleon/Action.html +286 -0
  32. data/rdoc/site/0.2.1/Nucleon/Action/Extract.html +457 -0
  33. data/rdoc/site/0.2.1/Nucleon/Action/Project.html +285 -0
  34. data/rdoc/site/0.2.1/Nucleon/Action/Project/Add.html +502 -0
  35. data/rdoc/site/0.2.1/Nucleon/Action/Project/Create.html +459 -0
  36. data/rdoc/site/0.2.1/Nucleon/Action/Project/Remove.html +505 -0
  37. data/rdoc/site/0.2.1/Nucleon/Action/Project/Save.html +478 -0
  38. data/rdoc/site/0.2.1/Nucleon/Action/Project/Update.html +425 -0
  39. data/rdoc/site/0.2.1/Nucleon/Codes.html +569 -0
  40. data/rdoc/site/0.2.1/Nucleon/Command.html +281 -0
  41. data/rdoc/site/0.2.1/Nucleon/Command/Bash.html +550 -0
  42. data/rdoc/site/0.2.1/Nucleon/Config.html +1634 -0
  43. data/rdoc/site/0.2.1/Nucleon/Config/Collection.html +515 -0
  44. data/rdoc/site/0.2.1/Nucleon/Config/Options.html +495 -0
  45. data/rdoc/site/0.2.1/Nucleon/Core.html +641 -0
  46. data/rdoc/site/0.2.1/Nucleon/Environment.html +1210 -0
  47. data/rdoc/site/0.2.1/Nucleon/Errors.html +281 -0
  48. data/rdoc/site/0.2.1/Nucleon/Errors/BatchError.html +287 -0
  49. data/rdoc/site/0.2.1/Nucleon/Errors/NucleonError.html +663 -0
  50. data/rdoc/site/0.2.1/Nucleon/Errors/SSHUnavailable.html +287 -0
  51. data/rdoc/site/0.2.1/Nucleon/Event.html +281 -0
  52. data/rdoc/site/0.2.1/Nucleon/Event/Regex.html +473 -0
  53. data/rdoc/site/0.2.1/Nucleon/Facade.html +2452 -0
  54. data/rdoc/site/0.2.1/Nucleon/Gems.html +641 -0
  55. data/rdoc/site/0.2.1/Nucleon/Manager.html +1862 -0
  56. data/rdoc/site/0.2.1/Nucleon/Mixin.html +291 -0
  57. data/rdoc/site/0.2.1/Nucleon/Mixin/Action.html +284 -0
  58. data/rdoc/site/0.2.1/Nucleon/Mixin/Action/Commit.html +387 -0
  59. data/rdoc/site/0.2.1/Nucleon/Mixin/Action/Project.html +401 -0
  60. data/rdoc/site/0.2.1/Nucleon/Mixin/Action/Push.html +377 -0
  61. data/rdoc/site/0.2.1/Nucleon/Mixin/Action/Registration.html +575 -0
  62. data/rdoc/site/0.2.1/Nucleon/Mixin/Colors.html +551 -0
  63. data/rdoc/site/0.2.1/Nucleon/Mixin/ConfigCollection.html +487 -0
  64. data/rdoc/site/0.2.1/Nucleon/Mixin/ConfigOptions.html +455 -0
  65. data/rdoc/site/0.2.1/Nucleon/Mixin/Macro.html +282 -0
  66. data/rdoc/site/0.2.1/Nucleon/Mixin/Macro/ObjectInterface.html +701 -0
  67. data/rdoc/site/0.2.1/Nucleon/Mixin/Macro/PluginInterface.html +688 -0
  68. data/rdoc/site/0.2.1/Nucleon/Mixin/Settings.html +487 -0
  69. data/rdoc/site/0.2.1/Nucleon/Mixin/SubConfig.html +893 -0
  70. data/rdoc/site/0.2.1/Nucleon/Parallel.html +332 -0
  71. data/rdoc/site/0.2.1/Nucleon/Parallel/ClassMethods.html +331 -0
  72. data/rdoc/site/0.2.1/Nucleon/Parallel/InstanceMethods.html +458 -0
  73. data/rdoc/site/0.2.1/Nucleon/Plugin.html +288 -0
  74. data/rdoc/site/0.2.1/Nucleon/Plugin/Action.html +2133 -0
  75. data/rdoc/site/0.2.1/Nucleon/Plugin/Action/Option.html +465 -0
  76. data/rdoc/site/0.2.1/Nucleon/Plugin/Base.html +1988 -0
  77. data/rdoc/site/0.2.1/Nucleon/Plugin/Command.html +765 -0
  78. data/rdoc/site/0.2.1/Nucleon/Plugin/Event.html +448 -0
  79. data/rdoc/site/0.2.1/Nucleon/Plugin/Extension.html +287 -0
  80. data/rdoc/site/0.2.1/Nucleon/Plugin/Project.html +2900 -0
  81. data/rdoc/site/0.2.1/Nucleon/Plugin/Template.html +482 -0
  82. data/rdoc/site/0.2.1/Nucleon/Plugin/Translator.html +377 -0
  83. data/rdoc/site/0.2.1/Nucleon/Project.html +282 -0
  84. data/rdoc/site/0.2.1/Nucleon/Project/Git.html +1807 -0
  85. data/rdoc/site/0.2.1/Nucleon/Project/Github.html +555 -0
  86. data/rdoc/site/0.2.1/Nucleon/Template.html +283 -0
  87. data/rdoc/site/0.2.1/Nucleon/Template/JSON.html +335 -0
  88. data/rdoc/site/0.2.1/Nucleon/Template/Wrapper.html +335 -0
  89. data/rdoc/site/0.2.1/Nucleon/Template/YAML.html +335 -0
  90. data/rdoc/site/0.2.1/Nucleon/Translator.html +282 -0
  91. data/rdoc/site/0.2.1/Nucleon/Translator/JSON.html +372 -0
  92. data/rdoc/site/0.2.1/Nucleon/Translator/YAML.html +372 -0
  93. data/rdoc/site/0.2.1/Nucleon/Util.html +291 -0
  94. data/rdoc/site/0.2.1/Nucleon/Util/CLI.html +394 -0
  95. data/rdoc/site/0.2.1/Nucleon/Util/CLI/Parser.html +1404 -0
  96. data/rdoc/site/0.2.1/Nucleon/Util/Cache.html +824 -0
  97. data/rdoc/site/0.2.1/Nucleon/Util/Console.html +1330 -0
  98. data/rdoc/site/0.2.1/Nucleon/Util/Data.html +1423 -0
  99. data/rdoc/site/0.2.1/Nucleon/Util/Disk.html +528 -0
  100. data/rdoc/site/0.2.1/Nucleon/Util/Git.html +367 -0
  101. data/rdoc/site/0.2.1/Nucleon/Util/Liquid.html +371 -0
  102. data/rdoc/site/0.2.1/Nucleon/Util/Logger.html +822 -0
  103. data/rdoc/site/0.2.1/Nucleon/Util/Package.html +564 -0
  104. data/rdoc/site/0.2.1/Nucleon/Util/SSH.html +1036 -0
  105. data/rdoc/site/0.2.1/Nucleon/Util/SSH/Keypair.html +607 -0
  106. data/rdoc/site/0.2.1/Nucleon/Util/Shell.html +697 -0
  107. data/rdoc/site/0.2.1/Nucleon/Util/Shell/Result.html +503 -0
  108. data/rdoc/site/0.2.1/README_rdoc.html +318 -0
  109. data/rdoc/site/0.2.1/TODO_rdoc.html +267 -0
  110. data/rdoc/site/0.2.1/created.rid +62 -0
  111. data/rdoc/site/0.2.1/images/add.png +0 -0
  112. data/rdoc/site/0.2.1/images/brick.png +0 -0
  113. data/rdoc/site/0.2.1/images/brick_link.png +0 -0
  114. data/rdoc/site/0.2.1/images/bug.png +0 -0
  115. data/rdoc/site/0.2.1/images/bullet_black.png +0 -0
  116. data/rdoc/site/0.2.1/images/bullet_toggle_minus.png +0 -0
  117. data/rdoc/site/0.2.1/images/bullet_toggle_plus.png +0 -0
  118. data/rdoc/site/0.2.1/images/date.png +0 -0
  119. data/rdoc/site/0.2.1/images/delete.png +0 -0
  120. data/rdoc/site/0.2.1/images/find.png +0 -0
  121. data/rdoc/site/0.2.1/images/loadingAnimation.gif +0 -0
  122. data/rdoc/site/0.2.1/images/macFFBgHack.png +0 -0
  123. data/rdoc/site/0.2.1/images/package.png +0 -0
  124. data/rdoc/site/0.2.1/images/page_green.png +0 -0
  125. data/rdoc/site/0.2.1/images/page_white_text.png +0 -0
  126. data/rdoc/site/0.2.1/images/page_white_width.png +0 -0
  127. data/rdoc/site/0.2.1/images/plugin.png +0 -0
  128. data/rdoc/site/0.2.1/images/ruby.png +0 -0
  129. data/rdoc/site/0.2.1/images/tag_blue.png +0 -0
  130. data/rdoc/site/0.2.1/images/tag_green.png +0 -0
  131. data/rdoc/site/0.2.1/images/transparent.png +0 -0
  132. data/rdoc/site/0.2.1/images/wrench.png +0 -0
  133. data/rdoc/site/0.2.1/images/wrench_orange.png +0 -0
  134. data/rdoc/site/0.2.1/images/zoom.png +0 -0
  135. data/rdoc/site/0.2.1/index.html +317 -0
  136. data/rdoc/site/0.2.1/js/darkfish.js +155 -0
  137. data/rdoc/site/0.2.1/js/jquery.js +18 -0
  138. data/rdoc/site/0.2.1/js/navigation.js +142 -0
  139. data/rdoc/site/0.2.1/js/search.js +94 -0
  140. data/rdoc/site/0.2.1/js/search_index.js +1 -0
  141. data/rdoc/site/0.2.1/js/searcher.js +228 -0
  142. data/rdoc/site/0.2.1/rdoc.css +543 -0
  143. data/rdoc/site/0.2.1/table_of_contents.html +1718 -0
  144. metadata +120 -2
@@ -0,0 +1,824 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
6
+
7
+ <title>class Nucleon::Util::Cache - nucleon 0.2.1</title>
8
+
9
+ <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet">
10
+
11
+ <script type="text/javascript">
12
+ var rdoc_rel_prefix = "../../";
13
+ </script>
14
+
15
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
16
+ <script type="text/javascript" charset="utf-8" src="../../js/navigation.js"></script>
17
+ <script type="text/javascript" charset="utf-8" src="../../js/search_index.js"></script>
18
+ <script type="text/javascript" charset="utf-8" src="../../js/search.js"></script>
19
+ <script type="text/javascript" charset="utf-8" src="../../js/searcher.js"></script>
20
+ <script type="text/javascript" charset="utf-8" src="../../js/darkfish.js"></script>
21
+
22
+
23
+ <body id="top" class="class">
24
+ <nav id="metadata">
25
+ <nav id="home-section" class="section">
26
+ <h3 class="section-header">
27
+ <a href="../../index.html">Home</a>
28
+ <a href="../../table_of_contents.html#classes">Classes</a>
29
+ <a href="../../table_of_contents.html#methods">Methods</a>
30
+ </h3>
31
+ </nav>
32
+
33
+
34
+ <nav id="search-section" class="section project-section" class="initially-hidden">
35
+ <form action="#" method="get" accept-charset="utf-8">
36
+ <h3 class="section-header">
37
+ <input type="text" name="search" placeholder="Search" id="search-field"
38
+ title="Type to search, Up and Down to navigate, Enter to load">
39
+ </h3>
40
+ </form>
41
+
42
+ <ul id="search-results" class="initially-hidden"></ul>
43
+ </nav>
44
+
45
+
46
+ <div id="file-metadata">
47
+ <nav id="file-list-section" class="section">
48
+ <h3 class="section-header">Defined In</h3>
49
+ <ul>
50
+ <li>lib/core/util/cache.rb
51
+ </ul>
52
+ </nav>
53
+
54
+
55
+ </div>
56
+
57
+ <div id="class-metadata">
58
+
59
+ <nav id="parent-class-section" class="section">
60
+ <h3 class="section-header">Parent</h3>
61
+
62
+ <p class="link"><a href="../Core.html">Nucleon::Core</a>
63
+
64
+ </nav>
65
+
66
+
67
+ <!-- Method Quickref -->
68
+ <nav id="method-list-section" class="section">
69
+ <h3 class="section-header">Methods</h3>
70
+
71
+ <ul class="link-list">
72
+
73
+ <li><a href="#method-c-new">::new</a>
74
+
75
+ <li><a href="#method-i-base_path">#base_path</a>
76
+
77
+ <li><a href="#method-i-clear">#clear</a>
78
+
79
+ <li><a href="#method-i-delete">#delete</a>
80
+
81
+ <li><a href="#method-i-directory_name">#directory_name</a>
82
+
83
+ <li><a href="#method-i-file">#file</a>
84
+
85
+ <li><a href="#method-i-get">#get</a>
86
+
87
+ <li><a href="#method-i-id">#id</a>
88
+
89
+ <li><a href="#method-i-import_base">#import_base</a>
90
+
91
+ <li><a href="#method-i-load">#load</a>
92
+
93
+ <li><a href="#method-i-save">#save</a>
94
+
95
+ <li><a href="#method-i-set">#set</a>
96
+
97
+ <li><a href="#method-i-status">#status</a>
98
+
99
+ <li><a href="#method-i-translator">#translator</a>
100
+
101
+ </ul>
102
+ </nav>
103
+
104
+ </div>
105
+
106
+ <div id="project-metadata">
107
+ <nav id="fileindex-section" class="section project-section">
108
+ <h3 class="section-header">Pages</h3>
109
+
110
+ <ul>
111
+
112
+ <li class="file"><a href="../../ARCHITECTURE_rdoc.html">ARCHITECTURE</a>
113
+
114
+ <li class="file"><a href="../../README_rdoc.html">README</a>
115
+
116
+ <li class="file"><a href="../../TODO_rdoc.html">TODO</a>
117
+
118
+ </ul>
119
+ </nav>
120
+
121
+ <nav id="classindex-section" class="section project-section">
122
+ <h3 class="section-header">Class and Module Index</h3>
123
+
124
+ <ul class="link-list">
125
+
126
+ <li><a href="../../Nucleon.html">Nucleon</a>
127
+
128
+ <li><a href="../../Nucleon/Action.html">Nucleon::Action</a>
129
+
130
+ <li><a href="../../Nucleon/Action/Extract.html">Nucleon::Action::Extract</a>
131
+
132
+ <li><a href="../../Nucleon/Action/Project.html">Nucleon::Action::Project</a>
133
+
134
+ <li><a href="../../Nucleon/Action/Project/Add.html">Nucleon::Action::Project::Add</a>
135
+
136
+ <li><a href="../../Nucleon/Action/Project/Create.html">Nucleon::Action::Project::Create</a>
137
+
138
+ <li><a href="../../Nucleon/Action/Project/Remove.html">Nucleon::Action::Project::Remove</a>
139
+
140
+ <li><a href="../../Nucleon/Action/Project/Save.html">Nucleon::Action::Project::Save</a>
141
+
142
+ <li><a href="../../Nucleon/Action/Project/Update.html">Nucleon::Action::Project::Update</a>
143
+
144
+ <li><a href="../../Nucleon/Codes.html">Nucleon::Codes</a>
145
+
146
+ <li><a href="../../Nucleon/Command.html">Nucleon::Command</a>
147
+
148
+ <li><a href="../../Nucleon/Command/Bash.html">Nucleon::Command::Bash</a>
149
+
150
+ <li><a href="../../Nucleon/Config.html">Nucleon::Config</a>
151
+
152
+ <li><a href="../../Nucleon/Config/Collection.html">Nucleon::Config::Collection</a>
153
+
154
+ <li><a href="../../Nucleon/Config/Options.html">Nucleon::Config::Options</a>
155
+
156
+ <li><a href="../../Nucleon/Core.html">Nucleon::Core</a>
157
+
158
+ <li><a href="../../Nucleon/Environment.html">Nucleon::Environment</a>
159
+
160
+ <li><a href="../../Nucleon/Errors.html">Nucleon::Errors</a>
161
+
162
+ <li><a href="../../Nucleon/Errors/BatchError.html">Nucleon::Errors::BatchError</a>
163
+
164
+ <li><a href="../../Nucleon/Errors/NucleonError.html">Nucleon::Errors::NucleonError</a>
165
+
166
+ <li><a href="../../Nucleon/Errors/SSHUnavailable.html">Nucleon::Errors::SSHUnavailable</a>
167
+
168
+ <li><a href="../../Nucleon/Event.html">Nucleon::Event</a>
169
+
170
+ <li><a href="../../Nucleon/Event/Regex.html">Nucleon::Event::Regex</a>
171
+
172
+ <li><a href="../../Nucleon/Facade.html">Nucleon::Facade</a>
173
+
174
+ <li><a href="../../Nucleon/Gems.html">Nucleon::Gems</a>
175
+
176
+ <li><a href="../../Nucleon/Manager.html">Nucleon::Manager</a>
177
+
178
+ <li><a href="../../Nucleon/Mixin.html">Nucleon::Mixin</a>
179
+
180
+ <li><a href="../../Nucleon/Mixin/Action.html">Nucleon::Mixin::Action</a>
181
+
182
+ <li><a href="../../Nucleon/Mixin/Action/Commit.html">Nucleon::Mixin::Action::Commit</a>
183
+
184
+ <li><a href="../../Nucleon/Mixin/Action/Project.html">Nucleon::Mixin::Action::Project</a>
185
+
186
+ <li><a href="../../Nucleon/Mixin/Action/Push.html">Nucleon::Mixin::Action::Push</a>
187
+
188
+ <li><a href="../../Nucleon/Mixin/Action/Registration.html">Nucleon::Mixin::Action::Registration</a>
189
+
190
+ <li><a href="../../Nucleon/Mixin/Colors.html">Nucleon::Mixin::Colors</a>
191
+
192
+ <li><a href="../../Nucleon/Mixin/ConfigCollection.html">Nucleon::Mixin::ConfigCollection</a>
193
+
194
+ <li><a href="../../Nucleon/Mixin/ConfigOptions.html">Nucleon::Mixin::ConfigOptions</a>
195
+
196
+ <li><a href="../../Nucleon/Mixin/Macro.html">Nucleon::Mixin::Macro</a>
197
+
198
+ <li><a href="../../Nucleon/Mixin/Macro/ObjectInterface.html">Nucleon::Mixin::Macro::ObjectInterface</a>
199
+
200
+ <li><a href="../../Nucleon/Mixin/Macro/PluginInterface.html">Nucleon::Mixin::Macro::PluginInterface</a>
201
+
202
+ <li><a href="../../Nucleon/Mixin/Settings.html">Nucleon::Mixin::Settings</a>
203
+
204
+ <li><a href="../../Nucleon/Mixin/SubConfig.html">Nucleon::Mixin::SubConfig</a>
205
+
206
+ <li><a href="../../Nucleon/Parallel.html">Nucleon::Parallel</a>
207
+
208
+ <li><a href="../../Nucleon/Parallel/ClassMethods.html">Nucleon::Parallel::ClassMethods</a>
209
+
210
+ <li><a href="../../Nucleon/Parallel/InstanceMethods.html">Nucleon::Parallel::InstanceMethods</a>
211
+
212
+ <li><a href="../../Nucleon/Plugin.html">Nucleon::Plugin</a>
213
+
214
+ <li><a href="../../Nucleon/Plugin/Action.html">Nucleon::Plugin::Action</a>
215
+
216
+ <li><a href="../../Nucleon/Plugin/Action/Option.html">Nucleon::Plugin::Action::Option</a>
217
+
218
+ <li><a href="../../Nucleon/Plugin/Base.html">Nucleon::Plugin::Base</a>
219
+
220
+ <li><a href="../../Nucleon/Plugin/Command.html">Nucleon::Plugin::Command</a>
221
+
222
+ <li><a href="../../Nucleon/Plugin/Event.html">Nucleon::Plugin::Event</a>
223
+
224
+ <li><a href="../../Nucleon/Plugin/Extension.html">Nucleon::Plugin::Extension</a>
225
+
226
+ <li><a href="../../Nucleon/Plugin/Project.html">Nucleon::Plugin::Project</a>
227
+
228
+ <li><a href="../../Nucleon/Plugin/Template.html">Nucleon::Plugin::Template</a>
229
+
230
+ <li><a href="../../Nucleon/Plugin/Translator.html">Nucleon::Plugin::Translator</a>
231
+
232
+ <li><a href="../../Nucleon/Project.html">Nucleon::Project</a>
233
+
234
+ <li><a href="../../Nucleon/Project/Git.html">Nucleon::Project::Git</a>
235
+
236
+ <li><a href="../../Nucleon/Project/Github.html">Nucleon::Project::Github</a>
237
+
238
+ <li><a href="../../Nucleon/Template.html">Nucleon::Template</a>
239
+
240
+ <li><a href="../../Nucleon/Template/JSON.html">Nucleon::Template::JSON</a>
241
+
242
+ <li><a href="../../Nucleon/Template/Wrapper.html">Nucleon::Template::Wrapper</a>
243
+
244
+ <li><a href="../../Nucleon/Template/YAML.html">Nucleon::Template::YAML</a>
245
+
246
+ <li><a href="../../Nucleon/Translator.html">Nucleon::Translator</a>
247
+
248
+ <li><a href="../../Nucleon/Translator/JSON.html">Nucleon::Translator::JSON</a>
249
+
250
+ <li><a href="../../Nucleon/Translator/YAML.html">Nucleon::Translator::YAML</a>
251
+
252
+ <li><a href="../../Nucleon/Util.html">Nucleon::Util</a>
253
+
254
+ <li><a href="../../Nucleon/Util/CLI.html">Nucleon::Util::CLI</a>
255
+
256
+ <li><a href="../../Nucleon/Util/CLI/Parser.html">Nucleon::Util::CLI::Parser</a>
257
+
258
+ <li><a href="../../Nucleon/Util/Cache.html">Nucleon::Util::Cache</a>
259
+
260
+ <li><a href="../../Nucleon/Util/Console.html">Nucleon::Util::Console</a>
261
+
262
+ <li><a href="../../Nucleon/Util/Data.html">Nucleon::Util::Data</a>
263
+
264
+ <li><a href="../../Nucleon/Util/Disk.html">Nucleon::Util::Disk</a>
265
+
266
+ <li><a href="../../Nucleon/Util/Git.html">Nucleon::Util::Git</a>
267
+
268
+ <li><a href="../../Nucleon/Util/Liquid.html">Nucleon::Util::Liquid</a>
269
+
270
+ <li><a href="../../Nucleon/Util/Logger.html">Nucleon::Util::Logger</a>
271
+
272
+ <li><a href="../../Nucleon/Util/Package.html">Nucleon::Util::Package</a>
273
+
274
+ <li><a href="../../Nucleon/Util/SSH.html">Nucleon::Util::SSH</a>
275
+
276
+ <li><a href="../../Nucleon/Util/SSH/Keypair.html">Nucleon::Util::SSH::Keypair</a>
277
+
278
+ <li><a href="../../Nucleon/Util/Shell.html">Nucleon::Util::Shell</a>
279
+
280
+ <li><a href="../../Nucleon/Util/Shell/Result.html">Nucleon::Util::Shell::Result</a>
281
+
282
+ <li><a href="../../Hash.html">Hash</a>
283
+
284
+ <li><a href="../../Kernel.html">Kernel</a>
285
+
286
+ </ul>
287
+ </nav>
288
+
289
+ </div>
290
+ </nav>
291
+
292
+ <div id="documentation">
293
+ <h1 class="class">class Nucleon::Util::Cache</h1>
294
+
295
+ <div id="description" class="description">
296
+
297
+ </div><!-- description -->
298
+
299
+
300
+
301
+
302
+ <section id="5Buntitled-5D" class="documentation-section">
303
+
304
+
305
+
306
+
307
+
308
+
309
+
310
+
311
+ <!-- Methods -->
312
+
313
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section section">
314
+ <h3 class="section-header">Public Class Methods</h3>
315
+
316
+
317
+ <div id="method-c-new" class="method-detail ">
318
+
319
+ <div class="method-heading">
320
+ <span class="method-name">new</span><span
321
+ class="method-args">(root_path, id, cache_dir = '.cache', force = true)</span>
322
+ <span class="method-click-advice">click to toggle source</span>
323
+ </div>
324
+
325
+
326
+ <div class="method-description">
327
+
328
+
329
+
330
+
331
+
332
+ <div class="method-source-code" id="new-source">
333
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 16</span>
334
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">root_path</span>, <span class="ruby-identifier">id</span>, <span class="ruby-identifier">cache_dir</span> = <span class="ruby-string">&#39;.cache&#39;</span>, <span class="ruby-identifier">force</span> = <span class="ruby-keyword">true</span>)
335
+ <span class="ruby-keyword">super</span>({}, {}, <span class="ruby-identifier">force</span>)
336
+
337
+ <span class="ruby-ivar">@cache_dir</span> = <span class="ruby-identifier">cache_dir</span>
338
+ <span class="ruby-ivar">@cache_root</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">root_path</span>, <span class="ruby-identifier">cache_dir</span>)
339
+ <span class="ruby-constant">FileUtils</span>.<span class="ruby-identifier">mkdir_p</span>(<span class="ruby-identifier">base_path</span>) <span class="ruby-keyword">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">directory?</span>(<span class="ruby-identifier">base_path</span>)
340
+
341
+ <span class="ruby-ivar">@cache_id</span> = <span class="ruby-identifier">id</span>.<span class="ruby-identifier">to_sym</span>
342
+ <span class="ruby-ivar">@cache_translator</span> = <span class="ruby-constant">Nucleon</span>.<span class="ruby-identifier">type_default</span>(<span class="ruby-value">:nucleon</span>, <span class="ruby-value">:translator</span>)
343
+ <span class="ruby-ivar">@cache_filename</span> = <span class="ruby-node">&quot;#{id}.#{translator}&quot;</span>
344
+ <span class="ruby-ivar">@cache_path</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-ivar">@cache_root</span>, <span class="ruby-ivar">@cache_filename</span>)
345
+
346
+ <span class="ruby-identifier">load</span>
347
+ <span class="ruby-keyword">end</span></pre>
348
+ </div><!-- new-source -->
349
+
350
+ </div>
351
+
352
+
353
+
354
+
355
+ </div><!-- new-method -->
356
+
357
+
358
+ </section><!-- public-class-method-details -->
359
+
360
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section section">
361
+ <h3 class="section-header">Public Instance Methods</h3>
362
+
363
+
364
+ <div id="method-i-base_path" class="method-detail ">
365
+
366
+ <div class="method-heading">
367
+ <span class="method-name">base_path</span><span
368
+ class="method-args">()</span>
369
+ <span class="method-click-advice">click to toggle source</span>
370
+ </div>
371
+
372
+
373
+ <div class="method-description">
374
+
375
+
376
+
377
+
378
+
379
+ <div class="method-source-code" id="base_path-source">
380
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 40</span>
381
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">base_path</span>
382
+ <span class="ruby-ivar">@cache_root</span>
383
+ <span class="ruby-keyword">end</span></pre>
384
+ </div><!-- base_path-source -->
385
+
386
+ </div>
387
+
388
+
389
+
390
+
391
+ </div><!-- base_path-method -->
392
+
393
+
394
+ <div id="method-i-clear" class="method-detail ">
395
+
396
+ <div class="method-heading">
397
+ <span class="method-name">clear</span><span
398
+ class="method-args">()</span>
399
+ <span class="method-click-advice">click to toggle source</span>
400
+ </div>
401
+
402
+
403
+ <div class="method-description">
404
+
405
+
406
+
407
+
408
+
409
+ <div class="method-source-code" id="clear-source">
410
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 99</span>
411
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">clear</span>
412
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>
413
+ <span class="ruby-identifier">save</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">initialized?</span>
414
+ <span class="ruby-identifier">result</span>
415
+ <span class="ruby-keyword">end</span></pre>
416
+ </div><!-- clear-source -->
417
+
418
+ </div>
419
+
420
+
421
+
422
+
423
+ </div><!-- clear-method -->
424
+
425
+
426
+ <div id="method-i-delete" class="method-detail ">
427
+
428
+ <div class="method-heading">
429
+ <span class="method-name">delete</span><span
430
+ class="method-args">(keys, default = nil)</span>
431
+ <span class="method-click-advice">click to toggle source</span>
432
+ </div>
433
+
434
+
435
+ <div class="method-description">
436
+
437
+
438
+
439
+
440
+
441
+ <div class="method-source-code" id="delete-source">
442
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 91</span>
443
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">delete</span>(<span class="ruby-identifier">keys</span>, <span class="ruby-identifier">default</span> = <span class="ruby-keyword">nil</span>)
444
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>
445
+ <span class="ruby-identifier">save</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">initialized?</span>
446
+ <span class="ruby-identifier">result</span>
447
+ <span class="ruby-keyword">end</span></pre>
448
+ </div><!-- delete-source -->
449
+
450
+ </div>
451
+
452
+
453
+
454
+
455
+ </div><!-- delete-method -->
456
+
457
+
458
+ <div id="method-i-directory_name" class="method-detail ">
459
+
460
+ <div class="method-heading">
461
+ <span class="method-name">directory_name</span><span
462
+ class="method-args">()</span>
463
+ <span class="method-click-advice">click to toggle source</span>
464
+ </div>
465
+
466
+
467
+ <div class="method-description">
468
+
469
+
470
+
471
+
472
+
473
+ <div class="method-source-code" id="directory_name-source">
474
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 46</span>
475
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">directory_name</span>
476
+ <span class="ruby-ivar">@cache_dir</span>
477
+ <span class="ruby-keyword">end</span></pre>
478
+ </div><!-- directory_name-source -->
479
+
480
+ </div>
481
+
482
+
483
+
484
+
485
+ </div><!-- directory_name-method -->
486
+
487
+
488
+ <div id="method-i-file" class="method-detail ">
489
+
490
+ <div class="method-heading">
491
+ <span class="method-name">file</span><span
492
+ class="method-args">()</span>
493
+ <span class="method-click-advice">click to toggle source</span>
494
+ </div>
495
+
496
+
497
+ <div class="method-description">
498
+
499
+
500
+
501
+
502
+
503
+ <div class="method-source-code" id="file-source">
504
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 64</span>
505
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">file</span>
506
+ <span class="ruby-ivar">@cache_path</span>
507
+ <span class="ruby-keyword">end</span></pre>
508
+ </div><!-- file-source -->
509
+
510
+ </div>
511
+
512
+
513
+
514
+
515
+ </div><!-- file-method -->
516
+
517
+
518
+ <div id="method-i-get" class="method-detail ">
519
+
520
+ <div class="method-heading">
521
+ <span class="method-name">get</span><span
522
+ class="method-args">(keys, default = nil, format = false)</span>
523
+ <span class="method-click-advice">click to toggle source</span>
524
+ </div>
525
+
526
+
527
+ <div class="method-description">
528
+
529
+
530
+
531
+
532
+
533
+ <div class="method-source-code" id="get-source">
534
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 70</span>
535
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">get</span>(<span class="ruby-identifier">keys</span>, <span class="ruby-identifier">default</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">format</span> = <span class="ruby-keyword">false</span>)
536
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>(<span class="ruby-identifier">keys</span>, <span class="ruby-keyword">nil</span>)
537
+
538
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">result</span>.<span class="ruby-identifier">nil?</span>
539
+ <span class="ruby-identifier">load</span>
540
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>(<span class="ruby-identifier">keys</span>, <span class="ruby-keyword">nil</span>)
541
+ <span class="ruby-keyword">end</span>
542
+ <span class="ruby-identifier">result</span> = <span class="ruby-identifier">filter</span>(<span class="ruby-identifier">default</span>, <span class="ruby-identifier">format</span>) <span class="ruby-keyword">if</span> <span class="ruby-identifier">result</span>.<span class="ruby-identifier">nil?</span>
543
+ <span class="ruby-identifier">result</span>
544
+ <span class="ruby-keyword">end</span></pre>
545
+ </div><!-- get-source -->
546
+
547
+ </div>
548
+
549
+
550
+
551
+
552
+ </div><!-- get-method -->
553
+
554
+
555
+ <div id="method-i-id" class="method-detail ">
556
+
557
+ <div class="method-heading">
558
+ <span class="method-name">id</span><span
559
+ class="method-args">()</span>
560
+ <span class="method-click-advice">click to toggle source</span>
561
+ </div>
562
+
563
+
564
+ <div class="method-description">
565
+
566
+
567
+
568
+
569
+
570
+ <div class="method-source-code" id="id-source">
571
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 52</span>
572
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">id</span>
573
+ <span class="ruby-ivar">@cache_id</span>
574
+ <span class="ruby-keyword">end</span></pre>
575
+ </div><!-- id-source -->
576
+
577
+ </div>
578
+
579
+
580
+
581
+
582
+ </div><!-- id-method -->
583
+
584
+
585
+ <div id="method-i-import_base" class="method-detail ">
586
+
587
+ <div class="method-heading">
588
+ <span class="method-name">import_base</span><span
589
+ class="method-args">(properties, options = {})</span>
590
+ <span class="method-click-advice">click to toggle source</span>
591
+ </div>
592
+
593
+
594
+ <div class="method-description">
595
+
596
+
597
+
598
+
599
+
600
+ <div class="method-source-code" id="import_base-source">
601
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 108</span>
602
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">import_base</span>(<span class="ruby-identifier">properties</span>, <span class="ruby-identifier">options</span> = {})
603
+ <span class="ruby-identifier">config</span> = <span class="ruby-constant">Config</span>.<span class="ruby-identifier">ensure</span>(<span class="ruby-identifier">options</span>)
604
+
605
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>
606
+ <span class="ruby-identifier">save</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">initialized?</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-operator">!</span> <span class="ruby-identifier">config</span>.<span class="ruby-identifier">get</span>(<span class="ruby-value">:no_save</span>, <span class="ruby-keyword">false</span>)
607
+ <span class="ruby-identifier">result</span>
608
+ <span class="ruby-keyword">end</span></pre>
609
+ </div><!-- import_base-source -->
610
+
611
+ </div>
612
+
613
+
614
+
615
+
616
+ </div><!-- import_base-method -->
617
+
618
+
619
+ <div id="method-i-set" class="method-detail ">
620
+
621
+ <div class="method-heading">
622
+ <span class="method-name">set</span><span
623
+ class="method-args">(keys, value, delete_nil = false)</span>
624
+ <span class="method-click-advice">click to toggle source</span>
625
+ </div>
626
+
627
+
628
+ <div class="method-description">
629
+
630
+
631
+
632
+
633
+
634
+ <div class="method-source-code" id="set-source">
635
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 83</span>
636
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">set</span>(<span class="ruby-identifier">keys</span>, <span class="ruby-identifier">value</span>, <span class="ruby-identifier">delete_nil</span> = <span class="ruby-keyword">false</span>)
637
+ <span class="ruby-identifier">result</span> = <span class="ruby-keyword">super</span>
638
+ <span class="ruby-identifier">save</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">initialized?</span>
639
+ <span class="ruby-identifier">result</span>
640
+ <span class="ruby-keyword">end</span></pre>
641
+ </div><!-- set-source -->
642
+
643
+ </div>
644
+
645
+
646
+
647
+
648
+ </div><!-- set-method -->
649
+
650
+
651
+ <div id="method-i-status" class="method-detail ">
652
+
653
+ <div class="method-heading">
654
+ <span class="method-name">status</span><span
655
+ class="method-args">()</span>
656
+ <span class="method-click-advice">click to toggle source</span>
657
+ </div>
658
+
659
+
660
+ <div class="method-description">
661
+
662
+
663
+
664
+
665
+
666
+ <div class="method-source-code" id="status-source">
667
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 34</span>
668
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">status</span>
669
+ <span class="ruby-ivar">@status</span>
670
+ <span class="ruby-keyword">end</span></pre>
671
+ </div><!-- status-source -->
672
+
673
+ </div>
674
+
675
+
676
+
677
+
678
+ </div><!-- status-method -->
679
+
680
+
681
+ <div id="method-i-translator" class="method-detail ">
682
+
683
+ <div class="method-heading">
684
+ <span class="method-name">translator</span><span
685
+ class="method-args">()</span>
686
+ <span class="method-click-advice">click to toggle source</span>
687
+ </div>
688
+
689
+
690
+ <div class="method-description">
691
+
692
+
693
+
694
+
695
+
696
+ <div class="method-source-code" id="translator-source">
697
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 58</span>
698
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">translator</span>
699
+ <span class="ruby-ivar">@cache_translator</span>
700
+ <span class="ruby-keyword">end</span></pre>
701
+ </div><!-- translator-source -->
702
+
703
+ </div>
704
+
705
+
706
+
707
+
708
+ </div><!-- translator-method -->
709
+
710
+
711
+ </section><!-- public-instance-method-details -->
712
+
713
+ <section id="protected-instance-5Buntitled-5D-method-details" class="method-section section">
714
+ <h3 class="section-header">Protected Instance Methods</h3>
715
+
716
+
717
+ <div id="method-i-load" class="method-detail ">
718
+
719
+ <div class="method-heading">
720
+ <span class="method-name">load</span><span
721
+ class="method-args">()</span>
722
+ <span class="method-click-advice">click to toggle source</span>
723
+ </div>
724
+
725
+
726
+ <div class="method-description">
727
+
728
+
729
+
730
+
731
+
732
+ <div class="method-source-code" id="load-source">
733
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 118</span>
734
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">load</span>
735
+ <span class="ruby-identifier">success</span> = <span class="ruby-keyword">false</span>
736
+ <span class="ruby-ivar">@status</span> = <span class="ruby-value">255</span>
737
+
738
+ <span class="ruby-identifier">@@cache_lock</span>.<span class="ruby-identifier">synchronize</span> <span class="ruby-keyword">do</span>
739
+ <span class="ruby-identifier">logger</span>.<span class="ruby-identifier">info</span>(<span class="ruby-node">&quot;Loading #{translator} translated cache from #{file}&quot;</span>)
740
+
741
+ <span class="ruby-identifier">parser</span> = <span class="ruby-constant">CORL</span>.<span class="ruby-identifier">translator</span>({}, <span class="ruby-identifier">translator</span>)
742
+ <span class="ruby-identifier">raw</span> = <span class="ruby-constant">Disk</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">file</span>)
743
+
744
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">parser</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-identifier">raw</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-operator">!</span> <span class="ruby-identifier">raw</span>.<span class="ruby-identifier">empty?</span>
745
+ <span class="ruby-identifier">logger</span>.<span class="ruby-identifier">debug</span>(<span class="ruby-node">&quot;Cache file contents: #{raw}&quot;</span>)
746
+ <span class="ruby-identifier">parse_properties</span> = <span class="ruby-constant">Data</span>.<span class="ruby-identifier">hash</span>(<span class="ruby-identifier">parser</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">raw</span>))
747
+
748
+ <span class="ruby-constant">Nucleon</span>.<span class="ruby-identifier">remove_plugin</span>(<span class="ruby-identifier">parser</span>)
749
+
750
+ <span class="ruby-identifier">import</span>(<span class="ruby-identifier">parse_properties</span>, { <span class="ruby-value">:no_save</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-keyword">true</span> }) <span class="ruby-keyword">unless</span> <span class="ruby-identifier">parse_properties</span>.<span class="ruby-identifier">empty?</span>
751
+ <span class="ruby-identifier">success</span> = <span class="ruby-keyword">true</span>
752
+ <span class="ruby-ivar">@status</span> = <span class="ruby-constant">Nucleon</span>.<span class="ruby-identifier">code</span>.<span class="ruby-identifier">success</span>
753
+ <span class="ruby-keyword">end</span>
754
+ <span class="ruby-keyword">end</span>
755
+ <span class="ruby-identifier">success</span>
756
+ <span class="ruby-keyword">end</span></pre>
757
+ </div><!-- load-source -->
758
+
759
+ </div>
760
+
761
+
762
+
763
+
764
+ </div><!-- load-method -->
765
+
766
+
767
+ <div id="method-i-save" class="method-detail ">
768
+
769
+ <div class="method-heading">
770
+ <span class="method-name">save</span><span
771
+ class="method-args">()</span>
772
+ <span class="method-click-advice">click to toggle source</span>
773
+ </div>
774
+
775
+
776
+ <div class="method-description">
777
+
778
+
779
+
780
+
781
+
782
+ <div class="method-source-code" id="save-source">
783
+ <pre><span class="ruby-comment"># File lib/core/util/cache.rb, line 145</span>
784
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">save</span>
785
+ <span class="ruby-identifier">success</span> = <span class="ruby-keyword">false</span>
786
+ <span class="ruby-ivar">@status</span> = <span class="ruby-value">255</span>
787
+
788
+ <span class="ruby-identifier">@@cache_lock</span>.<span class="ruby-identifier">synchronize</span> <span class="ruby-keyword">do</span>
789
+ <span class="ruby-keyword">if</span> <span class="ruby-identifier">renderer</span> = <span class="ruby-constant">CORL</span>.<span class="ruby-identifier">translator</span>({}, <span class="ruby-identifier">translator</span>)
790
+ <span class="ruby-identifier">rendering</span> = <span class="ruby-identifier">renderer</span>.<span class="ruby-identifier">generate</span>(<span class="ruby-identifier">export</span>)
791
+
792
+ <span class="ruby-constant">Nucleon</span>.<span class="ruby-identifier">remove_plugin</span>(<span class="ruby-identifier">renderer</span>)
793
+
794
+ <span class="ruby-keyword">if</span> <span class="ruby-constant">Disk</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">file</span>, <span class="ruby-identifier">rendering</span>)
795
+ <span class="ruby-identifier">success</span> = <span class="ruby-keyword">true</span>
796
+ <span class="ruby-ivar">@status</span> = <span class="ruby-constant">Nucleon</span>.<span class="ruby-identifier">code</span>.<span class="ruby-identifier">success</span>
797
+ <span class="ruby-keyword">end</span>
798
+ <span class="ruby-keyword">end</span>
799
+ <span class="ruby-keyword">end</span>
800
+ <span class="ruby-identifier">success</span>
801
+ <span class="ruby-keyword">end</span></pre>
802
+ </div><!-- save-source -->
803
+
804
+ </div>
805
+
806
+
807
+
808
+
809
+ </div><!-- save-method -->
810
+
811
+
812
+ </section><!-- protected-instance-method-details -->
813
+
814
+ </section><!-- 5Buntitled-5D -->
815
+
816
+ </div><!-- documentation -->
817
+
818
+
819
+ <footer id="validator-badges">
820
+ <p><a href="http://validator.w3.org/check/referer">[Validate]</a>
821
+ <p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.2.
822
+ <p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
823
+ </footer>
824
+