utopia 2.13.3 → 2.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (476) hide show
  1. checksums.yaml +4 -4
  2. data/bake/utopia/{yarn.rb → node.rb} +13 -5
  3. data/lib/utopia/command.rb +2 -2
  4. data/lib/utopia/command/site.rb +1 -1
  5. data/lib/utopia/content.rb +23 -19
  6. data/lib/utopia/content/link.rb +29 -34
  7. data/lib/utopia/content/links.rb +185 -123
  8. data/lib/utopia/content/markup.rb +1 -1
  9. data/lib/utopia/content/node.rb +15 -19
  10. data/lib/utopia/content/response.rb +5 -5
  11. data/lib/utopia/controller.rb +0 -17
  12. data/lib/utopia/controller/base.rb +23 -3
  13. data/lib/utopia/controller/respond.rb +50 -107
  14. data/lib/utopia/extensions/array_split.rb +2 -2
  15. data/lib/utopia/http.rb +3 -3
  16. data/lib/utopia/localization.rb +18 -10
  17. data/lib/utopia/middleware.rb +2 -2
  18. data/lib/utopia/path.rb +40 -36
  19. data/lib/utopia/redirection.rb +0 -2
  20. data/lib/utopia/responder.rb +76 -0
  21. data/lib/utopia/version.rb +1 -1
  22. data/setup/site/.gitignore +8 -7
  23. metadata +75 -607
  24. data/.codeclimate.yml +0 -5
  25. data/.gitignore +0 -8
  26. data/.rspec +0 -4
  27. data/.travis.yml +0 -28
  28. data/.yardopts +0 -2
  29. data/Gemfile +0 -28
  30. data/README.md +0 -92
  31. data/Rakefile +0 -33
  32. data/benchmark/call_vs_check.rb +0 -38
  33. data/benchmark/const_vs_hash.rb +0 -35
  34. data/benchmark/hash_vs_openstruct.rb +0 -54
  35. data/benchmark/string_vs_symbol.rb +0 -14
  36. data/benchmark/struct_vs_class.rb +0 -91
  37. data/docs/.nojekyll +0 -0
  38. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.apache.css +0 -6
  39. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.applescript.css +0 -5
  40. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.assembly.css +0 -8
  41. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.bash-script.css +0 -6
  42. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.bash.css +0 -10
  43. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.clang.css +0 -3
  44. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.css.css +0 -14
  45. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.diff.css +0 -16
  46. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.html.css +0 -5
  47. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.ocaml.css +0 -3
  48. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.protobuf.css +0 -2
  49. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.python.css +0 -6
  50. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.ruby.css +0 -2
  51. data/docs/_components/jquery-syntax/base/jquery.syntax.brush.xml.css +0 -18
  52. data/docs/_components/jquery-syntax/base/jquery.syntax.core.css +0 -62
  53. data/docs/_components/jquery-syntax/base/jquery.syntax.editor.css +0 -6
  54. data/docs/_components/jquery-syntax/base/theme.js +0 -1
  55. data/docs/_components/jquery-syntax/bright/jquery.syntax.core.css +0 -27
  56. data/docs/_components/jquery-syntax/bright/theme.js +0 -1
  57. data/docs/_components/jquery-syntax/jquery.syntax.brush.apache.js +0 -41
  58. data/docs/_components/jquery-syntax/jquery.syntax.brush.applescript.js +0 -57
  59. data/docs/_components/jquery-syntax/jquery.syntax.brush.assembly.js +0 -37
  60. data/docs/_components/jquery-syntax/jquery.syntax.brush.bash-script.js +0 -67
  61. data/docs/_components/jquery-syntax/jquery.syntax.brush.bash.js +0 -33
  62. data/docs/_components/jquery-syntax/jquery.syntax.brush.basic.js +0 -51
  63. data/docs/_components/jquery-syntax/jquery.syntax.brush.clang.js +0 -89
  64. data/docs/_components/jquery-syntax/jquery.syntax.brush.csharp.js +0 -47
  65. data/docs/_components/jquery-syntax/jquery.syntax.brush.css.js +0 -80
  66. data/docs/_components/jquery-syntax/jquery.syntax.brush.diff.js +0 -24
  67. data/docs/_components/jquery-syntax/jquery.syntax.brush.go.js +0 -47
  68. data/docs/_components/jquery-syntax/jquery.syntax.brush.haskell.js +0 -45
  69. data/docs/_components/jquery-syntax/jquery.syntax.brush.html.js +0 -66
  70. data/docs/_components/jquery-syntax/jquery.syntax.brush.io.js +0 -45
  71. data/docs/_components/jquery-syntax/jquery.syntax.brush.java.js +0 -45
  72. data/docs/_components/jquery-syntax/jquery.syntax.brush.javascript.js +0 -40
  73. data/docs/_components/jquery-syntax/jquery.syntax.brush.kai.js +0 -29
  74. data/docs/_components/jquery-syntax/jquery.syntax.brush.lisp.js +0 -34
  75. data/docs/_components/jquery-syntax/jquery.syntax.brush.lua.js +0 -44
  76. data/docs/_components/jquery-syntax/jquery.syntax.brush.nginx.js +0 -31
  77. data/docs/_components/jquery-syntax/jquery.syntax.brush.ocaml.js +0 -73
  78. data/docs/_components/jquery-syntax/jquery.syntax.brush.ooc.js +0 -46
  79. data/docs/_components/jquery-syntax/jquery.syntax.brush.pascal.js +0 -51
  80. data/docs/_components/jquery-syntax/jquery.syntax.brush.perl5.js +0 -52
  81. data/docs/_components/jquery-syntax/jquery.syntax.brush.php-script.js +0 -48
  82. data/docs/_components/jquery-syntax/jquery.syntax.brush.php.js +0 -15
  83. data/docs/_components/jquery-syntax/jquery.syntax.brush.plain.js +0 -10
  84. data/docs/_components/jquery-syntax/jquery.syntax.brush.protobuf.js +0 -43
  85. data/docs/_components/jquery-syntax/jquery.syntax.brush.python.js +0 -44
  86. data/docs/_components/jquery-syntax/jquery.syntax.brush.ruby.js +0 -77
  87. data/docs/_components/jquery-syntax/jquery.syntax.brush.scala.js +0 -44
  88. data/docs/_components/jquery-syntax/jquery.syntax.brush.smalltalk.js +0 -29
  89. data/docs/_components/jquery-syntax/jquery.syntax.brush.sql.js +0 -31
  90. data/docs/_components/jquery-syntax/jquery.syntax.brush.super-collider.js +0 -57
  91. data/docs/_components/jquery-syntax/jquery.syntax.brush.swift.js +0 -55
  92. data/docs/_components/jquery-syntax/jquery.syntax.brush.trenni.js +0 -35
  93. data/docs/_components/jquery-syntax/jquery.syntax.brush.xml.js +0 -50
  94. data/docs/_components/jquery-syntax/jquery.syntax.brush.yaml.js +0 -29
  95. data/docs/_components/jquery-syntax/jquery.syntax.cache.js +0 -65
  96. data/docs/_components/jquery-syntax/jquery.syntax.core.js +0 -1098
  97. data/docs/_components/jquery-syntax/jquery.syntax.editor.js +0 -291
  98. data/docs/_components/jquery-syntax/jquery.syntax.js +0 -258
  99. data/docs/_components/jquery-syntax/jquery.syntax.min.js +0 -13
  100. data/docs/_components/jquery-syntax/paper/jquery.syntax.core.css +0 -31
  101. data/docs/_components/jquery-syntax/paper/theme.js +0 -1
  102. data/docs/_components/jquery/core.js +0 -482
  103. data/docs/_components/jquery/jquery.js +0 -10220
  104. data/docs/_components/jquery/jquery.min.js +0 -4
  105. data/docs/_components/jquery/jquery.min.map +0 -1
  106. data/docs/_components/jquery/jquery.slim.js +0 -8107
  107. data/docs/_components/jquery/jquery.slim.min.js +0 -4
  108. data/docs/_components/jquery/jquery.slim.min.map +0 -1
  109. data/docs/_static/icon.png +0 -0
  110. data/docs/_static/site.css +0 -205
  111. data/docs/_static/utopia-background.svg +0 -1
  112. data/docs/_static/utopia.svg +0 -1
  113. data/docs/code/Utopia.html +0 -517
  114. data/docs/code/Utopia/Basename.html +0 -654
  115. data/docs/code/Utopia/Bootstrap.html +0 -538
  116. data/docs/code/Utopia/Command.html +0 -213
  117. data/docs/code/Utopia/Command/Environment.html +0 -321
  118. data/docs/code/Utopia/Command/Server.html +0 -214
  119. data/docs/code/Utopia/Command/Server/Create.html +0 -222
  120. data/docs/code/Utopia/Command/Server/Environment.html +0 -236
  121. data/docs/code/Utopia/Command/Server/Update.html +0 -317
  122. data/docs/code/Utopia/Command/Setup.html +0 -145
  123. data/docs/code/Utopia/Command/Setup/Server.html +0 -298
  124. data/docs/code/Utopia/Command/Setup/Site.html +0 -180
  125. data/docs/code/Utopia/Command/Site.html +0 -285
  126. data/docs/code/Utopia/Command/Site/Create.html +0 -324
  127. data/docs/code/Utopia/Command/Site/Update.html +0 -407
  128. data/docs/code/Utopia/Command/Top.html +0 -279
  129. data/docs/code/Utopia/Content.html +0 -832
  130. data/docs/code/Utopia/Content/Document.html +0 -1822
  131. data/docs/code/Utopia/Content/Document/State.html +0 -1220
  132. data/docs/code/Utopia/Content/Link.html +0 -1286
  133. data/docs/code/Utopia/Content/Links.html +0 -847
  134. data/docs/code/Utopia/Content/MarkupParser.html +0 -881
  135. data/docs/code/Utopia/Content/MarkupParser/ParsedTag.html +0 -422
  136. data/docs/code/Utopia/Content/MarkupParser/UnbalancedTagError.html +0 -615
  137. data/docs/code/Utopia/Content/Namespace.html +0 -485
  138. data/docs/code/Utopia/Content/Node.html +0 -1188
  139. data/docs/code/Utopia/Content/Node/Context.html +0 -938
  140. data/docs/code/Utopia/Content/Response.html +0 -813
  141. data/docs/code/Utopia/Content/SymbolicHash.html +0 -419
  142. data/docs/code/Utopia/Content/Tag.html +0 -399
  143. data/docs/code/Utopia/Content/Tags.html +0 -136
  144. data/docs/code/Utopia/Content/Tags/ContentTag.html +0 -187
  145. data/docs/code/Utopia/Content/Tags/DeferredTag.html +0 -193
  146. data/docs/code/Utopia/Content/Tags/Library.html +0 -333
  147. data/docs/code/Utopia/Content/Tags/NodeTag.html +0 -193
  148. data/docs/code/Utopia/Content/UnbalancedTagError.html +0 -298
  149. data/docs/code/Utopia/ContentLength.html +0 -343
  150. data/docs/code/Utopia/Controller.html +0 -907
  151. data/docs/code/Utopia/Controller/Actions.html +0 -289
  152. data/docs/code/Utopia/Controller/Actions/Action.html +0 -984
  153. data/docs/code/Utopia/Controller/Actions/ClassMethods.html +0 -442
  154. data/docs/code/Utopia/Controller/Base.html +0 -1216
  155. data/docs/code/Utopia/Controller/Respond.html +0 -293
  156. data/docs/code/Utopia/Controller/Respond/ClassMethods.html +0 -236
  157. data/docs/code/Utopia/Controller/Respond/Converter.html +0 -256
  158. data/docs/code/Utopia/Controller/Respond/Converter/Callback.html +0 -484
  159. data/docs/code/Utopia/Controller/Respond/Converter/ToJSON.html +0 -381
  160. data/docs/code/Utopia/Controller/Respond/Passthrough.html +0 -297
  161. data/docs/code/Utopia/Controller/Respond/Responder.html +0 -535
  162. data/docs/code/Utopia/Controller/Rewrite.html +0 -290
  163. data/docs/code/Utopia/Controller/Rewrite/ClassMethods.html +0 -242
  164. data/docs/code/Utopia/Controller/Rewrite/ExtractPrefixRule.html +0 -364
  165. data/docs/code/Utopia/Controller/Rewrite/Rewriter.html +0 -464
  166. data/docs/code/Utopia/Controller/Rewrite/Rule.html +0 -209
  167. data/docs/code/Utopia/Controller/Variables.html +0 -550
  168. data/docs/code/Utopia/Controllers.html +0 -244
  169. data/docs/code/Utopia/Exceptions.html +0 -127
  170. data/docs/code/Utopia/Exceptions/Handler.html +0 -526
  171. data/docs/code/Utopia/Exceptions/Mailer.html +0 -482
  172. data/docs/code/Utopia/Extensions.html +0 -117
  173. data/docs/code/Utopia/Extensions/ArraySplit.html +0 -183
  174. data/docs/code/Utopia/Extensions/DateTimeComparison.html +0 -193
  175. data/docs/code/Utopia/Extensions/TimeDateComparison.html +0 -193
  176. data/docs/code/Utopia/HTTP.html +0 -250
  177. data/docs/code/Utopia/HTTP/Status.html +0 -415
  178. data/docs/code/Utopia/Locale.html +0 -606
  179. data/docs/code/Utopia/Localization.html +0 -1241
  180. data/docs/code/Utopia/Localization/Wrapper.html +0 -459
  181. data/docs/code/Utopia/Logger.html +0 -205
  182. data/docs/code/Utopia/Logger/CompactFormatter.html +0 -335
  183. data/docs/code/Utopia/Path.html +0 -3310
  184. data/docs/code/Utopia/Path/Matcher.html +0 -518
  185. data/docs/code/Utopia/Path/Matcher/MatchData.html +0 -475
  186. data/docs/code/Utopia/Redirection.html +0 -151
  187. data/docs/code/Utopia/Redirection/ClientRedirect.html +0 -717
  188. data/docs/code/Utopia/Redirection/DirectoryIndex.html +0 -298
  189. data/docs/code/Utopia/Redirection/Errors.html +0 -476
  190. data/docs/code/Utopia/Redirection/Moved.html +0 -312
  191. data/docs/code/Utopia/Redirection/RequestFailure.html +0 -226
  192. data/docs/code/Utopia/Redirection/Rewrite.html +0 -296
  193. data/docs/code/Utopia/Session.html +0 -889
  194. data/docs/code/Utopia/Session/LazyHash.html +0 -859
  195. data/docs/code/Utopia/Setup.html +0 -970
  196. data/docs/code/Utopia/Static.html +0 -696
  197. data/docs/code/Utopia/Static/LocalFile.html +0 -1104
  198. data/docs/code/Utopia/Static/MimeTypeLoader.html +0 -541
  199. data/docs/code/Utopia/Static/MimeTypeLoader/ExpansionError.html +0 -124
  200. data/docs/code/Utopia/Tags.html +0 -115
  201. data/docs/code/Utopia/Tags/Environment.html +0 -314
  202. data/docs/code/Utopia/Tags/EnvironmentTag.html +0 -314
  203. data/docs/code/Utopia/Tags/Library.html +0 -340
  204. data/docs/code/_index.html +0 -758
  205. data/docs/code/class_list.html +0 -51
  206. data/docs/code/css/common.css +0 -1
  207. data/docs/code/css/full_list.css +0 -58
  208. data/docs/code/css/style.css +0 -496
  209. data/docs/code/file.README.html +0 -171
  210. data/docs/code/file_list.html +0 -56
  211. data/docs/code/frames.html +0 -17
  212. data/docs/code/index.html +0 -171
  213. data/docs/code/js/app.js +0 -292
  214. data/docs/code/js/full_list.js +0 -216
  215. data/docs/code/js/jquery.js +0 -4
  216. data/docs/code/materials/utopia.png +0 -0
  217. data/docs/code/materials/utopia.svg +0 -1
  218. data/docs/code/method_list.html +0 -3443
  219. data/docs/code/top-level-namespace.html +0 -110
  220. data/docs/index.html +0 -92
  221. data/docs/wiki.html +0 -92
  222. data/docs/wiki/development-environment-setup.html +0 -60
  223. data/docs/wiki/development-environment-setup/index.html +0 -60
  224. data/docs/wiki/edit.html +0 -103
  225. data/docs/wiki/faq/what-is-xnode.html +0 -79
  226. data/docs/wiki/faq/what-is-xnode/index.html +0 -79
  227. data/docs/wiki/javascript.html +0 -153
  228. data/docs/wiki/javascript/index.html +0 -153
  229. data/docs/wiki/middleware/content.html +0 -64
  230. data/docs/wiki/middleware/content/index.html +0 -64
  231. data/docs/wiki/middleware/controller.html +0 -104
  232. data/docs/wiki/middleware/controller/actions.html +0 -117
  233. data/docs/wiki/middleware/controller/actions/index.html +0 -117
  234. data/docs/wiki/middleware/controller/actions/rewrite/index.html +0 -48
  235. data/docs/wiki/middleware/controller/index.html +0 -104
  236. data/docs/wiki/middleware/controller/rewrite.html +0 -111
  237. data/docs/wiki/middleware/controller/rewrite/index.html +0 -111
  238. data/docs/wiki/middleware/localization.html +0 -59
  239. data/docs/wiki/middleware/localization/index.html +0 -59
  240. data/docs/wiki/middleware/redirection.html +0 -61
  241. data/docs/wiki/middleware/redirection/index.html +0 -61
  242. data/docs/wiki/middleware/session.html +0 -71
  243. data/docs/wiki/middleware/session/index.html +0 -71
  244. data/docs/wiki/middleware/static.html +0 -57
  245. data/docs/wiki/middleware/static/index.html +0 -57
  246. data/docs/wiki/server-setup.html +0 -118
  247. data/docs/wiki/server-setup/index.html +0 -118
  248. data/docs/wiki/testing.html +0 -59
  249. data/docs/wiki/testing/index.html +0 -59
  250. data/docs/wiki/updating-utopia.html +0 -108
  251. data/docs/wiki/updating-utopia/index.html +0 -108
  252. data/docs/wiki/your-first-page.html +0 -80
  253. data/docs/wiki/your-first-page/index.html +0 -80
  254. data/documentation/.rspec +0 -4
  255. data/documentation/.yarnrc +0 -1
  256. data/documentation/Gemfile +0 -19
  257. data/documentation/Guardfile +0 -9
  258. data/documentation/Rakefile +0 -9
  259. data/documentation/config.ru +0 -41
  260. data/documentation/config/README.md +0 -7
  261. data/documentation/config/environment.rb +0 -12
  262. data/documentation/lib/readme.txt +0 -1
  263. data/documentation/pages/_editor.xnode +0 -64
  264. data/documentation/pages/_heading.xnode +0 -2
  265. data/documentation/pages/_page.xnode +0 -40
  266. data/documentation/pages/errors/exception.xnode +0 -5
  267. data/documentation/pages/errors/file-not-found.xnode +0 -5
  268. data/documentation/pages/links.yaml +0 -2
  269. data/documentation/pages/wiki/_listing.xnode +0 -32
  270. data/documentation/pages/wiki/_navigation.xnode +0 -15
  271. data/documentation/pages/wiki/content.md +0 -35
  272. data/documentation/pages/wiki/controller.rb +0 -48
  273. data/documentation/pages/wiki/development-environment-setup/content.md +0 -16
  274. data/documentation/pages/wiki/edit.xnode +0 -10
  275. data/documentation/pages/wiki/faq/what-is-xnode/content.md +0 -37
  276. data/documentation/pages/wiki/javascript/content.md +0 -75
  277. data/documentation/pages/wiki/links.yaml +0 -6
  278. data/documentation/pages/wiki/middleware/content/content.md +0 -21
  279. data/documentation/pages/wiki/middleware/controller/actions/content.md +0 -76
  280. data/documentation/pages/wiki/middleware/controller/content.md +0 -62
  281. data/documentation/pages/wiki/middleware/controller/links.yaml +0 -4
  282. data/documentation/pages/wiki/middleware/controller/rewrite/content.md +0 -69
  283. data/documentation/pages/wiki/middleware/localization/content.md +0 -16
  284. data/documentation/pages/wiki/middleware/redirection/content.md +0 -17
  285. data/documentation/pages/wiki/middleware/session/content.md +0 -29
  286. data/documentation/pages/wiki/middleware/static/content.md +0 -13
  287. data/documentation/pages/wiki/server-setup/content.md +0 -52
  288. data/documentation/pages/wiki/show.xnode +0 -12
  289. data/documentation/pages/wiki/testing/content.md +0 -15
  290. data/documentation/pages/wiki/updating-utopia/content.md +0 -63
  291. data/documentation/pages/wiki/your-first-page/content.md +0 -38
  292. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.apache.css +0 -6
  293. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.applescript.css +0 -5
  294. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.assembly.css +0 -8
  295. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.bash-script.css +0 -6
  296. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.bash.css +0 -10
  297. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.clang.css +0 -3
  298. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.css.css +0 -14
  299. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.diff.css +0 -16
  300. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.html.css +0 -5
  301. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.ocaml.css +0 -3
  302. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.protobuf.css +0 -2
  303. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.python.css +0 -6
  304. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.ruby.css +0 -2
  305. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.brush.xml.css +0 -18
  306. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.core.css +0 -62
  307. data/documentation/public/_components/jquery-syntax/base/jquery.syntax.editor.css +0 -6
  308. data/documentation/public/_components/jquery-syntax/base/theme.js +0 -1
  309. data/documentation/public/_components/jquery-syntax/bright/jquery.syntax.core.css +0 -27
  310. data/documentation/public/_components/jquery-syntax/bright/theme.js +0 -1
  311. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.apache.js +0 -41
  312. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.applescript.js +0 -57
  313. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.assembly.js +0 -37
  314. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.bash-script.js +0 -67
  315. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.bash.js +0 -33
  316. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.basic.js +0 -51
  317. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.clang.js +0 -89
  318. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.csharp.js +0 -47
  319. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.css.js +0 -80
  320. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.diff.js +0 -24
  321. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.go.js +0 -47
  322. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.haskell.js +0 -45
  323. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.html.js +0 -66
  324. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.io.js +0 -45
  325. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.java.js +0 -45
  326. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.javascript.js +0 -40
  327. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.kai.js +0 -29
  328. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.lisp.js +0 -34
  329. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.lua.js +0 -44
  330. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.nginx.js +0 -31
  331. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.ocaml.js +0 -73
  332. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.ooc.js +0 -46
  333. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.pascal.js +0 -51
  334. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.perl5.js +0 -52
  335. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.php-script.js +0 -48
  336. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.php.js +0 -15
  337. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.plain.js +0 -10
  338. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.protobuf.js +0 -43
  339. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.python.js +0 -44
  340. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.ruby.js +0 -77
  341. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.scala.js +0 -44
  342. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.smalltalk.js +0 -29
  343. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.sql.js +0 -31
  344. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.super-collider.js +0 -57
  345. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.swift.js +0 -55
  346. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.trenni.js +0 -35
  347. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.xml.js +0 -50
  348. data/documentation/public/_components/jquery-syntax/jquery.syntax.brush.yaml.js +0 -29
  349. data/documentation/public/_components/jquery-syntax/jquery.syntax.cache.js +0 -65
  350. data/documentation/public/_components/jquery-syntax/jquery.syntax.core.js +0 -1098
  351. data/documentation/public/_components/jquery-syntax/jquery.syntax.editor.js +0 -291
  352. data/documentation/public/_components/jquery-syntax/jquery.syntax.js +0 -258
  353. data/documentation/public/_components/jquery-syntax/jquery.syntax.min.js +0 -13
  354. data/documentation/public/_components/jquery-syntax/paper/jquery.syntax.core.css +0 -31
  355. data/documentation/public/_components/jquery-syntax/paper/theme.js +0 -1
  356. data/documentation/public/_components/jquery/core.js +0 -482
  357. data/documentation/public/_components/jquery/jquery.js +0 -10220
  358. data/documentation/public/_components/jquery/jquery.min.js +0 -4
  359. data/documentation/public/_components/jquery/jquery.min.map +0 -1
  360. data/documentation/public/_components/jquery/jquery.slim.js +0 -8107
  361. data/documentation/public/_components/jquery/jquery.slim.min.js +0 -4
  362. data/documentation/public/_components/jquery/jquery.slim.min.map +0 -1
  363. data/documentation/public/_static +0 -1
  364. data/documentation/public/materials +0 -1
  365. data/documentation/spec/website_context.rb +0 -12
  366. data/documentation/spec/website_spec.rb +0 -16
  367. data/documentation/tasks +0 -1
  368. data/materials/utopia.png +0 -0
  369. data/materials/utopia.svg +0 -1
  370. data/setup/site/.yarnrc +0 -1
  371. data/spec/mock_node.rb +0 -16
  372. data/spec/spec_helper.rb +0 -13
  373. data/spec/utopia/command_spec.rb +0 -164
  374. data/spec/utopia/content/document_spec.rb +0 -60
  375. data/spec/utopia/content/link_spec.rb +0 -47
  376. data/spec/utopia/content/links/foo/index.xnode +0 -0
  377. data/spec/utopia/content/links/foo/links.yaml +0 -2
  378. data/spec/utopia/content/links/foo/test.de.xnode +0 -0
  379. data/spec/utopia/content/links/foo/test.en.xnode +0 -0
  380. data/spec/utopia/content/links/links.yaml +0 -9
  381. data/spec/utopia/content/links/welcome.xnode +0 -0
  382. data/spec/utopia/content/links_spec.rb +0 -101
  383. data/spec/utopia/content/localized/five/index.en.xnode +0 -0
  384. data/spec/utopia/content/localized/four/index.en.xnode +0 -0
  385. data/spec/utopia/content/localized/four/index.zh.xnode +0 -0
  386. data/spec/utopia/content/localized/four/links.yaml +0 -4
  387. data/spec/utopia/content/localized/links.yaml +0 -16
  388. data/spec/utopia/content/localized/one.xnode +0 -0
  389. data/spec/utopia/content/localized/three/index.xnode +0 -0
  390. data/spec/utopia/content/localized/two.en.xnode +0 -0
  391. data/spec/utopia/content/localized/two.zh.xnode +0 -0
  392. data/spec/utopia/content/markup_spec.rb +0 -96
  393. data/spec/utopia/content/namespace_spec.rb +0 -45
  394. data/spec/utopia/content/node/lookup/content.xnode +0 -1
  395. data/spec/utopia/content/node/lookup/index.xnode +0 -1
  396. data/spec/utopia/content/node/ordered/first.xnode +0 -0
  397. data/spec/utopia/content/node/ordered/index.xnode +0 -0
  398. data/spec/utopia/content/node/ordered/links.yaml +0 -4
  399. data/spec/utopia/content/node/ordered/second.xnode +0 -0
  400. data/spec/utopia/content/node/related/foo.en.xnode +0 -0
  401. data/spec/utopia/content/node/related/foo.ja.xnode +0 -0
  402. data/spec/utopia/content/node/related/links.yaml +0 -4
  403. data/spec/utopia/content/node_spec.rb +0 -97
  404. data/spec/utopia/content/response_spec.rb +0 -54
  405. data/spec/utopia/content/tags_spec.rb +0 -82
  406. data/spec/utopia/content_spec.rb +0 -100
  407. data/spec/utopia/content_spec.ru +0 -6
  408. data/spec/utopia/content_spec/_heading.xnode +0 -1
  409. data/spec/utopia/content_spec/content/_show-value.xnode +0 -1
  410. data/spec/utopia/content_spec/content/links.yaml +0 -2
  411. data/spec/utopia/content_spec/content/test-partial.xnode +0 -1
  412. data/spec/utopia/content_spec/index.xnode +0 -1
  413. data/spec/utopia/content_spec/node/index.xnode +0 -1
  414. data/spec/utopia/content_spec/test.xnode +0 -10
  415. data/spec/utopia/controller/actions_spec.rb +0 -62
  416. data/spec/utopia/controller/middleware_spec.rb +0 -88
  417. data/spec/utopia/controller/middleware_spec.ru +0 -6
  418. data/spec/utopia/controller/middleware_spec/controller/controller.rb +0 -27
  419. data/spec/utopia/controller/middleware_spec/controller/index.xnode +0 -1
  420. data/spec/utopia/controller/middleware_spec/controller/nested/controller.rb +0 -7
  421. data/spec/utopia/controller/middleware_spec/empty/controller.rb +0 -0
  422. data/spec/utopia/controller/middleware_spec/redirect/controller.rb +0 -12
  423. data/spec/utopia/controller/middleware_spec/redirect/test/controller.rb +0 -9
  424. data/spec/utopia/controller/respond_spec.rb +0 -174
  425. data/spec/utopia/controller/respond_spec.ru +0 -12
  426. data/spec/utopia/controller/respond_spec/api/controller.rb +0 -28
  427. data/spec/utopia/controller/respond_spec/errors/controller.rb +0 -14
  428. data/spec/utopia/controller/respond_spec/errors/file-not-found.xnode +0 -8
  429. data/spec/utopia/controller/respond_spec/html/controller.rb +0 -11
  430. data/spec/utopia/controller/respond_spec/rewrite/controller.rb +0 -13
  431. data/spec/utopia/controller/rewrite_spec.rb +0 -80
  432. data/spec/utopia/controller/sequence_spec.rb +0 -135
  433. data/spec/utopia/controller/variables_spec.rb +0 -59
  434. data/spec/utopia/controller/websocket_spec.rb +0 -68
  435. data/spec/utopia/controller/websocket_spec.ru +0 -5
  436. data/spec/utopia/controller/websocket_spec/server/controller.rb +0 -11
  437. data/spec/utopia/exceptions/handler_spec.rb +0 -47
  438. data/spec/utopia/exceptions/handler_spec.ru +0 -8
  439. data/spec/utopia/exceptions/handler_spec/controller.rb +0 -19
  440. data/spec/utopia/exceptions/mailer_spec.rb +0 -43
  441. data/spec/utopia/exceptions/mailer_spec.ru +0 -10
  442. data/spec/utopia/extensions_spec.rb +0 -73
  443. data/spec/utopia/http/status_spec.rb +0 -44
  444. data/spec/utopia/locale_spec.rb +0 -58
  445. data/spec/utopia/localization_spec.rb +0 -92
  446. data/spec/utopia/localization_spec.ru +0 -15
  447. data/spec/utopia/localization_spec/controller.rb +0 -21
  448. data/spec/utopia/localization_spec/localized.de.txt +0 -1
  449. data/spec/utopia/localization_spec/localized.en.txt +0 -1
  450. data/spec/utopia/localization_spec/localized.ja.txt +0 -1
  451. data/spec/utopia/localization_spec/test.txt +0 -1
  452. data/spec/utopia/middleware_spec.rb +0 -31
  453. data/spec/utopia/path/matcher_spec.rb +0 -66
  454. data/spec/utopia/path_spec.rb +0 -162
  455. data/spec/utopia/performance_spec.rb +0 -92
  456. data/spec/utopia/performance_spec/cache/head/readme.txt +0 -1
  457. data/spec/utopia/performance_spec/cache/meta/readme.txt +0 -1
  458. data/spec/utopia/performance_spec/config.ru +0 -35
  459. data/spec/utopia/performance_spec/lib/readme.txt +0 -1
  460. data/spec/utopia/performance_spec/pages/_heading.xnode +0 -2
  461. data/spec/utopia/performance_spec/pages/_page.xnode +0 -26
  462. data/spec/utopia/performance_spec/pages/api/controller.rb +0 -8
  463. data/spec/utopia/performance_spec/pages/errors/exception.xnode +0 -5
  464. data/spec/utopia/performance_spec/pages/errors/file-not-found.xnode +0 -5
  465. data/spec/utopia/performance_spec/pages/links.yaml +0 -2
  466. data/spec/utopia/performance_spec/pages/welcome/index.xnode +0 -17
  467. data/spec/utopia/rack_helper.rb +0 -32
  468. data/spec/utopia/redirection_spec.rb +0 -77
  469. data/spec/utopia/redirection_spec.ru +0 -27
  470. data/spec/utopia/session_spec.rb +0 -189
  471. data/spec/utopia/session_spec.ru +0 -24
  472. data/spec/utopia/setup_spec.rb +0 -56
  473. data/spec/utopia/static_spec.rb +0 -49
  474. data/spec/utopia/static_spec.ru +0 -5
  475. data/spec/utopia/static_spec/test.txt +0 -1
  476. data/utopia.gemspec +0 -52
@@ -1,3310 +0,0 @@
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: Utopia::Path
8
-
9
- &mdash; Documentation by YARD 0.9.18
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 = "Utopia::Path";
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 (P)</a> &raquo;
40
- <span class='title'><span class='object_link'><a href="../Utopia.html" title="Utopia (module)">Utopia</a></span></span>
41
- &raquo;
42
- <span class="title">Path</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: Utopia::Path
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">Utopia::Path</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>Comparable</dd>
93
- </dl>
94
-
95
-
96
-
97
-
98
-
99
-
100
- <dl>
101
- <dt>Defined in:</dt>
102
- <dd>lib/utopia/path.rb<span class="defines">,<br />
103
- lib/utopia/path/matcher.rb</span>
104
- </dd>
105
- </dl>
106
-
107
- </div>
108
-
109
- <h2>Overview</h2><div class="docstring">
110
- <div class="discussion">
111
- <p>Represents a path as an array of path components. Useful for efficient URL manipulation.</p>
112
-
113
-
114
- </div>
115
- </div>
116
- <div class="tags">
117
-
118
-
119
- </div><h2>Defined Under Namespace</h2>
120
- <p class="children">
121
-
122
-
123
-
124
-
125
- <strong class="classes">Classes:</strong> <span class='object_link'><a href="Path/Matcher.html" title="Utopia::Path::Matcher (class)">Matcher</a></span>
126
-
127
-
128
- </p>
129
-
130
-
131
- <h2>
132
- Constant Summary
133
- <small><a href="#" class="constants_summary_toggle">collapse</a></small>
134
- </h2>
135
-
136
- <dl class="constants">
137
-
138
- <dt id="SEPARATOR-constant" class="">SEPARATOR =
139
-
140
- </dt>
141
- <dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>/</span><span class='tstring_end'>&#39;</span></span><span class='period'>.</span><span class='id identifier rubyid_freeze'>freeze</span></pre></dd>
142
-
143
- </dl>
144
-
145
-
146
-
147
-
148
-
149
- <h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
150
- <ul class="summary">
151
-
152
- <li class="public ">
153
- <span class="summary_signature">
154
-
155
- <a href="#components-instance_method" title="#components (instance method)">#<strong>components</strong> &#x21d2; Object </a>
156
-
157
-
158
-
159
- </span>
160
-
161
-
162
-
163
-
164
-
165
-
166
-
167
-
168
-
169
-
170
-
171
-
172
- <span class="summary_desc"><div class='inline'><p>Returns the value of attribute components.</p>
173
- </div></span>
174
-
175
- </li>
176
-
177
-
178
- </ul>
179
-
180
-
181
-
182
-
183
-
184
- <h2>
185
- Class Method Summary
186
- <small><a href="#" class="summary_toggle">collapse</a></small>
187
- </h2>
188
-
189
- <ul class="summary">
190
-
191
- <li class="public ">
192
- <span class="summary_signature">
193
-
194
- <a href="#[]-class_method" title="[] (class method)">.<strong>[]</strong>(path) &#x21d2; Object </a>
195
-
196
-
197
-
198
- </span>
199
-
200
-
201
-
202
-
203
-
204
-
205
-
206
-
207
-
208
- <span class="summary_desc"><div class='inline'>
209
- </div></span>
210
-
211
- </li>
212
-
213
-
214
- <li class="public ">
215
- <span class="summary_signature">
216
-
217
- <a href="#create-class_method" title="create (class method)">.<strong>create</strong>(path) &#x21d2; Object </a>
218
-
219
-
220
-
221
- </span>
222
-
223
-
224
-
225
-
226
-
227
-
228
-
229
-
230
-
231
- <span class="summary_desc"><div class='inline'>
232
- </div></span>
233
-
234
- </li>
235
-
236
-
237
- <li class="public ">
238
- <span class="summary_signature">
239
-
240
- <a href="#dump-class_method" title="dump (class method)">.<strong>dump</strong>(instance) &#x21d2; Object </a>
241
-
242
-
243
-
244
- </span>
245
-
246
-
247
-
248
-
249
-
250
-
251
-
252
-
253
-
254
- <span class="summary_desc"><div class='inline'>
255
- </div></span>
256
-
257
- </li>
258
-
259
-
260
- <li class="public ">
261
- <span class="summary_signature">
262
-
263
- <a href="#from_string-class_method" title="from_string (class method)">.<strong>from_string</strong>(string) &#x21d2; Object </a>
264
-
265
-
266
-
267
- </span>
268
-
269
-
270
-
271
-
272
-
273
-
274
-
275
-
276
-
277
- <span class="summary_desc"><div class='inline'><p>This constructor takes a string and generates a relative path as efficiently as possible.</p>
278
- </div></span>
279
-
280
- </li>
281
-
282
-
283
- <li class="public ">
284
- <span class="summary_signature">
285
-
286
- <a href="#load-class_method" title="load (class method)">.<strong>load</strong>(value) &#x21d2; Object </a>
287
-
288
-
289
-
290
- </span>
291
-
292
-
293
-
294
-
295
-
296
-
297
-
298
-
299
-
300
- <span class="summary_desc"><div class='inline'>
301
- </div></span>
302
-
303
- </li>
304
-
305
-
306
- <li class="public ">
307
- <span class="summary_signature">
308
-
309
- <a href="#prefix_length-class_method" title="prefix_length (class method)">.<strong>prefix_length</strong>(a, b) &#x21d2; Object </a>
310
-
311
-
312
-
313
- </span>
314
-
315
-
316
-
317
-
318
-
319
-
320
-
321
-
322
-
323
- <span class="summary_desc"><div class='inline'><p>Returns the length of the prefix which is shared by two strings.</p>
324
- </div></span>
325
-
326
- </li>
327
-
328
-
329
- <li class="public ">
330
- <span class="summary_signature">
331
-
332
- <a href="#root-class_method" title="root (class method)">.<strong>root</strong> &#x21d2; Object </a>
333
-
334
-
335
-
336
- </span>
337
-
338
-
339
-
340
-
341
-
342
-
343
-
344
-
345
-
346
- <span class="summary_desc"><div class='inline'>
347
- </div></span>
348
-
349
- </li>
350
-
351
-
352
- <li class="public ">
353
- <span class="summary_signature">
354
-
355
- <a href="#shortest_path-class_method" title="shortest_path (class method)">.<strong>shortest_path</strong>(path, root) &#x21d2; Object </a>
356
-
357
-
358
-
359
- </span>
360
-
361
-
362
-
363
-
364
-
365
-
366
-
367
-
368
-
369
- <span class="summary_desc"><div class='inline'><p>Return the shortest relative path to get to path from root:.</p>
370
- </div></span>
371
-
372
- </li>
373
-
374
-
375
- <li class="public ">
376
- <span class="summary_signature">
377
-
378
- <a href="#split-class_method" title="split (class method)">.<strong>split</strong>(path) &#x21d2; Object </a>
379
-
380
-
381
-
382
- </span>
383
-
384
-
385
-
386
-
387
-
388
-
389
-
390
-
391
-
392
- <span class="summary_desc"><div class='inline'>
393
- </div></span>
394
-
395
- </li>
396
-
397
-
398
- <li class="public ">
399
- <span class="summary_signature">
400
-
401
- <a href="#unescape-class_method" title="unescape (class method)">.<strong>unescape</strong>(string) &#x21d2; Object </a>
402
-
403
-
404
-
405
- </span>
406
-
407
-
408
-
409
-
410
-
411
-
412
-
413
-
414
-
415
- <span class="summary_desc"><div class='inline'><p>Converts ‘+’ into whitespace and hex encoded characters into their equivalent characters.</p>
416
- </div></span>
417
-
418
- </li>
419
-
420
-
421
- </ul>
422
-
423
- <h2>
424
- Instance Method Summary
425
- <small><a href="#" class="summary_toggle">collapse</a></small>
426
- </h2>
427
-
428
- <ul class="summary">
429
-
430
- <li class="public ">
431
- <span class="summary_signature">
432
-
433
- <a href="#%2B-instance_method" title="#+ (instance method)">#<strong>+</strong>(other) &#x21d2; Object </a>
434
-
435
-
436
-
437
- </span>
438
-
439
-
440
-
441
-
442
-
443
-
444
-
445
-
446
-
447
- <span class="summary_desc"><div class='inline'>
448
- </div></span>
449
-
450
- </li>
451
-
452
-
453
- <li class="public ">
454
- <span class="summary_signature">
455
-
456
- <a href="#--instance_method" title="#- (instance method)">#<strong>-</strong>(other) &#x21d2; Object </a>
457
-
458
-
459
-
460
- </span>
461
-
462
-
463
-
464
-
465
-
466
-
467
-
468
-
469
-
470
- <span class="summary_desc"><div class='inline'><p>Computes the difference of the path.</p>
471
- </div></span>
472
-
473
- </li>
474
-
475
-
476
- <li class="public ">
477
- <span class="summary_signature">
478
-
479
- <a href="#<=>-instance_method" title="#&lt;=&gt; (instance method)">#<strong>&lt;=&gt;</strong>(other) &#x21d2; Object </a>
480
-
481
-
482
-
483
- </span>
484
-
485
-
486
-
487
-
488
-
489
-
490
-
491
-
492
-
493
- <span class="summary_desc"><div class='inline'>
494
- </div></span>
495
-
496
- </li>
497
-
498
-
499
- <li class="public ">
500
- <span class="summary_signature">
501
-
502
- <a href="#==-instance_method" title="#== (instance method)">#<strong>==</strong>(other) &#x21d2; Object </a>
503
-
504
-
505
-
506
- </span>
507
-
508
-
509
-
510
-
511
-
512
-
513
-
514
-
515
-
516
- <span class="summary_desc"><div class='inline'>
517
- </div></span>
518
-
519
- </li>
520
-
521
-
522
- <li class="public ">
523
- <span class="summary_signature">
524
-
525
- <a href="#[]-instance_method" title="#[] (instance method)">#<strong>[]</strong>(index) &#x21d2; Object </a>
526
-
527
-
528
-
529
- </span>
530
-
531
-
532
-
533
-
534
-
535
-
536
-
537
-
538
-
539
- <span class="summary_desc"><div class='inline'>
540
- </div></span>
541
-
542
- </li>
543
-
544
-
545
- <li class="public ">
546
- <span class="summary_signature">
547
-
548
- <a href="#[]=-instance_method" title="#[]= (instance method)">#<strong>[]=</strong>(index, value) &#x21d2; Object </a>
549
-
550
-
551
-
552
- </span>
553
-
554
-
555
-
556
-
557
-
558
-
559
-
560
-
561
-
562
- <span class="summary_desc"><div class='inline'><p>Replaces a named component, indexing as per.</p>
563
- </div></span>
564
-
565
- </li>
566
-
567
-
568
- <li class="public ">
569
- <span class="summary_signature">
570
-
571
- <a href="#absolute%3F-instance_method" title="#absolute? (instance method)">#<strong>absolute?</strong> &#x21d2; Boolean </a>
572
-
573
-
574
-
575
- </span>
576
-
577
-
578
-
579
-
580
-
581
-
582
-
583
-
584
-
585
- <span class="summary_desc"><div class='inline'>
586
- </div></span>
587
-
588
- </li>
589
-
590
-
591
- <li class="public ">
592
- <span class="summary_signature">
593
-
594
- <a href="#ascend-instance_method" title="#ascend (instance method)">#<strong>ascend</strong>(&amp;block) &#x21d2; Object </a>
595
-
596
-
597
-
598
- </span>
599
-
600
-
601
-
602
-
603
-
604
-
605
-
606
-
607
-
608
- <span class="summary_desc"><div class='inline'>
609
- </div></span>
610
-
611
- </li>
612
-
613
-
614
- <li class="public ">
615
- <span class="summary_signature">
616
-
617
- <a href="#basename-instance_method" title="#basename (instance method)">#<strong>basename</strong> &#x21d2; Object </a>
618
-
619
-
620
-
621
- </span>
622
-
623
-
624
-
625
-
626
-
627
-
628
-
629
-
630
-
631
- <span class="summary_desc"><div class='inline'>
632
- </div></span>
633
-
634
- </li>
635
-
636
-
637
- <li class="public ">
638
- <span class="summary_signature">
639
-
640
- <a href="#delete_at-instance_method" title="#delete_at (instance method)">#<strong>delete_at</strong>(index) &#x21d2; Object </a>
641
-
642
-
643
-
644
- </span>
645
-
646
-
647
-
648
-
649
-
650
-
651
-
652
-
653
-
654
- <span class="summary_desc"><div class='inline'>
655
- </div></span>
656
-
657
- </li>
658
-
659
-
660
- <li class="public ">
661
- <span class="summary_signature">
662
-
663
- <a href="#descend-instance_method" title="#descend (instance method)">#<strong>descend</strong>(&amp;block) &#x21d2; Object </a>
664
-
665
-
666
-
667
- </span>
668
-
669
-
670
-
671
-
672
-
673
-
674
-
675
-
676
-
677
- <span class="summary_desc"><div class='inline'>
678
- </div></span>
679
-
680
- </li>
681
-
682
-
683
- <li class="public ">
684
- <span class="summary_signature">
685
-
686
- <a href="#directory%3F-instance_method" title="#directory? (instance method)">#<strong>directory?</strong> &#x21d2; Boolean </a>
687
-
688
-
689
-
690
- </span>
691
-
692
-
693
-
694
-
695
-
696
-
697
-
698
-
699
-
700
- <span class="summary_desc"><div class='inline'>
701
- </div></span>
702
-
703
- </li>
704
-
705
-
706
- <li class="public ">
707
- <span class="summary_signature">
708
-
709
- <a href="#dirname-instance_method" title="#dirname (instance method)">#<strong>dirname</strong>(count = 1) &#x21d2; Object </a>
710
-
711
-
712
-
713
- </span>
714
-
715
-
716
-
717
-
718
-
719
-
720
-
721
-
722
-
723
- <span class="summary_desc"><div class='inline'>
724
- </div></span>
725
-
726
- </li>
727
-
728
-
729
- <li class="public ">
730
- <span class="summary_signature">
731
-
732
- <a href="#dup-instance_method" title="#dup (instance method)">#<strong>dup</strong> &#x21d2; Object </a>
733
-
734
-
735
-
736
- </span>
737
-
738
-
739
-
740
-
741
-
742
-
743
-
744
-
745
-
746
- <span class="summary_desc"><div class='inline'>
747
- </div></span>
748
-
749
- </li>
750
-
751
-
752
- <li class="public ">
753
- <span class="summary_signature">
754
-
755
- <a href="#empty%3F-instance_method" title="#empty? (instance method)">#<strong>empty?</strong> &#x21d2; Boolean </a>
756
-
757
-
758
-
759
- </span>
760
-
761
-
762
-
763
-
764
-
765
-
766
-
767
-
768
-
769
- <span class="summary_desc"><div class='inline'>
770
- </div></span>
771
-
772
- </li>
773
-
774
-
775
- <li class="public ">
776
- <span class="summary_signature">
777
-
778
- <a href="#eql%3F-instance_method" title="#eql? (instance method)">#<strong>eql?</strong>(other) &#x21d2; Boolean </a>
779
-
780
-
781
-
782
- </span>
783
-
784
-
785
-
786
-
787
-
788
-
789
-
790
-
791
-
792
- <span class="summary_desc"><div class='inline'>
793
- </div></span>
794
-
795
- </li>
796
-
797
-
798
- <li class="public ">
799
- <span class="summary_signature">
800
-
801
- <a href="#expand-instance_method" title="#expand (instance method)">#<strong>expand</strong>(root) &#x21d2; Object </a>
802
-
803
-
804
-
805
- </span>
806
-
807
-
808
-
809
-
810
-
811
-
812
-
813
-
814
-
815
- <span class="summary_desc"><div class='inline'>
816
- </div></span>
817
-
818
- </li>
819
-
820
-
821
- <li class="public ">
822
- <span class="summary_signature">
823
-
824
- <a href="#extension-instance_method" title="#extension (instance method)">#<strong>extension</strong> &#x21d2; Object </a>
825
-
826
-
827
-
828
- </span>
829
-
830
-
831
-
832
-
833
-
834
-
835
-
836
-
837
-
838
- <span class="summary_desc"><div class='inline'>
839
- </div></span>
840
-
841
- </li>
842
-
843
-
844
- <li class="public ">
845
- <span class="summary_signature">
846
-
847
- <a href="#first-instance_method" title="#first (instance method)">#<strong>first</strong> &#x21d2; Object </a>
848
-
849
-
850
-
851
- </span>
852
-
853
-
854
-
855
-
856
-
857
-
858
-
859
-
860
-
861
- <span class="summary_desc"><div class='inline'>
862
- </div></span>
863
-
864
- </li>
865
-
866
-
867
- <li class="public ">
868
- <span class="summary_signature">
869
-
870
- <a href="#freeze-instance_method" title="#freeze (instance method)">#<strong>freeze</strong> &#x21d2; Object </a>
871
-
872
-
873
-
874
- </span>
875
-
876
-
877
-
878
-
879
-
880
-
881
-
882
-
883
-
884
- <span class="summary_desc"><div class='inline'>
885
- </div></span>
886
-
887
- </li>
888
-
889
-
890
- <li class="public ">
891
- <span class="summary_signature">
892
-
893
- <a href="#hash-instance_method" title="#hash (instance method)">#<strong>hash</strong> &#x21d2; Object </a>
894
-
895
-
896
-
897
- </span>
898
-
899
-
900
-
901
-
902
-
903
-
904
-
905
-
906
-
907
- <span class="summary_desc"><div class='inline'>
908
- </div></span>
909
-
910
- </li>
911
-
912
-
913
- <li class="public ">
914
- <span class="summary_signature">
915
-
916
- <a href="#include%3F-instance_method" title="#include? (instance method)">#<strong>include?</strong>(*args) &#x21d2; Boolean </a>
917
-
918
-
919
-
920
- </span>
921
-
922
-
923
-
924
-
925
-
926
-
927
-
928
-
929
-
930
- <span class="summary_desc"><div class='inline'>
931
- </div></span>
932
-
933
- </li>
934
-
935
-
936
- <li class="public ">
937
- <span class="summary_signature">
938
-
939
- <a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(components = []) &#x21d2; Path </a>
940
-
941
-
942
-
943
- </span>
944
-
945
-
946
- <span class="note title constructor">constructor</span>
947
-
948
-
949
-
950
-
951
-
952
-
953
-
954
-
955
- <span class="summary_desc"><div class='inline'><p>A new instance of Path.</p>
956
- </div></span>
957
-
958
- </li>
959
-
960
-
961
- <li class="public ">
962
- <span class="summary_signature">
963
-
964
- <a href="#join-instance_method" title="#join (instance method)">#<strong>join</strong>(other) &#x21d2; Object </a>
965
-
966
-
967
-
968
- </span>
969
-
970
-
971
-
972
-
973
-
974
-
975
-
976
-
977
-
978
- <span class="summary_desc"><div class='inline'>
979
- </div></span>
980
-
981
- </li>
982
-
983
-
984
- <li class="public ">
985
- <span class="summary_signature">
986
-
987
- <a href="#last-instance_method" title="#last (instance method)">#<strong>last</strong> &#x21d2; Object </a>
988
-
989
-
990
-
991
- </span>
992
-
993
-
994
-
995
-
996
-
997
-
998
-
999
-
1000
-
1001
- <span class="summary_desc"><div class='inline'>
1002
- </div></span>
1003
-
1004
- </li>
1005
-
1006
-
1007
- <li class="public ">
1008
- <span class="summary_signature">
1009
-
1010
- <a href="#relative%3F-instance_method" title="#relative? (instance method)">#<strong>relative?</strong> &#x21d2; Boolean </a>
1011
-
1012
-
1013
-
1014
- </span>
1015
-
1016
-
1017
-
1018
-
1019
-
1020
-
1021
-
1022
-
1023
-
1024
- <span class="summary_desc"><div class='inline'>
1025
- </div></span>
1026
-
1027
- </li>
1028
-
1029
-
1030
- <li class="public ">
1031
- <span class="summary_signature">
1032
-
1033
- <a href="#replace-instance_method" title="#replace (instance method)">#<strong>replace</strong>(other_path) &#x21d2; Object </a>
1034
-
1035
-
1036
-
1037
- </span>
1038
-
1039
-
1040
-
1041
-
1042
-
1043
-
1044
-
1045
-
1046
-
1047
- <span class="summary_desc"><div class='inline'>
1048
- </div></span>
1049
-
1050
- </li>
1051
-
1052
-
1053
- <li class="public ">
1054
- <span class="summary_signature">
1055
-
1056
- <a href="#shortest_path-instance_method" title="#shortest_path (instance method)">#<strong>shortest_path</strong>(root) &#x21d2; Object </a>
1057
-
1058
-
1059
-
1060
- </span>
1061
-
1062
-
1063
-
1064
-
1065
-
1066
-
1067
-
1068
-
1069
-
1070
- <span class="summary_desc"><div class='inline'>
1071
- </div></span>
1072
-
1073
- </li>
1074
-
1075
-
1076
- <li class="public ">
1077
- <span class="summary_signature">
1078
-
1079
- <a href="#simplify-instance_method" title="#simplify (instance method)">#<strong>simplify</strong> &#x21d2; Object </a>
1080
-
1081
-
1082
-
1083
- </span>
1084
-
1085
-
1086
-
1087
-
1088
-
1089
-
1090
-
1091
-
1092
-
1093
- <span class="summary_desc"><div class='inline'>
1094
- </div></span>
1095
-
1096
- </li>
1097
-
1098
-
1099
- <li class="public ">
1100
- <span class="summary_signature">
1101
-
1102
- <a href="#split-instance_method" title="#split (instance method)">#<strong>split</strong>(at) &#x21d2; Object </a>
1103
-
1104
-
1105
-
1106
- </span>
1107
-
1108
-
1109
-
1110
-
1111
-
1112
-
1113
-
1114
-
1115
-
1116
- <span class="summary_desc"><div class='inline'>
1117
- </div></span>
1118
-
1119
- </li>
1120
-
1121
-
1122
- <li class="public ">
1123
- <span class="summary_signature">
1124
-
1125
- <a href="#start_with%3F-instance_method" title="#start_with? (instance method)">#<strong>start_with?</strong>(other) &#x21d2; Boolean </a>
1126
-
1127
-
1128
-
1129
- </span>
1130
-
1131
-
1132
-
1133
-
1134
-
1135
-
1136
-
1137
-
1138
-
1139
- <span class="summary_desc"><div class='inline'>
1140
- </div></span>
1141
-
1142
- </li>
1143
-
1144
-
1145
- <li class="public ">
1146
- <span class="summary_signature">
1147
-
1148
- <a href="#to_a-instance_method" title="#to_a (instance method)">#<strong>to_a</strong> &#x21d2; Object </a>
1149
-
1150
-
1151
-
1152
- </span>
1153
-
1154
-
1155
-
1156
-
1157
-
1158
-
1159
-
1160
-
1161
-
1162
- <span class="summary_desc"><div class='inline'>
1163
- </div></span>
1164
-
1165
- </li>
1166
-
1167
-
1168
- <li class="public ">
1169
- <span class="summary_signature">
1170
-
1171
- <a href="#to_absolute-instance_method" title="#to_absolute (instance method)">#<strong>to_absolute</strong> &#x21d2; Object </a>
1172
-
1173
-
1174
-
1175
- </span>
1176
-
1177
-
1178
-
1179
-
1180
-
1181
-
1182
-
1183
-
1184
-
1185
- <span class="summary_desc"><div class='inline'>
1186
- </div></span>
1187
-
1188
- </li>
1189
-
1190
-
1191
- <li class="public ">
1192
- <span class="summary_signature">
1193
-
1194
- <a href="#to_directory-instance_method" title="#to_directory (instance method)">#<strong>to_directory</strong> &#x21d2; Object </a>
1195
-
1196
-
1197
-
1198
- </span>
1199
-
1200
-
1201
-
1202
-
1203
-
1204
-
1205
-
1206
-
1207
-
1208
- <span class="summary_desc"><div class='inline'>
1209
- </div></span>
1210
-
1211
- </li>
1212
-
1213
-
1214
- <li class="public ">
1215
- <span class="summary_signature">
1216
-
1217
- <a href="#to_local_path-instance_method" title="#to_local_path (instance method)">#<strong>to_local_path</strong>(separator = File::SEPARATOR) &#x21d2; Object </a>
1218
-
1219
-
1220
-
1221
- </span>
1222
-
1223
-
1224
-
1225
-
1226
-
1227
-
1228
-
1229
-
1230
-
1231
- <span class="summary_desc"><div class='inline'>
1232
- </div></span>
1233
-
1234
- </li>
1235
-
1236
-
1237
- <li class="public ">
1238
- <span class="summary_signature">
1239
-
1240
- <a href="#to_relative!-instance_method" title="#to_relative! (instance method)">#<strong>to_relative!</strong> &#x21d2; Object </a>
1241
-
1242
-
1243
-
1244
- </span>
1245
-
1246
-
1247
-
1248
-
1249
-
1250
-
1251
-
1252
-
1253
-
1254
- <span class="summary_desc"><div class='inline'>
1255
- </div></span>
1256
-
1257
- </li>
1258
-
1259
-
1260
- <li class="public ">
1261
- <span class="summary_signature">
1262
-
1263
- <a href="#to_str-instance_method" title="#to_str (instance method)">#<strong>to_str</strong> &#x21d2; Object </a>
1264
-
1265
-
1266
-
1267
- (also: #to_s)
1268
-
1269
- </span>
1270
-
1271
-
1272
-
1273
-
1274
-
1275
-
1276
-
1277
-
1278
-
1279
- <span class="summary_desc"><div class='inline'>
1280
- </div></span>
1281
-
1282
- </li>
1283
-
1284
-
1285
- <li class="public ">
1286
- <span class="summary_signature">
1287
-
1288
- <a href="#with_prefix-instance_method" title="#with_prefix (instance method)">#<strong>with_prefix</strong>(*args) &#x21d2; Object </a>
1289
-
1290
-
1291
-
1292
- </span>
1293
-
1294
-
1295
-
1296
-
1297
-
1298
-
1299
-
1300
-
1301
-
1302
- <span class="summary_desc"><div class='inline'>
1303
- </div></span>
1304
-
1305
- </li>
1306
-
1307
-
1308
- </ul>
1309
-
1310
-
1311
-
1312
- <div id="constructor_details" class="method_details_list">
1313
- <h2>Constructor Details</h2>
1314
-
1315
- <div class="method_details first">
1316
- <h3 class="signature first" id="initialize-instance_method">
1317
-
1318
- #<strong>initialize</strong>(components = []) &#x21d2; <tt><span class='object_link'><a href="" title="Utopia::Path (class)">Path</a></span></tt>
1319
-
1320
-
1321
-
1322
-
1323
-
1324
- </h3><div class="docstring">
1325
- <div class="discussion">
1326
- <p>Returns a new instance of Path</p>
1327
-
1328
-
1329
- </div>
1330
- </div>
1331
- <div class="tags">
1332
-
1333
-
1334
- </div><table class="source_code">
1335
- <tr>
1336
- <td>
1337
- <pre class="lines">
1338
-
1339
-
1340
- 28
1341
- 29
1342
- 30</pre>
1343
- </td>
1344
- <td>
1345
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 28</span>
1346
-
1347
- <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_components'>components</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1348
- <span class='ivar'>@components</span> <span class='op'>=</span> <span class='id identifier rubyid_components'>components</span>
1349
- <span class='kw'>end</span></pre>
1350
- </td>
1351
- </tr>
1352
- </table>
1353
- </div>
1354
-
1355
- </div>
1356
-
1357
- <div id="instance_attr_details" class="attr_details">
1358
- <h2>Instance Attribute Details</h2>
1359
-
1360
-
1361
- <span id="components=-instance_method"></span>
1362
- <div class="method_details first">
1363
- <h3 class="signature first" id="components-instance_method">
1364
-
1365
- #<strong>components</strong> &#x21d2; <tt>Object</tt>
1366
-
1367
-
1368
-
1369
-
1370
-
1371
- </h3><div class="docstring">
1372
- <div class="discussion">
1373
- <p>Returns the value of attribute components</p>
1374
-
1375
-
1376
- </div>
1377
- </div>
1378
- <div class="tags">
1379
-
1380
-
1381
- </div><table class="source_code">
1382
- <tr>
1383
- <td>
1384
- <pre class="lines">
1385
-
1386
-
1387
- 32
1388
- 33
1389
- 34</pre>
1390
- </td>
1391
- <td>
1392
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 32</span>
1393
-
1394
- <span class='kw'>def</span> <span class='id identifier rubyid_components'>components</span>
1395
- <span class='ivar'>@components</span>
1396
- <span class='kw'>end</span></pre>
1397
- </td>
1398
- </tr>
1399
- </table>
1400
- </div>
1401
-
1402
- </div>
1403
-
1404
-
1405
- <div id="class_method_details" class="method_details_list">
1406
- <h2>Class Method Details</h2>
1407
-
1408
-
1409
- <div class="method_details first">
1410
- <h3 class="signature first" id="[]-class_method">
1411
-
1412
- .<strong>[]</strong>(path) &#x21d2; <tt>Object</tt>
1413
-
1414
-
1415
-
1416
-
1417
-
1418
- </h3><table class="source_code">
1419
- <tr>
1420
- <td>
1421
- <pre class="lines">
1422
-
1423
-
1424
- 78
1425
- 79
1426
- 80</pre>
1427
- </td>
1428
- <td>
1429
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 78</span>
1430
-
1431
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='op'>[]</span> <span class='id identifier rubyid_path'>path</span>
1432
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1433
- <span class='kw'>end</span></pre>
1434
- </td>
1435
- </tr>
1436
- </table>
1437
- </div>
1438
-
1439
- <div class="method_details ">
1440
- <h3 class="signature " id="create-class_method">
1441
-
1442
- .<strong>create</strong>(path) &#x21d2; <tt>Object</tt>
1443
-
1444
-
1445
-
1446
-
1447
-
1448
- </h3><table class="source_code">
1449
- <tr>
1450
- <td>
1451
- <pre class="lines">
1452
-
1453
-
1454
- 108
1455
- 109
1456
- 110
1457
- 111
1458
- 112
1459
- 113
1460
- 114
1461
- 115
1462
- 116
1463
- 117
1464
- 118
1465
- 119</pre>
1466
- </td>
1467
- <td>
1468
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 108</span>
1469
-
1470
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1471
- <span class='kw'>case</span> <span class='id identifier rubyid_path'>path</span>
1472
- <span class='kw'>when</span> <span class='const'><span class='object_link'><a href="" title="Utopia::Path (class)">Path</a></span></span>
1473
- <span class='kw'>return</span> <span class='id identifier rubyid_path'>path</span>
1474
- <span class='kw'>when</span> <span class='const'>Array</span>
1475
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1476
- <span class='kw'>when</span> <span class='const'>String</span>
1477
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_unescape'>unescape</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="#SEPARATOR-constant" title="Utopia::Path::SEPARATOR (constant)">SEPARATOR</a></span></span><span class='comma'>,</span> <span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rparen'>)</span>
1478
- <span class='kw'>else</span>
1479
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='id identifier rubyid_path'>path</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1480
- <span class='kw'>end</span>
1481
- <span class='kw'>end</span></pre>
1482
- </td>
1483
- </tr>
1484
- </table>
1485
- </div>
1486
-
1487
- <div class="method_details ">
1488
- <h3 class="signature " id="dump-class_method">
1489
-
1490
- .<strong>dump</strong>(instance) &#x21d2; <tt>Object</tt>
1491
-
1492
-
1493
-
1494
-
1495
-
1496
- </h3><table class="source_code">
1497
- <tr>
1498
- <td>
1499
- <pre class="lines">
1500
-
1501
-
1502
- 104
1503
- 105
1504
- 106</pre>
1505
- </td>
1506
- <td>
1507
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 104</span>
1508
-
1509
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_dump'>dump</span><span class='lparen'>(</span><span class='id identifier rubyid_instance'>instance</span><span class='rparen'>)</span>
1510
- <span class='id identifier rubyid_instance'>instance</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span> <span class='kw'>if</span> <span class='id identifier rubyid_instance'>instance</span>
1511
- <span class='kw'>end</span></pre>
1512
- </td>
1513
- </tr>
1514
- </table>
1515
- </div>
1516
-
1517
- <div class="method_details ">
1518
- <h3 class="signature " id="from_string-class_method">
1519
-
1520
- .<strong>from_string</strong>(string) &#x21d2; <tt>Object</tt>
1521
-
1522
-
1523
-
1524
-
1525
-
1526
- </h3><div class="docstring">
1527
- <div class="discussion">
1528
- <p>This constructor takes a string and generates a relative path as efficiently as possible. This is a direct entry point for all controller invocations so it’s designed to suit the requirements of that function.</p>
1529
-
1530
-
1531
- </div>
1532
- </div>
1533
- <div class="tags">
1534
-
1535
-
1536
- </div><table class="source_code">
1537
- <tr>
1538
- <td>
1539
- <pre class="lines">
1540
-
1541
-
1542
- 96
1543
- 97
1544
- 98</pre>
1545
- </td>
1546
- <td>
1547
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 96</span>
1548
-
1549
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_from_string'>from_string</span><span class='lparen'>(</span><span class='id identifier rubyid_string'>string</span><span class='rparen'>)</span>
1550
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_unescape'>unescape</span><span class='lparen'>(</span><span class='id identifier rubyid_string'>string</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="#SEPARATOR-constant" title="Utopia::Path::SEPARATOR (constant)">SEPARATOR</a></span></span><span class='comma'>,</span> <span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rparen'>)</span>
1551
- <span class='kw'>end</span></pre>
1552
- </td>
1553
- </tr>
1554
- </table>
1555
- </div>
1556
-
1557
- <div class="method_details ">
1558
- <h3 class="signature " id="load-class_method">
1559
-
1560
- .<strong>load</strong>(value) &#x21d2; <tt>Object</tt>
1561
-
1562
-
1563
-
1564
-
1565
-
1566
- </h3><table class="source_code">
1567
- <tr>
1568
- <td>
1569
- <pre class="lines">
1570
-
1571
-
1572
- 100
1573
- 101
1574
- 102</pre>
1575
- </td>
1576
- <td>
1577
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 100</span>
1578
-
1579
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_load'>load</span><span class='lparen'>(</span><span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
1580
- <span class='id identifier rubyid_from_string'>from_string</span><span class='lparen'>(</span><span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_value'>value</span>
1581
- <span class='kw'>end</span></pre>
1582
- </td>
1583
- </tr>
1584
- </table>
1585
- </div>
1586
-
1587
- <div class="method_details ">
1588
- <h3 class="signature " id="prefix_length-class_method">
1589
-
1590
- .<strong>prefix_length</strong>(a, b) &#x21d2; <tt>Object</tt>
1591
-
1592
-
1593
-
1594
-
1595
-
1596
- </h3><div class="docstring">
1597
- <div class="discussion">
1598
- <p>Returns the length of the prefix which is shared by two strings.</p>
1599
-
1600
-
1601
- </div>
1602
- </div>
1603
- <div class="tags">
1604
-
1605
-
1606
- </div><table class="source_code">
1607
- <tr>
1608
- <td>
1609
- <pre class="lines">
1610
-
1611
-
1612
- 49
1613
- 50
1614
- 51</pre>
1615
- </td>
1616
- <td>
1617
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 49</span>
1618
-
1619
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_prefix_length'>prefix_length</span><span class='lparen'>(</span><span class='id identifier rubyid_a'>a</span><span class='comma'>,</span> <span class='id identifier rubyid_b'>b</span><span class='rparen'>)</span>
1620
- <span class='lbracket'>[</span><span class='id identifier rubyid_a'>a</span><span class='period'>.</span><span class='id identifier rubyid_size'>size</span><span class='comma'>,</span> <span class='id identifier rubyid_b'>b</span><span class='period'>.</span><span class='id identifier rubyid_size'>size</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_min'>min</span><span class='period'>.</span><span class='id identifier rubyid_times'>times</span><span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_i'>i</span><span class='op'>|</span> <span class='kw'>return</span> <span class='id identifier rubyid_i'>i</span> <span class='kw'>if</span> <span class='id identifier rubyid_a'>a</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='rbracket'>]</span> <span class='op'>!=</span> <span class='id identifier rubyid_b'>b</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='rbracket'>]</span><span class='rbrace'>}</span>
1621
- <span class='kw'>end</span></pre>
1622
- </td>
1623
- </tr>
1624
- </table>
1625
- </div>
1626
-
1627
- <div class="method_details ">
1628
- <h3 class="signature " id="root-class_method">
1629
-
1630
- .<strong>root</strong> &#x21d2; <tt>Object</tt>
1631
-
1632
-
1633
-
1634
-
1635
-
1636
- </h3><table class="source_code">
1637
- <tr>
1638
- <td>
1639
- <pre class="lines">
1640
-
1641
-
1642
- 44
1643
- 45
1644
- 46</pre>
1645
- </td>
1646
- <td>
1647
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 44</span>
1648
-
1649
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span>
1650
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
1651
- <span class='kw'>end</span></pre>
1652
- </td>
1653
- </tr>
1654
- </table>
1655
- </div>
1656
-
1657
- <div class="method_details ">
1658
- <h3 class="signature " id="shortest_path-class_method">
1659
-
1660
- .<strong>shortest_path</strong>(path, root) &#x21d2; <tt>Object</tt>
1661
-
1662
-
1663
-
1664
-
1665
-
1666
- </h3><div class="docstring">
1667
- <div class="discussion">
1668
- <p>Return the shortest relative path to get to path from root:</p>
1669
-
1670
-
1671
- </div>
1672
- </div>
1673
- <div class="tags">
1674
-
1675
-
1676
- </div><table class="source_code">
1677
- <tr>
1678
- <td>
1679
- <pre class="lines">
1680
-
1681
-
1682
- 54
1683
- 55
1684
- 56
1685
- 57
1686
- 58
1687
- 59
1688
- 60
1689
- 61
1690
- 62
1691
- 63
1692
- 64
1693
- 65</pre>
1694
- </td>
1695
- <td>
1696
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 54</span>
1697
-
1698
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_shortest_path'>shortest_path</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='comma'>,</span> <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='rparen'>)</span>
1699
- <span class='id identifier rubyid_path'>path</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1700
- <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_dirname'>dirname</span>
1701
-
1702
- <span class='comment'># Find the common prefix:
1703
- </span> <span class='id identifier rubyid_i'>i</span> <span class='op'>=</span> <span class='id identifier rubyid_prefix_length'>prefix_length</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='comma'>,</span> <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='rparen'>)</span> <span class='op'>||</span> <span class='int'>0</span>
1704
-
1705
- <span class='comment'># The difference between the root path and the required path, taking into account the common prefix:
1706
- </span> <span class='id identifier rubyid_up'>up</span> <span class='op'>=</span> <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_size'>size</span> <span class='op'>-</span> <span class='id identifier rubyid_i'>i</span>
1707
-
1708
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>..</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>*</span> <span class='id identifier rubyid_up'>up</span> <span class='op'>+</span> <span class='id identifier rubyid_path'>path</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1709
- <span class='kw'>end</span></pre>
1710
- </td>
1711
- </tr>
1712
- </table>
1713
- </div>
1714
-
1715
- <div class="method_details ">
1716
- <h3 class="signature " id="split-class_method">
1717
-
1718
- .<strong>split</strong>(path) &#x21d2; <tt>Object</tt>
1719
-
1720
-
1721
-
1722
-
1723
-
1724
- </h3><table class="source_code">
1725
- <tr>
1726
- <td>
1727
- <pre class="lines">
1728
-
1729
-
1730
- 82
1731
- 83
1732
- 84
1733
- 85
1734
- 86
1735
- 87
1736
- 88
1737
- 89
1738
- 90
1739
- 91
1740
- 92
1741
- 93</pre>
1742
- </td>
1743
- <td>
1744
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 82</span>
1745
-
1746
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
1747
- <span class='kw'>case</span> <span class='id identifier rubyid_path'>path</span>
1748
- <span class='kw'>when</span> <span class='const'><span class='object_link'><a href="" title="Utopia::Path (class)">Path</a></span></span>
1749
- <span class='kw'>return</span> <span class='id identifier rubyid_path'>path</span><span class='period'>.</span><span class='id identifier rubyid_to_a'>to_a</span>
1750
- <span class='kw'>when</span> <span class='const'>Array</span>
1751
- <span class='kw'>return</span> <span class='id identifier rubyid_path'>path</span>
1752
- <span class='kw'>when</span> <span class='const'>String</span>
1753
- <span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to_a'>to_a</span>
1754
- <span class='kw'>else</span>
1755
- <span class='lbracket'>[</span><span class='id identifier rubyid_path'>path</span><span class='rbracket'>]</span>
1756
- <span class='kw'>end</span>
1757
- <span class='kw'>end</span></pre>
1758
- </td>
1759
- </tr>
1760
- </table>
1761
- </div>
1762
-
1763
- <div class="method_details ">
1764
- <h3 class="signature " id="unescape-class_method">
1765
-
1766
- .<strong>unescape</strong>(string) &#x21d2; <tt>Object</tt>
1767
-
1768
-
1769
-
1770
-
1771
-
1772
- </h3><div class="docstring">
1773
- <div class="discussion">
1774
- <p>Converts ‘+’ into whitespace and hex encoded characters into their equivalent characters.</p>
1775
-
1776
-
1777
- </div>
1778
- </div>
1779
- <div class="tags">
1780
-
1781
-
1782
- </div><table class="source_code">
1783
- <tr>
1784
- <td>
1785
- <pre class="lines">
1786
-
1787
-
1788
- 72
1789
- 73
1790
- 74
1791
- 75
1792
- 76</pre>
1793
- </td>
1794
- <td>
1795
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 72</span>
1796
-
1797
- <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_unescape'>unescape</span><span class='lparen'>(</span><span class='id identifier rubyid_string'>string</span><span class='rparen'>)</span>
1798
- <span class='id identifier rubyid_string'>string</span><span class='period'>.</span><span class='id identifier rubyid_tr'>tr</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>+</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'> </span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_gsub'>gsub</span><span class='lparen'>(</span><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>((?:%[0-9a-fA-F]{2})+)</span><span class='regexp_end'>/n</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span>
1799
- <span class='lbracket'>[</span><span class='backref'>$1</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>%</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_pack'>pack</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>H*</span><span class='tstring_end'>&#39;</span></span><span class='rparen'>)</span>
1800
- <span class='rbrace'>}</span>
1801
- <span class='kw'>end</span></pre>
1802
- </td>
1803
- </tr>
1804
- </table>
1805
- </div>
1806
-
1807
- </div>
1808
-
1809
- <div id="instance_method_details" class="method_details_list">
1810
- <h2>Instance Method Details</h2>
1811
-
1812
-
1813
- <div class="method_details first">
1814
- <h3 class="signature first" id="+-instance_method">
1815
-
1816
- #<strong>+</strong>(other) &#x21d2; <tt>Object</tt>
1817
-
1818
-
1819
-
1820
-
1821
-
1822
- </h3><table class="source_code">
1823
- <tr>
1824
- <td>
1825
- <pre class="lines">
1826
-
1827
-
1828
- 183
1829
- 184
1830
- 185
1831
- 186
1832
- 187
1833
- 188
1834
- 189
1835
- 190
1836
- 191
1837
- 192
1838
- 193
1839
- 194
1840
- 195
1841
- 196
1842
- 197</pre>
1843
- </td>
1844
- <td>
1845
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 183</span>
1846
-
1847
- <span class='kw'>def</span> <span class='op'>+</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span>
1848
- <span class='kw'>if</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_kind_of?'>kind_of?</span> <span class='const'><span class='object_link'><a href="" title="Utopia::Path (class)">Path</a></span></span>
1849
- <span class='kw'>if</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_absolute?'>absolute?</span>
1850
- <span class='kw'>return</span> <span class='id identifier rubyid_other'>other</span>
1851
- <span class='kw'>else</span>
1852
- <span class='kw'>return</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='rparen'>)</span>
1853
- <span class='kw'>end</span>
1854
- <span class='kw'>elsif</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_kind_of?'>kind_of?</span> <span class='const'>Array</span>
1855
- <span class='kw'>return</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span>
1856
- <span class='kw'>elsif</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_kind_of?'>kind_of?</span> <span class='const'>String</span>
1857
- <span class='kw'>return</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="#SEPARATOR-constant" title="Utopia::Path::SEPARATOR (constant)">SEPARATOR</a></span></span><span class='comma'>,</span> <span class='op'>-</span><span class='int'>1</span><span class='rparen'>)</span><span class='rparen'>)</span>
1858
- <span class='kw'>else</span>
1859
- <span class='kw'>return</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1860
- <span class='kw'>end</span>
1861
- <span class='kw'>end</span></pre>
1862
- </td>
1863
- </tr>
1864
- </table>
1865
- </div>
1866
-
1867
- <div class="method_details ">
1868
- <h3 class="signature " id="--instance_method">
1869
-
1870
- #<strong>-</strong>(other) &#x21d2; <tt>Object</tt>
1871
-
1872
-
1873
-
1874
-
1875
-
1876
- </h3><div class="docstring">
1877
- <div class="discussion">
1878
- <p>Computes the difference of the path.
1879
- /a/b/c - /a/b -&gt; c
1880
- a/b/c - a/b -&gt; c</p>
1881
-
1882
-
1883
- </div>
1884
- </div>
1885
- <div class="tags">
1886
-
1887
-
1888
- </div><table class="source_code">
1889
- <tr>
1890
- <td>
1891
- <pre class="lines">
1892
-
1893
-
1894
- 206
1895
- 207
1896
- 208
1897
- 209
1898
- 210
1899
- 211
1900
- 212
1901
- 213
1902
- 214
1903
- 215
1904
- 216</pre>
1905
- </td>
1906
- <td>
1907
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 206</span>
1908
-
1909
- <span class='kw'>def</span> <span class='op'>-</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span>
1910
- <span class='id identifier rubyid_i'>i</span> <span class='op'>=</span> <span class='int'>0</span>
1911
-
1912
- <span class='kw'>while</span> <span class='id identifier rubyid_i'>i</span> <span class='op'>&lt;</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_size'>size</span>
1913
- <span class='kw'>break</span> <span class='kw'>if</span> <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='rbracket'>]</span> <span class='op'>!=</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='rbracket'>]</span>
1914
-
1915
- <span class='id identifier rubyid_i'>i</span> <span class='op'>+=</span> <span class='int'>1</span>
1916
- <span class='kw'>end</span>
1917
-
1918
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_i'>i</span><span class='comma'>,</span><span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_size'>size</span><span class='rbracket'>]</span><span class='rparen'>)</span>
1919
- <span class='kw'>end</span></pre>
1920
- </td>
1921
- </tr>
1922
- </table>
1923
- </div>
1924
-
1925
- <div class="method_details ">
1926
- <h3 class="signature " id="<=>-instance_method">
1927
-
1928
- #<strong>&lt;=&gt;</strong>(other) &#x21d2; <tt>Object</tt>
1929
-
1930
-
1931
-
1932
-
1933
-
1934
- </h3><table class="source_code">
1935
- <tr>
1936
- <td>
1937
- <pre class="lines">
1938
-
1939
-
1940
- 296
1941
- 297
1942
- 298</pre>
1943
- </td>
1944
- <td>
1945
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 296</span>
1946
-
1947
- <span class='kw'>def</span> <span class='op'>&lt;=&gt;</span> <span class='id identifier rubyid_other'>other</span>
1948
- <span class='ivar'>@components</span> <span class='op'>&lt;=&gt;</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span>
1949
- <span class='kw'>end</span></pre>
1950
- </td>
1951
- </tr>
1952
- </table>
1953
- </div>
1954
-
1955
- <div class="method_details ">
1956
- <h3 class="signature " id="==-instance_method">
1957
-
1958
- #<strong>==</strong>(other) &#x21d2; <tt>Object</tt>
1959
-
1960
-
1961
-
1962
-
1963
-
1964
- </h3><table class="source_code">
1965
- <tr>
1966
- <td>
1967
- <pre class="lines">
1968
-
1969
-
1970
- 308
1971
- 309
1972
- 310
1973
- 311
1974
- 312
1975
- 313
1976
- 314
1977
- 315
1978
- 316</pre>
1979
- </td>
1980
- <td>
1981
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 308</span>
1982
-
1983
- <span class='kw'>def</span> <span class='op'>==</span> <span class='id identifier rubyid_other'>other</span>
1984
- <span class='kw'>return</span> <span class='kw'>false</span> <span class='kw'>unless</span> <span class='id identifier rubyid_other'>other</span>
1985
-
1986
- <span class='kw'>case</span> <span class='id identifier rubyid_other'>other</span>
1987
- <span class='kw'>when</span> <span class='const'>String</span> <span class='kw'>then</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span> <span class='op'>==</span> <span class='id identifier rubyid_other'>other</span>
1988
- <span class='kw'>when</span> <span class='const'>Array</span> <span class='kw'>then</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_to_a'>to_a</span> <span class='op'>==</span> <span class='id identifier rubyid_other'>other</span>
1989
- <span class='kw'>else</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='rparen'>)</span> <span class='op'>&amp;&amp;</span> <span class='ivar'>@components</span> <span class='op'>==</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span>
1990
- <span class='kw'>end</span>
1991
- <span class='kw'>end</span></pre>
1992
- </td>
1993
- </tr>
1994
- </table>
1995
- </div>
1996
-
1997
- <div class="method_details ">
1998
- <h3 class="signature " id="[]-instance_method">
1999
-
2000
- #<strong>[]</strong>(index) &#x21d2; <tt>Object</tt>
2001
-
2002
-
2003
-
2004
-
2005
-
2006
- </h3><table class="source_code">
2007
- <tr>
2008
- <td>
2009
- <pre class="lines">
2010
-
2011
-
2012
- 326
2013
- 327
2014
- 328</pre>
2015
- </td>
2016
- <td>
2017
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 326</span>
2018
-
2019
- <span class='kw'>def</span> <span class='op'>[]</span> <span class='id identifier rubyid_index'>index</span>
2020
- <span class='kw'>return</span> <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_component_offset'>component_offset</span><span class='lparen'>(</span><span class='id identifier rubyid_index'>index</span><span class='rparen'>)</span><span class='rbracket'>]</span>
2021
- <span class='kw'>end</span></pre>
2022
- </td>
2023
- </tr>
2024
- </table>
2025
- </div>
2026
-
2027
- <div class="method_details ">
2028
- <h3 class="signature " id="[]=-instance_method">
2029
-
2030
- #<strong>[]=</strong>(index, value) &#x21d2; <tt>Object</tt>
2031
-
2032
-
2033
-
2034
-
2035
-
2036
- </h3><div class="docstring">
2037
- <div class="discussion">
2038
- <p>Replaces a named component, indexing as per</p>
2039
-
2040
-
2041
- </div>
2042
- </div>
2043
- <div class="tags">
2044
-
2045
-
2046
- </div><table class="source_code">
2047
- <tr>
2048
- <td>
2049
- <pre class="lines">
2050
-
2051
-
2052
- 331
2053
- 332
2054
- 333</pre>
2055
- </td>
2056
- <td>
2057
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 331</span>
2058
-
2059
- <span class='kw'>def</span> <span class='op'>[]=</span> <span class='id identifier rubyid_index'>index</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span>
2060
- <span class='kw'>return</span> <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_component_offset'>component_offset</span><span class='lparen'>(</span><span class='id identifier rubyid_index'>index</span><span class='rparen'>)</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_value'>value</span>
2061
- <span class='kw'>end</span></pre>
2062
- </td>
2063
- </tr>
2064
- </table>
2065
- </div>
2066
-
2067
- <div class="method_details ">
2068
- <h3 class="signature " id="absolute?-instance_method">
2069
-
2070
- #<strong>absolute?</strong> &#x21d2; <tt>Boolean</tt>
2071
-
2072
-
2073
-
2074
-
2075
-
2076
- </h3><div class="docstring">
2077
- <div class="discussion">
2078
-
2079
-
2080
-
2081
- </div>
2082
- </div>
2083
- <div class="tags">
2084
-
2085
- <p class="tag_title">Returns:</p>
2086
- <ul class="return">
2087
-
2088
- <li>
2089
-
2090
-
2091
- <span class='type'>(<tt>Boolean</tt>)</span>
2092
-
2093
-
2094
-
2095
- </li>
2096
-
2097
- </ul>
2098
-
2099
- </div><table class="source_code">
2100
- <tr>
2101
- <td>
2102
- <pre class="lines">
2103
-
2104
-
2105
- 145
2106
- 146
2107
- 147</pre>
2108
- </td>
2109
- <td>
2110
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 145</span>
2111
-
2112
- <span class='kw'>def</span> <span class='id identifier rubyid_absolute?'>absolute?</span>
2113
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_first'>first</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span>
2114
- <span class='kw'>end</span></pre>
2115
- </td>
2116
- </tr>
2117
- </table>
2118
- </div>
2119
-
2120
- <div class="method_details ">
2121
- <h3 class="signature " id="ascend-instance_method">
2122
-
2123
- #<strong>ascend</strong>(&amp;block) &#x21d2; <tt>Object</tt>
2124
-
2125
-
2126
-
2127
-
2128
-
2129
- </h3><table class="source_code">
2130
- <tr>
2131
- <td>
2132
- <pre class="lines">
2133
-
2134
-
2135
- 268
2136
- 269
2137
- 270
2138
- 271
2139
- 272
2140
- 273
2141
- 274
2142
- 275
2143
- 276
2144
- 277
2145
- 278</pre>
2146
- </td>
2147
- <td>
2148
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 268</span>
2149
-
2150
- <span class='kw'>def</span> <span class='id identifier rubyid_ascend'>ascend</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
2151
- <span class='kw'>return</span> <span class='id identifier rubyid_to_enum'>to_enum</span><span class='lparen'>(</span><span class='symbol'>:ascend</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id identifier rubyid_block_given?'>block_given?</span>
2152
-
2153
- <span class='id identifier rubyid_components'>components</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
2154
-
2155
- <span class='kw'>while</span> <span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_any?'>any?</span>
2156
- <span class='kw'>yield</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span><span class='rparen'>)</span>
2157
-
2158
- <span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_pop'>pop</span>
2159
- <span class='kw'>end</span>
2160
- <span class='kw'>end</span></pre>
2161
- </td>
2162
- </tr>
2163
- </table>
2164
- </div>
2165
-
2166
- <div class="method_details ">
2167
- <h3 class="signature " id="basename-instance_method">
2168
-
2169
- #<strong>basename</strong> &#x21d2; <tt>Object</tt>
2170
-
2171
-
2172
-
2173
-
2174
-
2175
- </h3><table class="source_code">
2176
- <tr>
2177
- <td>
2178
- <pre class="lines">
2179
-
2180
-
2181
- 234
2182
- 235
2183
- 236
2184
- 237
2185
- 238</pre>
2186
- </td>
2187
- <td>
2188
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 234</span>
2189
-
2190
- <span class='kw'>def</span> <span class='id identifier rubyid_basename'>basename</span>
2191
- <span class='id identifier rubyid_basename'>basename</span><span class='comma'>,</span> <span class='id identifier rubyid__'>_</span> <span class='op'>=</span> <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>.</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='int'>2</span><span class='rparen'>)</span>
2192
-
2193
- <span class='kw'>return</span> <span class='id identifier rubyid_basename'>basename</span> <span class='op'>||</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span>
2194
- <span class='kw'>end</span></pre>
2195
- </td>
2196
- </tr>
2197
- </table>
2198
- </div>
2199
-
2200
- <div class="method_details ">
2201
- <h3 class="signature " id="delete_at-instance_method">
2202
-
2203
- #<strong>delete_at</strong>(index) &#x21d2; <tt>Object</tt>
2204
-
2205
-
2206
-
2207
-
2208
-
2209
- </h3><table class="source_code">
2210
- <tr>
2211
- <td>
2212
- <pre class="lines">
2213
-
2214
-
2215
- 335
2216
- 336
2217
- 337</pre>
2218
- </td>
2219
- <td>
2220
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 335</span>
2221
-
2222
- <span class='kw'>def</span> <span class='id identifier rubyid_delete_at'>delete_at</span><span class='lparen'>(</span><span class='id identifier rubyid_index'>index</span><span class='rparen'>)</span>
2223
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_delete_at'>delete_at</span><span class='lparen'>(</span><span class='id identifier rubyid_component_offset'>component_offset</span><span class='lparen'>(</span><span class='id identifier rubyid_index'>index</span><span class='rparen'>)</span><span class='rparen'>)</span>
2224
- <span class='kw'>end</span></pre>
2225
- </td>
2226
- </tr>
2227
- </table>
2228
- </div>
2229
-
2230
- <div class="method_details ">
2231
- <h3 class="signature " id="descend-instance_method">
2232
-
2233
- #<strong>descend</strong>(&amp;block) &#x21d2; <tt>Object</tt>
2234
-
2235
-
2236
-
2237
-
2238
-
2239
- </h3><table class="source_code">
2240
- <tr>
2241
- <td>
2242
- <pre class="lines">
2243
-
2244
-
2245
- 256
2246
- 257
2247
- 258
2248
- 259
2249
- 260
2250
- 261
2251
- 262
2252
- 263
2253
- 264
2254
- 265
2255
- 266</pre>
2256
- </td>
2257
- <td>
2258
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 256</span>
2259
-
2260
- <span class='kw'>def</span> <span class='id identifier rubyid_descend'>descend</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
2261
- <span class='kw'>return</span> <span class='id identifier rubyid_to_enum'>to_enum</span><span class='lparen'>(</span><span class='symbol'>:descend</span><span class='rparen'>)</span> <span class='kw'>unless</span> <span class='id identifier rubyid_block_given?'>block_given?</span>
2262
-
2263
- <span class='id identifier rubyid_components'>components</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
2264
-
2265
- <span class='ivar'>@components</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_component'>component</span><span class='op'>|</span>
2266
- <span class='id identifier rubyid_components'>components</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_component'>component</span>
2267
-
2268
- <span class='kw'>yield</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span><span class='rparen'>)</span>
2269
- <span class='kw'>end</span>
2270
- <span class='kw'>end</span></pre>
2271
- </td>
2272
- </tr>
2273
- </table>
2274
- </div>
2275
-
2276
- <div class="method_details ">
2277
- <h3 class="signature " id="directory?-instance_method">
2278
-
2279
- #<strong>directory?</strong> &#x21d2; <tt>Boolean</tt>
2280
-
2281
-
2282
-
2283
-
2284
-
2285
- </h3><div class="docstring">
2286
- <div class="discussion">
2287
-
2288
-
2289
-
2290
- </div>
2291
- </div>
2292
- <div class="tags">
2293
-
2294
- <p class="tag_title">Returns:</p>
2295
- <ul class="return">
2296
-
2297
- <li>
2298
-
2299
-
2300
- <span class='type'>(<tt>Boolean</tt>)</span>
2301
-
2302
-
2303
-
2304
- </li>
2305
-
2306
- </ul>
2307
-
2308
- </div><table class="source_code">
2309
- <tr>
2310
- <td>
2311
- <pre class="lines">
2312
-
2313
-
2314
- 129
2315
- 130
2316
- 131</pre>
2317
- </td>
2318
- <td>
2319
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 129</span>
2320
-
2321
- <span class='kw'>def</span> <span class='id identifier rubyid_directory?'>directory?</span>
2322
- <span class='kw'>return</span> <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span>
2323
- <span class='kw'>end</span></pre>
2324
- </td>
2325
- </tr>
2326
- </table>
2327
- </div>
2328
-
2329
- <div class="method_details ">
2330
- <h3 class="signature " id="dirname-instance_method">
2331
-
2332
- #<strong>dirname</strong>(count = 1) &#x21d2; <tt>Object</tt>
2333
-
2334
-
2335
-
2336
-
2337
-
2338
- </h3><table class="source_code">
2339
- <tr>
2340
- <td>
2341
- <pre class="lines">
2342
-
2343
-
2344
- 246
2345
- 247
2346
- 248
2347
- 249
2348
- 250</pre>
2349
- </td>
2350
- <td>
2351
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 246</span>
2352
-
2353
- <span class='kw'>def</span> <span class='id identifier rubyid_dirname'>dirname</span><span class='lparen'>(</span><span class='id identifier rubyid_count'>count</span> <span class='op'>=</span> <span class='int'>1</span><span class='rparen'>)</span>
2354
- <span class='id identifier rubyid_path'>path</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@components</span><span class='lbracket'>[</span><span class='int'>0</span><span class='op'>...</span><span class='op'>-</span><span class='id identifier rubyid_count'>count</span><span class='rbracket'>]</span><span class='rparen'>)</span>
2355
-
2356
- <span class='kw'>return</span> <span class='id identifier rubyid_absolute?'>absolute?</span> <span class='op'>?</span> <span class='id identifier rubyid_path'>path</span><span class='period'>.</span><span class='id identifier rubyid_to_absolute'>to_absolute</span> <span class='op'>:</span> <span class='id identifier rubyid_path'>path</span>
2357
- <span class='kw'>end</span></pre>
2358
- </td>
2359
- </tr>
2360
- </table>
2361
- </div>
2362
-
2363
- <div class="method_details ">
2364
- <h3 class="signature " id="dup-instance_method">
2365
-
2366
- #<strong>dup</strong> &#x21d2; <tt>Object</tt>
2367
-
2368
-
2369
-
2370
-
2371
-
2372
- </h3><table class="source_code">
2373
- <tr>
2374
- <td>
2375
- <pre class="lines">
2376
-
2377
-
2378
- 292
2379
- 293
2380
- 294</pre>
2381
- </td>
2382
- <td>
2383
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 292</span>
2384
-
2385
- <span class='kw'>def</span> <span class='id identifier rubyid_dup'>dup</span>
2386
- <span class='kw'>return</span> <span class='const'><span class='object_link'><a href="" title="Utopia::Path (class)">Path</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="#initialize-instance_method" title="Utopia::Path#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span><span class='rparen'>)</span>
2387
- <span class='kw'>end</span></pre>
2388
- </td>
2389
- </tr>
2390
- </table>
2391
- </div>
2392
-
2393
- <div class="method_details ">
2394
- <h3 class="signature " id="empty?-instance_method">
2395
-
2396
- #<strong>empty?</strong> &#x21d2; <tt>Boolean</tt>
2397
-
2398
-
2399
-
2400
-
2401
-
2402
- </h3><div class="docstring">
2403
- <div class="discussion">
2404
-
2405
-
2406
-
2407
- </div>
2408
- </div>
2409
- <div class="tags">
2410
-
2411
- <p class="tag_title">Returns:</p>
2412
- <ul class="return">
2413
-
2414
- <li>
2415
-
2416
-
2417
- <span class='type'>(<tt>Boolean</tt>)</span>
2418
-
2419
-
2420
-
2421
- </li>
2422
-
2423
- </ul>
2424
-
2425
- </div><table class="source_code">
2426
- <tr>
2427
- <td>
2428
- <pre class="lines">
2429
-
2430
-
2431
- 40
2432
- 41
2433
- 42</pre>
2434
- </td>
2435
- <td>
2436
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 40</span>
2437
-
2438
- <span class='kw'>def</span> <span class='id identifier rubyid_empty?'>empty?</span>
2439
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_empty?'>empty?</span>
2440
- <span class='kw'>end</span></pre>
2441
- </td>
2442
- </tr>
2443
- </table>
2444
- </div>
2445
-
2446
- <div class="method_details ">
2447
- <h3 class="signature " id="eql?-instance_method">
2448
-
2449
- #<strong>eql?</strong>(other) &#x21d2; <tt>Boolean</tt>
2450
-
2451
-
2452
-
2453
-
2454
-
2455
- </h3><div class="docstring">
2456
- <div class="discussion">
2457
-
2458
-
2459
-
2460
- </div>
2461
- </div>
2462
- <div class="tags">
2463
-
2464
- <p class="tag_title">Returns:</p>
2465
- <ul class="return">
2466
-
2467
- <li>
2468
-
2469
-
2470
- <span class='type'>(<tt>Boolean</tt>)</span>
2471
-
2472
-
2473
-
2474
- </li>
2475
-
2476
- </ul>
2477
-
2478
- </div><table class="source_code">
2479
- <tr>
2480
- <td>
2481
- <pre class="lines">
2482
-
2483
-
2484
- 300
2485
- 301
2486
- 302</pre>
2487
- </td>
2488
- <td>
2489
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 300</span>
2490
-
2491
- <span class='kw'>def</span> <span class='id identifier rubyid_eql?'>eql?</span> <span class='id identifier rubyid_other'>other</span>
2492
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_eql?'>eql?</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='rparen'>)</span> <span class='kw'>and</span> <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_eql?'>eql?</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='rparen'>)</span>
2493
- <span class='kw'>end</span></pre>
2494
- </td>
2495
- </tr>
2496
- </table>
2497
- </div>
2498
-
2499
- <div class="method_details ">
2500
- <h3 class="signature " id="expand-instance_method">
2501
-
2502
- #<strong>expand</strong>(root) &#x21d2; <tt>Object</tt>
2503
-
2504
-
2505
-
2506
-
2507
-
2508
- </h3><table class="source_code">
2509
- <tr>
2510
- <td>
2511
- <pre class="lines">
2512
-
2513
-
2514
- 179
2515
- 180
2516
- 181</pre>
2517
- </td>
2518
- <td>
2519
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 179</span>
2520
-
2521
- <span class='kw'>def</span> <span class='id identifier rubyid_expand'>expand</span><span class='lparen'>(</span><span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='rparen'>)</span>
2522
- <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span> <span class='op'>+</span> <span class='kw'>self</span>
2523
- <span class='kw'>end</span></pre>
2524
- </td>
2525
- </tr>
2526
- </table>
2527
- </div>
2528
-
2529
- <div class="method_details ">
2530
- <h3 class="signature " id="extension-instance_method">
2531
-
2532
- #<strong>extension</strong> &#x21d2; <tt>Object</tt>
2533
-
2534
-
2535
-
2536
-
2537
-
2538
- </h3><table class="source_code">
2539
- <tr>
2540
- <td>
2541
- <pre class="lines">
2542
-
2543
-
2544
- 240
2545
- 241
2546
- 242
2547
- 243
2548
- 244</pre>
2549
- </td>
2550
- <td>
2551
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 240</span>
2552
-
2553
- <span class='kw'>def</span> <span class='id identifier rubyid_extension'>extension</span>
2554
- <span class='id identifier rubyid__'>_</span><span class='comma'>,</span> <span class='id identifier rubyid_extension'>extension</span> <span class='op'>=</span> <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span><span class='period'>.</span><span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>.</span><span class='tstring_end'>&#39;</span></span><span class='comma'>,</span> <span class='int'>2</span><span class='rparen'>)</span>
2555
-
2556
- <span class='kw'>return</span> <span class='id identifier rubyid_extension'>extension</span>
2557
- <span class='kw'>end</span></pre>
2558
- </td>
2559
- </tr>
2560
- </table>
2561
- </div>
2562
-
2563
- <div class="method_details ">
2564
- <h3 class="signature " id="first-instance_method">
2565
-
2566
- #<strong>first</strong> &#x21d2; <tt>Object</tt>
2567
-
2568
-
2569
-
2570
-
2571
-
2572
- </h3><table class="source_code">
2573
- <tr>
2574
- <td>
2575
- <pre class="lines">
2576
-
2577
-
2578
- 339
2579
- 340
2580
- 341
2581
- 342
2582
- 343
2583
- 344
2584
- 345</pre>
2585
- </td>
2586
- <td>
2587
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 339</span>
2588
-
2589
- <span class='kw'>def</span> <span class='id identifier rubyid_first'>first</span>
2590
- <span class='kw'>if</span> <span class='id identifier rubyid_absolute?'>absolute?</span>
2591
- <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='int'>1</span><span class='rbracket'>]</span>
2592
- <span class='kw'>else</span>
2593
- <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='int'>0</span><span class='rbracket'>]</span>
2594
- <span class='kw'>end</span>
2595
- <span class='kw'>end</span></pre>
2596
- </td>
2597
- </tr>
2598
- </table>
2599
- </div>
2600
-
2601
- <div class="method_details ">
2602
- <h3 class="signature " id="freeze-instance_method">
2603
-
2604
- #<strong>freeze</strong> &#x21d2; <tt>Object</tt>
2605
-
2606
-
2607
-
2608
-
2609
-
2610
- </h3><table class="source_code">
2611
- <tr>
2612
- <td>
2613
- <pre class="lines">
2614
-
2615
-
2616
- 34
2617
- 35
2618
- 36
2619
- 37
2620
- 38</pre>
2621
- </td>
2622
- <td>
2623
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 34</span>
2624
-
2625
- <span class='kw'>def</span> <span class='id identifier rubyid_freeze'>freeze</span>
2626
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_freeze'>freeze</span>
2627
-
2628
- <span class='kw'>super</span>
2629
- <span class='kw'>end</span></pre>
2630
- </td>
2631
- </tr>
2632
- </table>
2633
- </div>
2634
-
2635
- <div class="method_details ">
2636
- <h3 class="signature " id="hash-instance_method">
2637
-
2638
- #<strong>hash</strong> &#x21d2; <tt>Object</tt>
2639
-
2640
-
2641
-
2642
-
2643
-
2644
- </h3><table class="source_code">
2645
- <tr>
2646
- <td>
2647
- <pre class="lines">
2648
-
2649
-
2650
- 304
2651
- 305
2652
- 306</pre>
2653
- </td>
2654
- <td>
2655
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 304</span>
2656
-
2657
- <span class='kw'>def</span> <span class='id identifier rubyid_hash'>hash</span>
2658
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_hash'>hash</span>
2659
- <span class='kw'>end</span></pre>
2660
- </td>
2661
- </tr>
2662
- </table>
2663
- </div>
2664
-
2665
- <div class="method_details ">
2666
- <h3 class="signature " id="include?-instance_method">
2667
-
2668
- #<strong>include?</strong>(*args) &#x21d2; <tt>Boolean</tt>
2669
-
2670
-
2671
-
2672
-
2673
-
2674
- </h3><div class="docstring">
2675
- <div class="discussion">
2676
-
2677
-
2678
-
2679
- </div>
2680
- </div>
2681
- <div class="tags">
2682
-
2683
- <p class="tag_title">Returns:</p>
2684
- <ul class="return">
2685
-
2686
- <li>
2687
-
2688
-
2689
- <span class='type'>(<tt>Boolean</tt>)</span>
2690
-
2691
-
2692
-
2693
- </li>
2694
-
2695
- </ul>
2696
-
2697
- </div><table class="source_code">
2698
- <tr>
2699
- <td>
2700
- <pre class="lines">
2701
-
2702
-
2703
- 125
2704
- 126
2705
- 127</pre>
2706
- </td>
2707
- <td>
2708
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 125</span>
2709
-
2710
- <span class='kw'>def</span> <span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
2711
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
2712
- <span class='kw'>end</span></pre>
2713
- </td>
2714
- </tr>
2715
- </table>
2716
- </div>
2717
-
2718
- <div class="method_details ">
2719
- <h3 class="signature " id="join-instance_method">
2720
-
2721
- #<strong>join</strong>(other) &#x21d2; <tt>Object</tt>
2722
-
2723
-
2724
-
2725
-
2726
-
2727
- </h3><table class="source_code">
2728
- <tr>
2729
- <td>
2730
- <pre class="lines">
2731
-
2732
-
2733
- 175
2734
- 176
2735
- 177</pre>
2736
- </td>
2737
- <td>
2738
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 175</span>
2739
-
2740
- <span class='kw'>def</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span>
2741
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@components</span> <span class='op'>+</span> <span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_simplify'>simplify</span>
2742
- <span class='kw'>end</span></pre>
2743
- </td>
2744
- </tr>
2745
- </table>
2746
- </div>
2747
-
2748
- <div class="method_details ">
2749
- <h3 class="signature " id="last-instance_method">
2750
-
2751
- #<strong>last</strong> &#x21d2; <tt>Object</tt>
2752
-
2753
-
2754
-
2755
-
2756
-
2757
- </h3><table class="source_code">
2758
- <tr>
2759
- <td>
2760
- <pre class="lines">
2761
-
2762
-
2763
- 347
2764
- 348
2765
- 349
2766
- 350
2767
- 351
2768
- 352
2769
- 353</pre>
2770
- </td>
2771
- <td>
2772
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 347</span>
2773
-
2774
- <span class='kw'>def</span> <span class='id identifier rubyid_last'>last</span>
2775
- <span class='kw'>if</span> <span class='id identifier rubyid_directory?'>directory?</span>
2776
- <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='op'>-</span><span class='int'>2</span><span class='rbracket'>]</span>
2777
- <span class='kw'>else</span>
2778
- <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='op'>-</span><span class='int'>1</span><span class='rbracket'>]</span>
2779
- <span class='kw'>end</span>
2780
- <span class='kw'>end</span></pre>
2781
- </td>
2782
- </tr>
2783
- </table>
2784
- </div>
2785
-
2786
- <div class="method_details ">
2787
- <h3 class="signature " id="relative?-instance_method">
2788
-
2789
- #<strong>relative?</strong> &#x21d2; <tt>Boolean</tt>
2790
-
2791
-
2792
-
2793
-
2794
-
2795
- </h3><div class="docstring">
2796
- <div class="discussion">
2797
-
2798
-
2799
-
2800
- </div>
2801
- </div>
2802
- <div class="tags">
2803
-
2804
- <p class="tag_title">Returns:</p>
2805
- <ul class="return">
2806
-
2807
- <li>
2808
-
2809
-
2810
- <span class='type'>(<tt>Boolean</tt>)</span>
2811
-
2812
-
2813
-
2814
- </li>
2815
-
2816
- </ul>
2817
-
2818
- </div><table class="source_code">
2819
- <tr>
2820
- <td>
2821
- <pre class="lines">
2822
-
2823
-
2824
- 141
2825
- 142
2826
- 143</pre>
2827
- </td>
2828
- <td>
2829
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 141</span>
2830
-
2831
- <span class='kw'>def</span> <span class='id identifier rubyid_relative?'>relative?</span>
2832
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_first'>first</span> <span class='op'>!=</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span>
2833
- <span class='kw'>end</span></pre>
2834
- </td>
2835
- </tr>
2836
- </table>
2837
- </div>
2838
-
2839
- <div class="method_details ">
2840
- <h3 class="signature " id="replace-instance_method">
2841
-
2842
- #<strong>replace</strong>(other_path) &#x21d2; <tt>Object</tt>
2843
-
2844
-
2845
-
2846
-
2847
-
2848
- </h3><table class="source_code">
2849
- <tr>
2850
- <td>
2851
- <pre class="lines">
2852
-
2853
-
2854
- 121
2855
- 122
2856
- 123</pre>
2857
- </td>
2858
- <td>
2859
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 121</span>
2860
-
2861
- <span class='kw'>def</span> <span class='id identifier rubyid_replace'>replace</span><span class='lparen'>(</span><span class='id identifier rubyid_other_path'>other_path</span><span class='rparen'>)</span>
2862
- <span class='ivar'>@components</span> <span class='op'>=</span> <span class='id identifier rubyid_other_path'>other_path</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
2863
- <span class='kw'>end</span></pre>
2864
- </td>
2865
- </tr>
2866
- </table>
2867
- </div>
2868
-
2869
- <div class="method_details ">
2870
- <h3 class="signature " id="shortest_path-instance_method">
2871
-
2872
- #<strong>shortest_path</strong>(root) &#x21d2; <tt>Object</tt>
2873
-
2874
-
2875
-
2876
-
2877
-
2878
- </h3><table class="source_code">
2879
- <tr>
2880
- <td>
2881
- <pre class="lines">
2882
-
2883
-
2884
- 67
2885
- 68
2886
- 69</pre>
2887
- </td>
2888
- <td>
2889
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 67</span>
2890
-
2891
- <span class='kw'>def</span> <span class='id identifier rubyid_shortest_path'>shortest_path</span><span class='lparen'>(</span><span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='rparen'>)</span>
2892
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_shortest_path'>shortest_path</span><span class='lparen'>(</span><span class='kw'>self</span><span class='comma'>,</span> <span class='id identifier rubyid_root'><span class='object_link'><a href="../top-level-namespace.html" title="Top Level Namespace (root)">root</a></span></span><span class='rparen'>)</span>
2893
- <span class='kw'>end</span></pre>
2894
- </td>
2895
- </tr>
2896
- </table>
2897
- </div>
2898
-
2899
- <div class="method_details ">
2900
- <h3 class="signature " id="simplify-instance_method">
2901
-
2902
- #<strong>simplify</strong> &#x21d2; <tt>Object</tt>
2903
-
2904
-
2905
-
2906
-
2907
-
2908
- </h3><table class="source_code">
2909
- <tr>
2910
- <td>
2911
- <pre class="lines">
2912
-
2913
-
2914
- 218
2915
- 219
2916
- 220
2917
- 221
2918
- 222
2919
- 223
2920
- 224
2921
- 225
2922
- 226
2923
- 227
2924
- 228
2925
- 229
2926
- 230
2927
- 231
2928
- 232</pre>
2929
- </td>
2930
- <td>
2931
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 218</span>
2932
-
2933
- <span class='kw'>def</span> <span class='id identifier rubyid_simplify'>simplify</span>
2934
- <span class='id identifier rubyid_result'>result</span> <span class='op'>=</span> <span class='id identifier rubyid_absolute?'>absolute?</span> <span class='op'>?</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span> <span class='op'>:</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
2935
-
2936
- <span class='ivar'>@components</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_bit'>bit</span><span class='op'>|</span>
2937
- <span class='kw'>if</span> <span class='id identifier rubyid_bit'>bit</span> <span class='op'>==</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>..</span><span class='tstring_end'>&quot;</span></span>
2938
- <span class='id identifier rubyid_result'>result</span><span class='period'>.</span><span class='id identifier rubyid_pop'>pop</span>
2939
- <span class='kw'>elsif</span> <span class='id identifier rubyid_bit'>bit</span> <span class='op'>!=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>.</span><span class='tstring_end'>&quot;</span></span> <span class='op'>&amp;&amp;</span> <span class='id identifier rubyid_bit'>bit</span> <span class='op'>!=</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span>
2940
- <span class='id identifier rubyid_result'>result</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_bit'>bit</span>
2941
- <span class='kw'>end</span>
2942
- <span class='kw'>end</span>
2943
-
2944
- <span class='id identifier rubyid_result'>result</span> <span class='op'>&lt;&lt;</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>if</span> <span class='id identifier rubyid_directory?'>directory?</span>
2945
-
2946
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_result'>result</span><span class='rparen'>)</span>
2947
- <span class='kw'>end</span></pre>
2948
- </td>
2949
- </tr>
2950
- </table>
2951
- </div>
2952
-
2953
- <div class="method_details ">
2954
- <h3 class="signature " id="split-instance_method">
2955
-
2956
- #<strong>split</strong>(at) &#x21d2; <tt>Object</tt>
2957
-
2958
-
2959
-
2960
-
2961
-
2962
- </h3><table class="source_code">
2963
- <tr>
2964
- <td>
2965
- <pre class="lines">
2966
-
2967
-
2968
- 280
2969
- 281
2970
- 282
2971
- 283
2972
- 284
2973
- 285
2974
- 286
2975
- 287
2976
- 288
2977
- 289
2978
- 290</pre>
2979
- </td>
2980
- <td>
2981
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 280</span>
2982
-
2983
- <span class='kw'>def</span> <span class='id identifier rubyid_split'>split</span><span class='lparen'>(</span><span class='id identifier rubyid_at'>at</span><span class='rparen'>)</span>
2984
- <span class='kw'>if</span> <span class='id identifier rubyid_at'>at</span><span class='period'>.</span><span class='id identifier rubyid_kind_of?'>kind_of?</span> <span class='const'>String</span>
2985
- <span class='id identifier rubyid_at'>at</span> <span class='op'>=</span> <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_index'>index</span><span class='lparen'>(</span><span class='id identifier rubyid_at'>at</span><span class='rparen'>)</span>
2986
- <span class='kw'>end</span>
2987
-
2988
- <span class='kw'>if</span> <span class='id identifier rubyid_at'>at</span>
2989
- <span class='kw'>return</span> <span class='lbracket'>[</span><span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@components</span><span class='lbracket'>[</span><span class='int'>0</span><span class='op'>...</span><span class='id identifier rubyid_at'>at</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='comma'>,</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_at'>at</span><span class='op'>+</span><span class='int'>1</span><span class='op'>..</span><span class='op'>-</span><span class='int'>1</span><span class='rbracket'>]</span><span class='rparen'>)</span><span class='rbracket'>]</span>
2990
- <span class='kw'>else</span>
2991
- <span class='kw'>return</span> <span class='kw'>nil</span>
2992
- <span class='kw'>end</span>
2993
- <span class='kw'>end</span></pre>
2994
- </td>
2995
- </tr>
2996
- </table>
2997
- </div>
2998
-
2999
- <div class="method_details ">
3000
- <h3 class="signature " id="start_with?-instance_method">
3001
-
3002
- #<strong>start_with?</strong>(other) &#x21d2; <tt>Boolean</tt>
3003
-
3004
-
3005
-
3006
-
3007
-
3008
- </h3><div class="docstring">
3009
- <div class="discussion">
3010
-
3011
-
3012
-
3013
- </div>
3014
- </div>
3015
- <div class="tags">
3016
-
3017
- <p class="tag_title">Returns:</p>
3018
- <ul class="return">
3019
-
3020
- <li>
3021
-
3022
-
3023
- <span class='type'>(<tt>Boolean</tt>)</span>
3024
-
3025
-
3026
-
3027
- </li>
3028
-
3029
- </ul>
3030
-
3031
- </div><table class="source_code">
3032
- <tr>
3033
- <td>
3034
- <pre class="lines">
3035
-
3036
-
3037
- 318
3038
- 319
3039
- 320
3040
- 321
3041
- 322
3042
- 323
3043
- 324</pre>
3044
- </td>
3045
- <td>
3046
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 318</span>
3047
-
3048
- <span class='kw'>def</span> <span class='id identifier rubyid_start_with?'>start_with?</span> <span class='id identifier rubyid_other'>other</span>
3049
- <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_components'>components</span><span class='period'>.</span><span class='id identifier rubyid_each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_part'>part</span><span class='comma'>,</span> <span class='id identifier rubyid_index'>index</span><span class='op'>|</span>
3050
- <span class='kw'>return</span> <span class='kw'>false</span> <span class='kw'>if</span> <span class='ivar'>@components</span><span class='lbracket'>[</span><span class='id identifier rubyid_index'>index</span><span class='rbracket'>]</span> <span class='op'>!=</span> <span class='id identifier rubyid_part'>part</span>
3051
- <span class='kw'>end</span>
3052
-
3053
- <span class='kw'>return</span> <span class='kw'>true</span>
3054
- <span class='kw'>end</span></pre>
3055
- </td>
3056
- </tr>
3057
- </table>
3058
- </div>
3059
-
3060
- <div class="method_details ">
3061
- <h3 class="signature " id="to_a-instance_method">
3062
-
3063
- #<strong>to_a</strong> &#x21d2; <tt>Object</tt>
3064
-
3065
-
3066
-
3067
-
3068
-
3069
- </h3><table class="source_code">
3070
- <tr>
3071
- <td>
3072
- <pre class="lines">
3073
-
3074
-
3075
- 171
3076
- 172
3077
- 173</pre>
3078
- </td>
3079
- <td>
3080
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 171</span>
3081
-
3082
- <span class='kw'>def</span> <span class='id identifier rubyid_to_a'>to_a</span>
3083
- <span class='ivar'>@components</span>
3084
- <span class='kw'>end</span></pre>
3085
- </td>
3086
- </tr>
3087
- </table>
3088
- </div>
3089
-
3090
- <div class="method_details ">
3091
- <h3 class="signature " id="to_absolute-instance_method">
3092
-
3093
- #<strong>to_absolute</strong> &#x21d2; <tt>Object</tt>
3094
-
3095
-
3096
-
3097
-
3098
-
3099
- </h3><table class="source_code">
3100
- <tr>
3101
- <td>
3102
- <pre class="lines">
3103
-
3104
-
3105
- 149
3106
- 150
3107
- 151
3108
- 152
3109
- 153
3110
- 154
3111
- 155</pre>
3112
- </td>
3113
- <td>
3114
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 149</span>
3115
-
3116
- <span class='kw'>def</span> <span class='id identifier rubyid_to_absolute'>to_absolute</span>
3117
- <span class='kw'>if</span> <span class='id identifier rubyid_absolute?'>absolute?</span>
3118
- <span class='kw'>return</span> <span class='kw'>self</span>
3119
- <span class='kw'>else</span>
3120
- <span class='kw'>return</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span> <span class='op'>+</span> <span class='ivar'>@components</span><span class='rparen'>)</span>
3121
- <span class='kw'>end</span>
3122
- <span class='kw'>end</span></pre>
3123
- </td>
3124
- </tr>
3125
- </table>
3126
- </div>
3127
-
3128
- <div class="method_details ">
3129
- <h3 class="signature " id="to_directory-instance_method">
3130
-
3131
- #<strong>to_directory</strong> &#x21d2; <tt>Object</tt>
3132
-
3133
-
3134
-
3135
-
3136
-
3137
- </h3><table class="source_code">
3138
- <tr>
3139
- <td>
3140
- <pre class="lines">
3141
-
3142
-
3143
- 133
3144
- 134
3145
- 135
3146
- 136
3147
- 137
3148
- 138
3149
- 139</pre>
3150
- </td>
3151
- <td>
3152
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 133</span>
3153
-
3154
- <span class='kw'>def</span> <span class='id identifier rubyid_to_directory'>to_directory</span>
3155
- <span class='kw'>if</span> <span class='id identifier rubyid_directory?'>directory?</span>
3156
- <span class='kw'>return</span> <span class='kw'>self</span>
3157
- <span class='kw'>else</span>
3158
- <span class='kw'>return</span> <span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
3159
- <span class='kw'>end</span>
3160
- <span class='kw'>end</span></pre>
3161
- </td>
3162
- </tr>
3163
- </table>
3164
- </div>
3165
-
3166
- <div class="method_details ">
3167
- <h3 class="signature " id="to_local_path-instance_method">
3168
-
3169
- #<strong>to_local_path</strong>(separator = File::SEPARATOR) &#x21d2; <tt>Object</tt>
3170
-
3171
-
3172
-
3173
-
3174
-
3175
- </h3><table class="source_code">
3176
- <tr>
3177
- <td>
3178
- <pre class="lines">
3179
-
3180
-
3181
- 252
3182
- 253
3183
- 254</pre>
3184
- </td>
3185
- <td>
3186
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 252</span>
3187
-
3188
- <span class='kw'>def</span> <span class='id identifier rubyid_to_local_path'>to_local_path</span><span class='lparen'>(</span><span class='id identifier rubyid_separator'>separator</span> <span class='op'>=</span> <span class='const'>File</span><span class='op'>::</span><span class='const'>SEPARATOR</span><span class='rparen'>)</span>
3189
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='id identifier rubyid_separator'>separator</span><span class='rparen'>)</span>
3190
- <span class='kw'>end</span></pre>
3191
- </td>
3192
- </tr>
3193
- </table>
3194
- </div>
3195
-
3196
- <div class="method_details ">
3197
- <h3 class="signature " id="to_relative!-instance_method">
3198
-
3199
- #<strong>to_relative!</strong> &#x21d2; <tt>Object</tt>
3200
-
3201
-
3202
-
3203
-
3204
-
3205
- </h3><table class="source_code">
3206
- <tr>
3207
- <td>
3208
- <pre class="lines">
3209
-
3210
-
3211
- 157
3212
- 158
3213
- 159</pre>
3214
- </td>
3215
- <td>
3216
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 157</span>
3217
-
3218
- <span class='kw'>def</span> <span class='id identifier rubyid_to_relative!'>to_relative!</span>
3219
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span> <span class='kw'>if</span> <span class='id identifier rubyid_relative?'>relative?</span>
3220
- <span class='kw'>end</span></pre>
3221
- </td>
3222
- </tr>
3223
- </table>
3224
- </div>
3225
-
3226
- <div class="method_details ">
3227
- <h3 class="signature " id="to_str-instance_method">
3228
-
3229
- #<strong>to_str</strong> &#x21d2; <tt>Object</tt>
3230
-
3231
-
3232
-
3233
- <span class="aliases">Also known as:
3234
- <span class="names"><span id='to_s-instance_method'>to_s</span></span>
3235
- </span>
3236
-
3237
-
3238
-
3239
- </h3><table class="source_code">
3240
- <tr>
3241
- <td>
3242
- <pre class="lines">
3243
-
3244
-
3245
- 161
3246
- 162
3247
- 163
3248
- 164
3249
- 165
3250
- 166
3251
- 167</pre>
3252
- </td>
3253
- <td>
3254
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 161</span>
3255
-
3256
- <span class='kw'>def</span> <span class='id identifier rubyid_to_str'>to_str</span>
3257
- <span class='kw'>if</span> <span class='ivar'>@components</span> <span class='op'>==</span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span>
3258
- <span class='const'><span class='object_link'><a href="#SEPARATOR-constant" title="Utopia::Path::SEPARATOR (constant)">SEPARATOR</a></span></span>
3259
- <span class='kw'>else</span>
3260
- <span class='ivar'>@components</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="#SEPARATOR-constant" title="Utopia::Path::SEPARATOR (constant)">SEPARATOR</a></span></span><span class='rparen'>)</span>
3261
- <span class='kw'>end</span>
3262
- <span class='kw'>end</span></pre>
3263
- </td>
3264
- </tr>
3265
- </table>
3266
- </div>
3267
-
3268
- <div class="method_details ">
3269
- <h3 class="signature " id="with_prefix-instance_method">
3270
-
3271
- #<strong>with_prefix</strong>(*args) &#x21d2; <tt>Object</tt>
3272
-
3273
-
3274
-
3275
-
3276
-
3277
- </h3><table class="source_code">
3278
- <tr>
3279
- <td>
3280
- <pre class="lines">
3281
-
3282
-
3283
- 199
3284
- 200
3285
- 201</pre>
3286
- </td>
3287
- <td>
3288
- <pre class="code"><span class="info file"># File 'lib/utopia/path.rb', line 199</span>
3289
-
3290
- <span class='kw'>def</span> <span class='id identifier rubyid_with_prefix'>with_prefix</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
3291
- <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_class'>class</span><span class='period'>.</span><span class='id identifier rubyid_create'>create</span><span class='lparen'>(</span><span class='op'>*</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span> <span class='op'>+</span> <span class='kw'>self</span>
3292
- <span class='kw'>end</span></pre>
3293
- </td>
3294
- </tr>
3295
- </table>
3296
- </div>
3297
-
3298
- </div>
3299
-
3300
- </div>
3301
-
3302
- <div id="footer">
3303
- Generated on Sat Mar 9 12:01:52 2019 by
3304
- <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
3305
- 0.9.18 (ruby-2.6.1).
3306
- </div>
3307
-
3308
- </div>
3309
- </body>
3310
- </html>