facets 2.4.2 → 2.4.3
Sign up to get free protection for your applications and to get access to all the features.
- data/AUTHORS +1 -1
- data/CHANGES +25 -5
- data/MANIFEST +67 -34
- data/METADATA +2 -2
- data/NEWS +54 -46
- data/doc/news/NEWS-2.4.0 +52 -0
- data/doc/rdoc/core/classes/Array.html +198 -198
- data/doc/rdoc/core/classes/Binding.html +86 -192
- data/doc/rdoc/core/classes/Class.html +136 -136
- data/doc/rdoc/core/classes/Comparable.html +45 -45
- data/doc/rdoc/core/classes/Dir.html +64 -64
- data/doc/rdoc/core/classes/Enumerable.html +287 -281
- data/doc/rdoc/core/classes/Exception.html +16 -16
- data/doc/rdoc/core/classes/FalseClass.html +8 -8
- data/doc/rdoc/core/classes/File.html +100 -100
- data/doc/rdoc/core/classes/FileTest.html +8 -8
- data/doc/rdoc/core/classes/Float.html +32 -32
- data/doc/rdoc/core/classes/Friend.html +8 -8
- data/doc/rdoc/core/classes/Functor.html +12 -12
- data/doc/rdoc/core/classes/Hash.html +439 -847
- data/doc/rdoc/{more → core}/classes/Indexable.html +115 -115
- data/doc/rdoc/core/classes/InstanceVariables.html +88 -88
- data/doc/rdoc/core/classes/Integer.html +142 -142
- data/doc/rdoc/core/classes/Kernel.html +602 -600
- data/doc/rdoc/core/classes/Lazy/Promise.html +1 -1
- data/doc/rdoc/core/classes/MatchData.html +30 -30
- data/doc/rdoc/core/classes/Module.html +379 -327
- data/doc/rdoc/core/classes/NilClass.html +32 -32
- data/doc/rdoc/core/classes/Numeric.html +46 -46
- data/doc/rdoc/core/classes/Object.html +4 -4
- data/doc/rdoc/core/classes/Proc.html +46 -134
- data/doc/rdoc/core/classes/Range.html +60 -60
- data/doc/rdoc/core/classes/Regexp.html +28 -28
- data/doc/rdoc/{more → core}/classes/Stackable.html +38 -38
- data/doc/rdoc/core/classes/String.html +844 -504
- data/doc/rdoc/core/classes/Symbol.html +62 -62
- data/doc/rdoc/core/classes/Time.html +112 -112
- data/doc/rdoc/core/classes/TrueClass.html +8 -8
- data/doc/rdoc/core/classes/UnboundMethod.html +22 -22
- data/doc/rdoc/core/created.rid +1 -1
- data/doc/rdoc/core/files/lib/core/facets/array_rb.html +4 -1
- data/doc/rdoc/core/files/lib/core/facets/binding_rb.html +1 -1
- data/doc/rdoc/core/files/lib/core/facets/boolean_rb.html +2 -2
- data/doc/rdoc/core/files/lib/core/facets/class/methodize_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/class/pathize_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/class_rb.html +5 -1
- data/doc/rdoc/core/files/lib/core/facets/dir_rb.html +1 -1
- data/doc/rdoc/core/files/lib/core/facets/{class/to_methodname_rb.html → enumerable/commonality_rb.html} +4 -4
- data/doc/rdoc/core/files/lib/core/facets/enumerable/entropy_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/{class/to_pathname_rb.html → enumerable/frequency_rb.html} +4 -4
- data/doc/rdoc/core/files/lib/core/facets/enumerable/probability_rb.html +1 -1
- data/doc/rdoc/core/files/lib/core/facets/enumerable_rb.html +6 -2
- data/doc/rdoc/core/files/lib/core/facets/file_rb.html +2 -1
- data/doc/rdoc/core/files/lib/core/facets/hash_rb.html +7 -1
- data/doc/rdoc/{more/files/lib/more → core/files/lib/core}/facets/indexable_rb.html +2 -2
- data/doc/rdoc/core/files/lib/core/facets/kernel/require_all_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/kernel/require_local_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/kernel_rb.html +15 -2
- data/doc/rdoc/core/files/lib/core/facets/module/integrate_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/module/methodize_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/module/module_load_rb.html +1 -1
- data/doc/rdoc/core/files/lib/core/facets/module/pathize_rb.html +5 -1
- data/doc/rdoc/core/files/lib/core/facets/module/redefine_method_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/module/redirect_method_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/module/rename_method_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/module/revise_rb.html +8 -1
- data/doc/rdoc/core/files/lib/core/facets/module/wrap_method_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/module_rb.html +8 -5
- data/doc/rdoc/core/files/lib/core/facets/numeric_rb.html +2 -1
- data/doc/rdoc/core/files/lib/core/facets/proc_rb.html +3 -5
- data/doc/rdoc/{more/files/lib/more → core/files/lib/core}/facets/stackable_rb.html +3 -4
- data/doc/rdoc/core/files/lib/core/facets/string/each_word_rb.html +96 -0
- data/doc/rdoc/core/files/lib/core/facets/{module/clone_rb.html → string/methodize_rb.html} +4 -4
- data/doc/rdoc/core/files/lib/core/facets/{kernel/load_rb.html → string/pathize_rb.html} +4 -4
- data/doc/rdoc/core/files/lib/core/facets/string/word_wrap_rb.html +92 -0
- data/doc/rdoc/core/files/lib/core/facets/string/words_rb.html +1 -5
- data/doc/rdoc/core/files/lib/core/facets/string_rb.html +8 -3
- data/doc/rdoc/core/files/lib/core/facets/symbol_rb.html +2 -1
- data/doc/rdoc/core/fr_class_index.html +2 -3
- data/doc/rdoc/core/fr_file_index.html +36 -16
- data/doc/rdoc/core/fr_method_index.html +778 -784
- data/doc/rdoc/lore/created.rid +1 -1
- data/doc/rdoc/more/classes/ANSICode.html +66 -66
- data/doc/rdoc/more/classes/Advisable.html +37 -37
- data/doc/rdoc/more/classes/Advisable/Method.html +20 -20
- data/doc/rdoc/more/classes/Archive/Tar/Minitar.html +27 -27
- data/doc/rdoc/more/classes/Archive/Tar/Minitar/Input.html +28 -28
- data/doc/rdoc/more/classes/Archive/Tar/Minitar/Output.html +19 -19
- data/doc/rdoc/more/classes/Archive/Tar/Minitar/Reader.html +31 -31
- data/doc/rdoc/more/classes/Archive/Tar/Minitar/Writer.html +33 -33
- data/doc/rdoc/more/classes/Association.html +28 -28
- data/doc/rdoc/more/classes/Association/Kernel.html +8 -8
- data/doc/rdoc/more/classes/Autoarray.html +12 -12
- data/doc/rdoc/more/classes/BBCode.html +34 -34
- data/doc/rdoc/more/classes/BaseX.html +16 -16
- data/doc/rdoc/more/classes/BiCrypt.html +67 -67
- data/doc/rdoc/more/classes/BigDuration.html +30 -30
- data/doc/rdoc/more/classes/BinReadable.html +85 -85
- data/doc/rdoc/more/classes/BinReadable/ByteOrder.html +25 -25
- data/doc/rdoc/more/classes/Binding.html +201 -0
- data/doc/rdoc/more/classes/Buildable.html +4 -4
- data/doc/rdoc/more/classes/BuildingBlock.html +32 -32
- data/doc/rdoc/more/classes/CLI.html +108 -0
- data/doc/rdoc/more/classes/CLI/Arguments.html +76 -76
- data/doc/rdoc/more/classes/CLI/Command.html +22 -22
- data/doc/rdoc/more/classes/CLI/NoCommandError.html +4 -4
- data/doc/rdoc/more/classes/CLI/NoOptionError.html +4 -4
- data/doc/rdoc/more/classes/CacheDecorator.html +21 -21
- data/doc/rdoc/more/classes/Capsule.html +41 -41
- data/doc/rdoc/more/classes/Chain.html +17 -17
- data/doc/rdoc/more/classes/Cloneable.html +4 -4
- data/doc/rdoc/more/classes/ConsoleUtils.html +18 -18
- data/doc/rdoc/more/classes/Coroutine.html +28 -28
- data/doc/rdoc/more/classes/Crypt.html +16 -16
- data/doc/rdoc/more/classes/CssFilter.html +45 -45
- data/doc/rdoc/more/classes/CssTree.html +8 -8
- data/doc/rdoc/more/classes/Dictionary.html +228 -228
- data/doc/rdoc/more/classes/DictionaryMatcher.html +38 -38
- data/doc/rdoc/more/classes/DictionaryMatcher/MatchData.html +4 -4
- data/doc/rdoc/more/classes/Downloader.html +56 -56
- data/doc/rdoc/more/classes/Duration.html +68 -68
- data/doc/rdoc/more/classes/Enumerable.html +44 -44
- data/doc/rdoc/more/classes/Enumerable/Elementor.html +16 -16
- data/doc/rdoc/more/classes/Enumerable/Enumerator.html +4 -4
- data/doc/rdoc/more/classes/EnumerablePass.html +15 -15
- data/doc/rdoc/more/classes/Equatable.html +16 -16
- data/doc/rdoc/more/classes/EventHook.html +8 -8
- data/doc/rdoc/more/classes/Expirable.html +17 -17
- data/doc/rdoc/more/classes/FileList.html +125 -125
- data/doc/rdoc/more/classes/FileShell.html +147 -147
- data/doc/rdoc/more/classes/Fileable.html +14 -14
- data/doc/rdoc/more/classes/Fileable/DSL.html +41 -41
- data/doc/rdoc/more/classes/Hash.html +306 -14
- data/doc/rdoc/more/classes/Hash2Xml.html +4 -4
- data/doc/rdoc/more/classes/HtmlFilter.html +9 -9
- data/doc/rdoc/more/classes/IORedirect.html +19 -19
- data/doc/rdoc/more/classes/InfinityClass.html +36 -36
- data/doc/rdoc/more/classes/InfinityClass/Numeric.html +23 -23
- data/doc/rdoc/more/classes/Ini.html +37 -37
- data/doc/rdoc/more/classes/Instantiable.html +9 -9
- data/doc/rdoc/more/classes/Instantise.html +8 -8
- data/doc/rdoc/more/classes/Interval.html +187 -187
- data/doc/rdoc/more/classes/It.html +12 -12
- data/doc/rdoc/more/classes/Kernel.html +77 -77
- data/doc/rdoc/more/classes/LRUCache.html +38 -38
- data/doc/rdoc/more/classes/LinkedList.html +68 -68
- data/doc/rdoc/more/classes/LinkedList/Node.html +4 -4
- data/doc/rdoc/{core → more}/classes/MissingArgument.html +1 -2
- data/doc/rdoc/more/classes/Module.html +171 -171
- data/doc/rdoc/more/classes/Multiton.html +12 -12
- data/doc/rdoc/more/classes/Multiton/MetaMethods.html +28 -28
- data/doc/rdoc/more/classes/Net/SMTP.html +19 -19
- data/doc/rdoc/more/classes/NullClass.html +24 -24
- data/doc/rdoc/more/classes/ObjectReflection.html +12 -12
- data/doc/rdoc/more/classes/OpEsc.html +5 -5
- data/doc/rdoc/more/classes/OpenCascade.html +4 -4
- data/doc/rdoc/more/classes/OpenCollection.html +8 -8
- data/doc/rdoc/more/classes/OpenHash.html +9 -9
- data/doc/rdoc/more/classes/OpenObject.html +95 -95
- data/doc/rdoc/more/classes/PQueue.html +84 -84
- data/doc/rdoc/more/classes/Paramix.html +11 -11
- data/doc/rdoc/more/classes/Paramix/Delegator.html +16 -16
- data/doc/rdoc/more/classes/PathList.html +8 -8
- data/doc/rdoc/more/classes/PathList/Finder.html +8 -8
- data/doc/rdoc/more/classes/Platform.html +46 -46
- data/doc/rdoc/more/classes/Pool.html +18 -18
- data/doc/rdoc/more/classes/Proc.html +48 -4
- data/doc/rdoc/more/classes/ProgressBar.html +52 -52
- data/doc/rdoc/more/classes/Prototype.html +28 -28
- data/doc/rdoc/more/classes/RWDelegator.html +16 -16
- data/doc/rdoc/more/classes/Random.html +9 -9
- data/doc/rdoc/more/classes/Random/Array.html +37 -37
- data/doc/rdoc/more/classes/Random/Hash.html +52 -52
- data/doc/rdoc/more/classes/Random/Object.html +4 -4
- data/doc/rdoc/more/classes/Random/String.html +34 -34
- data/doc/rdoc/more/classes/Random/String/Self.html +9 -9
- data/doc/rdoc/more/classes/Recorder.html +16 -16
- data/doc/rdoc/more/classes/Reference.html +19 -19
- data/doc/rdoc/more/classes/Registerable.html +13 -13
- data/doc/rdoc/more/classes/Semaphore.html +36 -36
- data/doc/rdoc/more/classes/Settings.html +28 -28
- data/doc/rdoc/more/classes/Settings/Setting.html +13 -13
- data/doc/rdoc/more/classes/Settings/SettingCollection.html +4 -4
- data/doc/rdoc/more/classes/SimpleStringIO.html +8 -8
- data/doc/rdoc/more/classes/Snapshot.html +16 -16
- data/doc/rdoc/more/classes/Snapshot/ValueHolder.html +12 -12
- data/doc/rdoc/more/classes/String/Style.html +113 -113
- data/doc/rdoc/{core → more}/classes/String/Words.html +78 -78
- data/doc/rdoc/more/classes/Struct.html +8 -8
- data/doc/rdoc/more/classes/SyncArray.html +4 -4
- data/doc/rdoc/more/classes/SyncHash.html +4 -4
- data/doc/rdoc/more/classes/SyncHash/Delegator.html +28 -28
- data/doc/rdoc/more/classes/SyncHash/Inheritor.html +28 -28
- data/doc/rdoc/more/classes/System.html +253 -253
- data/doc/rdoc/more/classes/Timer.html +48 -48
- data/doc/rdoc/more/classes/Timer/Dummy.html +9 -9
- data/doc/rdoc/more/classes/TracePoint.html +64 -62
- data/doc/rdoc/more/classes/Tuple.html +170 -170
- data/doc/rdoc/more/classes/TypeCast/Class.html +4 -4
- data/doc/rdoc/more/classes/TypeCast/Object.html +4 -4
- data/doc/rdoc/more/classes/Uninheritable.html +6 -6
- data/doc/rdoc/more/classes/UploadUtils.html +49 -49
- data/doc/rdoc/more/classes/VersionNumber.html +53 -53
- data/doc/rdoc/more/classes/Weekdays.html +28 -28
- data/doc/rdoc/more/classes/XOXO.html +9 -9
- data/doc/rdoc/more/classes/ZipUtils.html +58 -58
- data/doc/rdoc/more/classes/ZipUtils/DryRun.html +28 -28
- data/doc/rdoc/more/classes/ZipUtils/NoWrite.html +28 -28
- data/doc/rdoc/more/classes/ZipUtils/Verbose.html +28 -28
- data/doc/rdoc/more/created.rid +1 -1
- data/doc/rdoc/more/files/lib/more/facets/ansicode_rb.html +1 -1
- data/doc/rdoc/{core/files/lib/core → more/files/lib/more}/facets/binding/opvars_rb.html +2 -2
- data/doc/rdoc/{core/files/lib/core → more/files/lib/more}/facets/hash/stringify_keys_rb.html +2 -2
- data/doc/rdoc/{core/files/lib/core → more/files/lib/more}/facets/hash/symbolize_keys_rb.html +2 -2
- data/doc/rdoc/{core/files/lib/core/facets/proc → more/files/lib/more/facets}/partial_rb.html +8 -7
- data/doc/rdoc/more/files/lib/more/facets/snapshot_rb.html +2 -2
- data/doc/rdoc/more/files/lib/more/facets/string/words_rb.html +96 -0
- data/doc/rdoc/more/files/lib/more/facets/tracepoint_rb.html +13 -8
- data/doc/rdoc/more/fr_class_index.html +4 -2
- data/doc/rdoc/more/fr_file_index.html +9 -2
- data/doc/rdoc/more/fr_method_index.html +1013 -1009
- data/doc/ri/CLI/cdesc-CLI.yaml +7 -2
- data/doc/ri/Enumerable/probability-i.yaml +1 -1
- data/doc/ri/Module/append_features-i.yaml +4 -3
- data/doc/ri/Module/cdesc-Module.yaml +4 -3
- data/doc/ri/Module/methodize-i.yaml +14 -0
- data/doc/ri/Module/redefine_method-i.yaml +1 -1
- data/doc/ri/Module/redirect_method-i.yaml +3 -1
- data/doc/ri/Module/rename_method-i.yaml +1 -1
- data/doc/ri/created.rid +1 -1
- data/lib/core/facets/array.rb +3 -0
- data/lib/core/facets/binding.rb +0 -1
- data/lib/core/facets/class.rb +4 -4
- data/lib/core/facets/class/{to_methodname.rb → methodize.rb} +5 -2
- data/lib/core/facets/class/pathize.rb +14 -0
- data/lib/core/facets/enumerable.rb +5 -2
- data/lib/core/facets/enumerable/commonality.rb +33 -0
- data/lib/core/facets/enumerable/entropy.rb +37 -0
- data/lib/core/facets/enumerable/frequency.rb +18 -0
- data/lib/core/facets/enumerable/probability.rb +1 -98
- data/lib/core/facets/file.rb +1 -1
- data/lib/core/facets/hash.rb +6 -0
- data/lib/{more → core}/facets/indexable.rb +0 -0
- data/lib/core/facets/kernel.rb +15 -1
- data/lib/core/facets/kernel/require_all.rb +21 -0
- data/lib/core/facets/kernel/{load.rb → require_local.rb} +6 -23
- data/lib/core/facets/module.rb +7 -3
- data/lib/core/facets/module/integrate.rb +2 -0
- data/lib/core/facets/module/methodize.rb +14 -0
- data/lib/core/facets/module/pathize.rb +10 -7
- data/lib/core/facets/module/redefine_method.rb +35 -0
- data/lib/core/facets/module/redirect_method.rb +45 -0
- data/lib/core/facets/module/rename_method.rb +20 -0
- data/lib/core/facets/module/revise.rb +7 -113
- data/lib/core/facets/module/wrap_method.rb +28 -0
- data/lib/core/facets/numeric.rb +1 -1
- data/lib/core/facets/proc.rb +2 -3
- data/lib/{more → core}/facets/stackable.rb +0 -0
- data/lib/core/facets/string.rb +8 -6
- data/lib/core/facets/string/each_word.rb +13 -0
- data/lib/core/facets/string/methodize.rb +12 -0
- data/lib/core/facets/string/pathize.rb +12 -0
- data/lib/core/facets/string/word_wrap.rb +34 -0
- data/lib/core/facets/string/words.rb +6 -167
- data/lib/core/facets/symbol.rb +1 -0
- data/lib/more/facets/ansicode.rb +4 -4
- data/lib/{core → more}/facets/binding/opvars.rb +0 -0
- data/lib/{core → more}/facets/hash/stringify_keys.rb +0 -0
- data/lib/{core → more}/facets/hash/symbolize_keys.rb +5 -6
- data/lib/{core/facets/proc → more/facets}/partial.rb +0 -0
- data/lib/more/facets/string/words.rb +173 -0
- data/test/core/dir/test_multiglob.rb +1 -0
- data/test/core/dir/test_recurse.rb +1 -0
- data/test/core/enumerable/test_commonality.rb +15 -0
- data/test/core/enumerable/test_entropy.rb +15 -0
- data/test/core/enumerable/test_frequency.rb +11 -0
- data/test/core/enumerable/test_probability.rb +1 -34
- data/test/core/string/test_each_word.rb +14 -0
- data/test/core/string/test_fold.rb +1 -1
- data/test/core/string/test_word_wrap.rb +35 -0
- data/test/core/string/test_words.rb +12 -61
- data/test/more/test_command.rb +7 -9
- data/test/more/test_paramix.rb +4 -1
- data/test/{core/proc → more}/test_partial.rb +1 -1
- metadata +75 -38
- data/doc/rdoc/core/classes/Module/CloneExtensions.html +0 -287
- data/doc/ri/Module/CloneExtensions/cdesc-CloneExtensions.yaml +0 -20
- data/doc/ri/Module/CloneExtensions/clone_removing-i.yaml +0 -14
- data/doc/ri/Module/CloneExtensions/clone_renaming-i.yaml +0 -14
- data/doc/ri/Module/CloneExtensions/clone_using-i.yaml +0 -14
- data/lib/core/facets/class/to_pathname.rb +0 -12
- data/lib/core/facets/module/clone.rb +0 -57
- data/test/core/module/test_clone.rb +0 -45
@@ -82,9 +82,9 @@ Object
|
|
82
82
|
|
83
83
|
<div class="sectiontitle">Methods</div>
|
84
84
|
<ul>
|
85
|
-
<li><a href="#
|
86
|
-
<li><a href="#
|
87
|
-
<li><a href="#
|
85
|
+
<li><a href="#M000481">first?</a></li>
|
86
|
+
<li><a href="#M000482">last?</a></li>
|
87
|
+
<li><a href="#M000480">new</a></li>
|
88
88
|
</ul>
|
89
89
|
|
90
90
|
|
@@ -126,11 +126,11 @@ Object
|
|
126
126
|
<div class="sectiontitle">Public Class methods</div>
|
127
127
|
<div class="method">
|
128
128
|
<div class="title">
|
129
|
-
<a name="
|
129
|
+
<a name="M000480"></a><b>new</b>(array)
|
130
130
|
</div>
|
131
131
|
<div class="sourcecode">
|
132
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
133
|
-
<div id="
|
132
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000480_source')" id="l_M000480_source">show source</a> ]</p>
|
133
|
+
<div id="M000480_source" class="dyn-source">
|
134
134
|
<pre>
|
135
135
|
<span class="ruby-comment cmt"># File lib/more/facets/iteration.rb, line 7</span>
|
136
136
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">array</span>)
|
@@ -147,11 +147,11 @@ Object
|
|
147
147
|
<div class="sectiontitle">Public Instance methods</div>
|
148
148
|
<div class="method">
|
149
149
|
<div class="title">
|
150
|
-
<a name="
|
150
|
+
<a name="M000481"></a><b>first?</b>()
|
151
151
|
</div>
|
152
152
|
<div class="sourcecode">
|
153
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
154
|
-
<div id="
|
153
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000481_source')" id="l_M000481_source">show source</a> ]</p>
|
154
|
+
<div id="M000481_source" class="dyn-source">
|
155
155
|
<pre>
|
156
156
|
<span class="ruby-comment cmt"># File lib/more/facets/iteration.rb, line 14</span>
|
157
157
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">first?</span> ; <span class="ruby-ivar">@index</span> <span class="ruby-operator">==</span> <span class="ruby-value">0</span> ; <span class="ruby-keyword kw">end</span>
|
@@ -161,11 +161,11 @@ Object
|
|
161
161
|
</div>
|
162
162
|
<div class="method">
|
163
163
|
<div class="title">
|
164
|
-
<a name="
|
164
|
+
<a name="M000482"></a><b>last?</b>()
|
165
165
|
</div>
|
166
166
|
<div class="sourcecode">
|
167
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
168
|
-
<div id="
|
167
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000482_source')" id="l_M000482_source">show source</a> ]</p>
|
168
|
+
<div id="M000482_source" class="dyn-source">
|
169
169
|
<pre>
|
170
170
|
<span class="ruby-comment cmt"># File lib/more/facets/iteration.rb, line 15</span>
|
171
171
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">last?</span>
|
@@ -88,24 +88,24 @@
|
|
88
88
|
|
89
89
|
<div class="sectiontitle">Methods</div>
|
90
90
|
<ul>
|
91
|
-
<li><a href="#
|
92
|
-
<li><a href="#
|
93
|
-
<li><a href="#
|
94
|
-
<li><a href="#
|
95
|
-
<li><a href="#
|
96
|
-
<li><a href="#
|
97
|
-
<li><a href="#
|
98
|
-
<li><a href="#
|
99
|
-
<li><a href="#
|
100
|
-
<li><a href="#
|
101
|
-
<li><a href="#
|
102
|
-
<li><a href="#
|
103
|
-
<li><a href="#
|
104
|
-
<li><a href="#
|
105
|
-
<li><a href="#
|
106
|
-
<li><a href="#
|
107
|
-
<li><a href="#
|
108
|
-
<li><a href="#
|
91
|
+
<li><a href="#M000929">__object__</a></li>
|
92
|
+
<li><a href="#M000940">autoimport</a></li>
|
93
|
+
<li><a href="#M000932">autoreload</a></li>
|
94
|
+
<li><a href="#M000933">autoreload_files</a></li>
|
95
|
+
<li><a href="#M000927">cache</a></li>
|
96
|
+
<li><a href="#M000931">chain</a></li>
|
97
|
+
<li><a href="#M000928">daemonize</a></li>
|
98
|
+
<li><a href="#M000942">event</a></li>
|
99
|
+
<li><a href="#M000941">hook</a></li>
|
100
|
+
<li><a href="#M000935">meta</a></li>
|
101
|
+
<li><a href="#M000936">meta</a></li>
|
102
|
+
<li><a href="#M000939">method!</a></li>
|
103
|
+
<li><a href="#M000943">nack</a></li>
|
104
|
+
<li><a href="#M000938">new</a></li>
|
105
|
+
<li><a href="#M000930">null</a></li>
|
106
|
+
<li><a href="#M000937">prototype</a></li>
|
107
|
+
<li><a href="#M000934">ref</a></li>
|
108
|
+
<li><a href="#M000944">timed</a></li>
|
109
109
|
</ul>
|
110
110
|
|
111
111
|
|
@@ -116,7 +116,7 @@
|
|
116
116
|
<div class="sectiontitle">Public Instance methods</div>
|
117
117
|
<div class="method">
|
118
118
|
<div class="title">
|
119
|
-
<a name="
|
119
|
+
<a name="M000929"></a><b>__object__</b>()
|
120
120
|
</div>
|
121
121
|
<div class="description">
|
122
122
|
<p>
|
@@ -132,8 +132,8 @@ For metaprogramming this can be important.
|
|
132
132
|
</p>
|
133
133
|
</div>
|
134
134
|
<div class="sourcecode">
|
135
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
136
|
-
<div id="
|
135
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000929_source')" id="l_M000929_source">show source</a> ]</p>
|
136
|
+
<div id="M000929_source" class="dyn-source">
|
137
137
|
<pre>
|
138
138
|
<span class="ruby-comment cmt"># File lib/more/facets/reflection.rb, line 92</span>
|
139
139
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">__object__</span>
|
@@ -145,7 +145,7 @@ For metaprogramming this can be important.
|
|
145
145
|
</div>
|
146
146
|
<div class="method">
|
147
147
|
<div class="title">
|
148
|
-
<a name="
|
148
|
+
<a name="M000940"></a><b>autoimport</b>(mod, file)
|
149
149
|
</div>
|
150
150
|
<div class="description">
|
151
151
|
<p>
|
@@ -153,8 +153,8 @@ Calls Object.autoimport
|
|
153
153
|
</p>
|
154
154
|
</div>
|
155
155
|
<div class="sourcecode">
|
156
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
157
|
-
<div id="
|
156
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000940_source')" id="l_M000940_source">show source</a> ]</p>
|
157
|
+
<div id="M000940_source" class="dyn-source">
|
158
158
|
<pre>
|
159
159
|
<span class="ruby-comment cmt"># File lib/more/facets/capsule.rb, line 254</span>
|
160
160
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">autoimport</span>(<span class="ruby-identifier">mod</span>, <span class="ruby-identifier">file</span>)
|
@@ -166,7 +166,7 @@ Calls Object.autoimport
|
|
166
166
|
</div>
|
167
167
|
<div class="method">
|
168
168
|
<div class="title">
|
169
|
-
<a name="
|
169
|
+
<a name="M000932"></a><b>autoreload</b>( *args )
|
170
170
|
</div>
|
171
171
|
<div class="description">
|
172
172
|
<p>
|
@@ -184,8 +184,8 @@ specified files. Also keeps a "dirty" flag.
|
|
184
184
|
</p>
|
185
185
|
</div>
|
186
186
|
<div class="sourcecode">
|
187
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
188
|
-
<div id="
|
187
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000932_source')" id="l_M000932_source">show source</a> ]</p>
|
188
|
+
<div id="M000932_source" class="dyn-source">
|
189
189
|
<pre>
|
190
190
|
<span class="ruby-comment cmt"># File lib/more/facets/autoreload.rb, line 50</span>
|
191
191
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">autoreload</span>( <span class="ruby-operator">*</span><span class="ruby-identifier">args</span> )
|
@@ -252,19 +252,19 @@ specified files. Also keeps a "dirty" flag.
|
|
252
252
|
</div>
|
253
253
|
<div class="method">
|
254
254
|
<div class="title">
|
255
|
-
<a name="
|
255
|
+
<a name="M000933"></a><b>autoreload_files</b>( *args )
|
256
256
|
</div>
|
257
257
|
<div class="description">
|
258
258
|
<p>
|
259
|
-
Same as <a href="Kernel.html#
|
259
|
+
Same as <a href="Kernel.html#M000932">autoreload</a>, but does not include
|
260
260
|
previously loaded features. This is equivalent to as adding a
|
261
261
|
‘false’ parameter to <a
|
262
|
-
href="Kernel.html#
|
262
|
+
href="Kernel.html#M000932">autoreload</a>.
|
263
263
|
</p>
|
264
264
|
</div>
|
265
265
|
<div class="sourcecode">
|
266
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
267
|
-
<div id="
|
266
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000933_source')" id="l_M000933_source">show source</a> ]</p>
|
267
|
+
<div id="M000933_source" class="dyn-source">
|
268
268
|
<pre>
|
269
269
|
<span class="ruby-comment cmt"># File lib/more/facets/autoreload.rb, line 112</span>
|
270
270
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">autoreload_files</span>( <span class="ruby-operator">*</span><span class="ruby-identifier">args</span> )
|
@@ -276,20 +276,20 @@ href="Kernel.html#M000928">autoreload</a>.
|
|
276
276
|
</div>
|
277
277
|
<div class="method">
|
278
278
|
<div class="title">
|
279
|
-
<a name="
|
279
|
+
<a name="M000927"></a><b>cache</b>(m = nil)
|
280
280
|
</div>
|
281
281
|
<div class="description">
|
282
282
|
<p>
|
283
283
|
Object#cache is essentially like <a
|
284
|
-
href="Module.html#
|
284
|
+
href="Module.html#M000348">Module#memoize</a> except it can also be used on
|
285
285
|
singleton/eigen methods. OTOH, memoize‘s implementation is arguably
|
286
286
|
better for it‘s use of bind instead of alias. Eventually the two
|
287
287
|
implmenations will be reconciled with a single implmentation.
|
288
288
|
</p>
|
289
289
|
</div>
|
290
290
|
<div class="sourcecode">
|
291
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
292
|
-
<div id="
|
291
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000927_source')" id="l_M000927_source">show source</a> ]</p>
|
292
|
+
<div id="M000927_source" class="dyn-source">
|
293
293
|
<pre>
|
294
294
|
<span class="ruby-comment cmt"># File lib/more/facets/memoize.rb, line 97</span>
|
295
295
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">cache</span> <span class="ruby-identifier">m</span> = <span class="ruby-keyword kw">nil</span>
|
@@ -304,11 +304,11 @@ implmenations will be reconciled with a single implmentation.
|
|
304
304
|
</div>
|
305
305
|
<div class="method">
|
306
306
|
<div class="title">
|
307
|
-
<a name="
|
307
|
+
<a name="M000931"></a><b>chain</b>()
|
308
308
|
</div>
|
309
309
|
<div class="sourcecode">
|
310
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
311
|
-
<div id="
|
310
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000931_source')" id="l_M000931_source">show source</a> ]</p>
|
311
|
+
<div id="M000931_source" class="dyn-source">
|
312
312
|
<pre>
|
313
313
|
<span class="ruby-comment cmt"># File lib/more/facets/chain.rb, line 54</span>
|
314
314
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">chain</span>
|
@@ -320,7 +320,7 @@ implmenations will be reconciled with a single implmentation.
|
|
320
320
|
</div>
|
321
321
|
<div class="method">
|
322
322
|
<div class="title">
|
323
|
-
<a name="
|
323
|
+
<a name="M000928"></a><b>daemonize</b>()
|
324
324
|
</div>
|
325
325
|
<div class="description">
|
326
326
|
<p>
|
@@ -329,8 +329,8 @@ console. <a href="It.html">It</a> can be shut down with a TERM signal.
|
|
329
329
|
</p>
|
330
330
|
</div>
|
331
331
|
<div class="sourcecode">
|
332
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
333
|
-
<div id="
|
332
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000928_source')" id="l_M000928_source">show source</a> ]</p>
|
333
|
+
<div id="M000928_source" class="dyn-source">
|
334
334
|
<pre>
|
335
335
|
<span class="ruby-comment cmt"># File lib/more/facets/daemonize.rb, line 31</span>
|
336
336
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">daemonize</span>
|
@@ -350,11 +350,11 @@ console. <a href="It.html">It</a> can be shut down with a TERM signal.
|
|
350
350
|
</div>
|
351
351
|
<div class="method">
|
352
352
|
<div class="title">
|
353
|
-
<a name="
|
353
|
+
<a name="M000942"></a><b>event</b>(sym) {|| ...}
|
354
354
|
</div>
|
355
355
|
<div class="sourcecode">
|
356
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
357
|
-
<div id="
|
356
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000942_source')" id="l_M000942_source">show source</a> ]</p>
|
357
|
+
<div id="M000942_source" class="dyn-source">
|
358
358
|
<pre>
|
359
359
|
<span class="ruby-comment cmt"># File lib/more/facets/eventhook.rb, line 84</span>
|
360
360
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">event</span>(<span class="ruby-identifier">sym</span>)
|
@@ -369,11 +369,11 @@ console. <a href="It.html">It</a> can be shut down with a TERM signal.
|
|
369
369
|
</div>
|
370
370
|
<div class="method">
|
371
371
|
<div class="title">
|
372
|
-
<a name="
|
372
|
+
<a name="M000941"></a><b>hook</b>(sym)
|
373
373
|
</div>
|
374
374
|
<div class="sourcecode">
|
375
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
376
|
-
<div id="
|
375
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000941_source')" id="l_M000941_source">show source</a> ]</p>
|
376
|
+
<div id="M000941_source" class="dyn-source">
|
377
377
|
<pre>
|
378
378
|
<span class="ruby-comment cmt"># File lib/more/facets/eventhook.rb, line 81</span>
|
379
379
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">hook</span>(<span class="ruby-identifier">sym</span>)
|
@@ -385,7 +385,7 @@ console. <a href="It.html">It</a> can be shut down with a TERM signal.
|
|
385
385
|
</div>
|
386
386
|
<div class="method">
|
387
387
|
<div class="title">
|
388
|
-
<a name="
|
388
|
+
<a name="M000935"></a><b>meta</b>()
|
389
389
|
</div>
|
390
390
|
<div class="description">
|
391
391
|
<p>
|
@@ -415,8 +415,8 @@ is a conflict with URI prior to 1.8.6, so it will have to wait.
|
|
415
415
|
</pre>
|
416
416
|
</div>
|
417
417
|
<div class="sourcecode">
|
418
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
419
|
-
<div id="
|
418
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000935_source')" id="l_M000935_source">show source</a> ]</p>
|
419
|
+
<div id="M000935_source" class="dyn-source">
|
420
420
|
<pre>
|
421
421
|
<span class="ruby-comment cmt"># File lib/more/facets/kernel/meta.rb, line 25</span>
|
422
422
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">meta</span>
|
@@ -430,7 +430,7 @@ is a conflict with URI prior to 1.8.6, so it will have to wait.
|
|
430
430
|
</div>
|
431
431
|
<div class="method">
|
432
432
|
<div class="title">
|
433
|
-
<a name="
|
433
|
+
<a name="M000936"></a><b>meta</b>()
|
434
434
|
</div>
|
435
435
|
<div class="description">
|
436
436
|
<p>
|
@@ -460,8 +460,8 @@ is a conflict with URI prior to 1.8.6, so it will have to wait.
|
|
460
460
|
</pre>
|
461
461
|
</div>
|
462
462
|
<div class="sourcecode">
|
463
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
464
|
-
<div id="
|
463
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000936_source')" id="l_M000936_source">show source</a> ]</p>
|
464
|
+
<div id="M000936_source" class="dyn-source">
|
465
465
|
<pre>
|
466
466
|
<span class="ruby-comment cmt"># File lib/more/facets/kernel/meta.rb, line 25</span>
|
467
467
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">meta</span>
|
@@ -475,7 +475,7 @@ is a conflict with URI prior to 1.8.6, so it will have to wait.
|
|
475
475
|
</div>
|
476
476
|
<div class="method">
|
477
477
|
<div class="title">
|
478
|
-
<a name="
|
478
|
+
<a name="M000939"></a><b>method!</b>(s)
|
479
479
|
</div>
|
480
480
|
<div class="description">
|
481
481
|
<p>
|
@@ -497,8 +497,8 @@ Easy access to method as objects, and they retain state!
|
|
497
497
|
</pre>
|
498
498
|
</div>
|
499
499
|
<div class="sourcecode">
|
500
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
501
|
-
<div id="
|
500
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000939_source')" id="l_M000939_source">show source</a> ]</p>
|
501
|
+
<div id="M000939_source" class="dyn-source">
|
502
502
|
<pre>
|
503
503
|
<span class="ruby-comment cmt"># File lib/more/facets/1stclassmethod.rb, line 94</span>
|
504
504
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">method!</span>(<span class="ruby-identifier">s</span>)
|
@@ -510,7 +510,7 @@ Easy access to method as objects, and they retain state!
|
|
510
510
|
</div>
|
511
511
|
<div class="method">
|
512
512
|
<div class="title">
|
513
|
-
<a name="
|
513
|
+
<a name="M000943"></a><b>nack</b>()
|
514
514
|
</div>
|
515
515
|
<div class="description">
|
516
516
|
<p>
|
@@ -519,8 +519,8 @@ for minor usecases. See mega/nack for a complete version.
|
|
519
519
|
</p>
|
520
520
|
</div>
|
521
521
|
<div class="sourcecode">
|
522
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
523
|
-
<div id="
|
522
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000943_source')" id="l_M000943_source">show source</a> ]</p>
|
523
|
+
<div id="M000943_source" class="dyn-source">
|
524
524
|
<pre>
|
525
525
|
<span class="ruby-comment cmt"># File lib/more/facets/nackclass.rb, line 38</span>
|
526
526
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">nack</span>
|
@@ -532,22 +532,22 @@ for minor usecases. See mega/nack for a complete version.
|
|
532
532
|
</div>
|
533
533
|
<div class="method">
|
534
534
|
<div class="title">
|
535
|
-
<a name="
|
535
|
+
<a name="M000938"></a><b>new</b>(o=nil)
|
536
536
|
</div>
|
537
537
|
<div class="description">
|
538
538
|
<p>
|
539
539
|
Synonymous with clone, this is an interesting method in that it promotes <a
|
540
|
-
href="Kernel.html#
|
540
|
+
href="Kernel.html#M000937">prototype</a>-based Ruby. Now Classes
|
541
541
|
aren‘t the only things that respond to <a
|
542
|
-
href="Kernel.html#
|
542
|
+
href="Kernel.html#M000938">new</a>.
|
543
543
|
</p>
|
544
544
|
<pre>
|
545
545
|
"ABC".new => "ABC"
|
546
546
|
</pre>
|
547
547
|
</div>
|
548
548
|
<div class="sourcecode">
|
549
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
550
|
-
<div id="
|
549
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000938_source')" id="l_M000938_source">show source</a> ]</p>
|
550
|
+
<div id="M000938_source" class="dyn-source">
|
551
551
|
<pre>
|
552
552
|
<span class="ruby-comment cmt"># File lib/more/facets/prototype.rb, line 83</span>
|
553
553
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">new</span>(<span class="ruby-identifier">o</span>=<span class="ruby-keyword kw">nil</span>)
|
@@ -560,11 +560,11 @@ href="Kernel.html#M000934">new</a>.
|
|
560
560
|
</div>
|
561
561
|
<div class="method">
|
562
562
|
<div class="title">
|
563
|
-
<a name="
|
563
|
+
<a name="M000930"></a><b>null</b>()
|
564
564
|
</div>
|
565
565
|
<div class="sourcecode">
|
566
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
567
|
-
<div id="
|
566
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000930_source')" id="l_M000930_source">show source</a> ]</p>
|
567
|
+
<div id="M000930_source" class="dyn-source">
|
568
568
|
<pre>
|
569
569
|
<span class="ruby-comment cmt"># File lib/more/facets/nullclass.rb, line 51</span>
|
570
570
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">null</span>
|
@@ -576,11 +576,11 @@ href="Kernel.html#M000934">new</a>.
|
|
576
576
|
</div>
|
577
577
|
<div class="method">
|
578
578
|
<div class="title">
|
579
|
-
<a name="
|
579
|
+
<a name="M000937"></a><b>prototype</b>(&block)
|
580
580
|
</div>
|
581
581
|
<div class="sourcecode">
|
582
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
583
|
-
<div id="
|
582
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000937_source')" id="l_M000937_source">show source</a> ]</p>
|
583
|
+
<div id="M000937_source" class="dyn-source">
|
584
584
|
<pre>
|
585
585
|
<span class="ruby-comment cmt"># File lib/more/facets/prototype.rb, line 71</span>
|
586
586
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">prototype</span>(<span class="ruby-operator">&</span><span class="ruby-identifier">block</span>)
|
@@ -592,7 +592,7 @@ href="Kernel.html#M000934">new</a>.
|
|
592
592
|
</div>
|
593
593
|
<div class="method">
|
594
594
|
<div class="title">
|
595
|
-
<a name="
|
595
|
+
<a name="M000934"></a><b>ref</b>(x)
|
596
596
|
</div>
|
597
597
|
<div class="description">
|
598
598
|
<p>
|
@@ -600,8 +600,8 @@ Shortcut reference constructor.
|
|
600
600
|
</p>
|
601
601
|
</div>
|
602
602
|
<div class="sourcecode">
|
603
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
604
|
-
<div id="
|
603
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000934_source')" id="l_M000934_source">show source</a> ]</p>
|
604
|
+
<div id="M000934_source" class="dyn-source">
|
605
605
|
<pre>
|
606
606
|
<span class="ruby-comment cmt"># File lib/more/facets/reference.rb, line 78</span>
|
607
607
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">ref</span>(<span class="ruby-identifier">x</span>)
|
@@ -613,7 +613,7 @@ Shortcut reference constructor.
|
|
613
613
|
</div>
|
614
614
|
<div class="method">
|
615
615
|
<div class="title">
|
616
|
-
<a name="
|
616
|
+
<a name="M000944"></a><b>timed</b>() {|timer = Timer.new.start| ...}
|
617
617
|
</div>
|
618
618
|
<div class="description">
|
619
619
|
<p>
|
@@ -621,8 +621,8 @@ Takes a block and returns the total time it took to execute.
|
|
621
621
|
</p>
|
622
622
|
</div>
|
623
623
|
<div class="sourcecode">
|
624
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
625
|
-
<div id="
|
624
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000944_source')" id="l_M000944_source">show source</a> ]</p>
|
625
|
+
<div id="M000944_source" class="dyn-source">
|
626
626
|
<pre>
|
627
627
|
<span class="ruby-comment cmt"># File lib/more/facets/timer.rb, line 268</span>
|
628
628
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">timed</span>
|
@@ -85,7 +85,7 @@ reads rather than inserts!
|
|
85
85
|
</p>
|
86
86
|
<p>
|
87
87
|
LRU semantics are enforced by inserting the items in a queue. The <a
|
88
|
-
href="LRUCache.html#
|
88
|
+
href="LRUCache.html#M000289">lru</a> item is always at the tail. Two
|
89
89
|
special sentinels (head, tail) are used to simplify (?) the code.
|
90
90
|
</p>
|
91
91
|
</div>
|
@@ -94,14 +94,14 @@ special sentinels (head, tail) are used to simplify (?) the code.
|
|
94
94
|
|
95
95
|
<div class="sectiontitle">Methods</div>
|
96
96
|
<ul>
|
97
|
-
<li><a href="#
|
98
|
-
<li><a href="#
|
99
|
-
<li><a href="#
|
100
|
-
<li><a href="#
|
101
|
-
<li><a href="#
|
102
|
-
<li><a href="#
|
103
|
-
<li><a href="#
|
104
|
-
<li><a href="#
|
97
|
+
<li><a href="#M000283">[]</a></li>
|
98
|
+
<li><a href="#M000284">[]=</a></li>
|
99
|
+
<li><a href="#M000286">clear</a></li>
|
100
|
+
<li><a href="#M000285">delete</a></li>
|
101
|
+
<li><a href="#M000287">first</a></li>
|
102
|
+
<li><a href="#M000288">last</a></li>
|
103
|
+
<li><a href="#M000289">lru</a></li>
|
104
|
+
<li><a href="#M000282">new</a></li>
|
105
105
|
</ul>
|
106
106
|
|
107
107
|
|
@@ -121,7 +121,7 @@ Class <a href="LRUCache/Sentinel.html" class="link">LRUCache::Sentinel</a><br />
|
|
121
121
|
<td class='attr-name'>head</td>
|
122
122
|
<td class='attr-desc'>
|
123
123
|
the head sentinel and the tail sentinel, tail.prev points to the <a
|
124
|
-
href="LRUCache.html#
|
124
|
+
href="LRUCache.html#M000289">lru</a> item.
|
125
125
|
|
126
126
|
</td>
|
127
127
|
</tr>
|
@@ -142,7 +142,7 @@ the maximum number of items in the cache.
|
|
142
142
|
<td class='attr-name'>tail</td>
|
143
143
|
<td class='attr-desc'>
|
144
144
|
the head sentinel and the tail sentinel, tail.prev points to the <a
|
145
|
-
href="LRUCache.html#
|
145
|
+
href="LRUCache.html#M000289">lru</a> item.
|
146
146
|
|
147
147
|
</td>
|
148
148
|
</tr>
|
@@ -151,11 +151,11 @@ href="LRUCache.html#M000280">lru</a> item.
|
|
151
151
|
<div class="sectiontitle">Public Class methods</div>
|
152
152
|
<div class="method">
|
153
153
|
<div class="title">
|
154
|
-
<a name="
|
154
|
+
<a name="M000282"></a><b>new</b>(max_items)
|
155
155
|
</div>
|
156
156
|
<div class="sourcecode">
|
157
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
158
|
-
<div id="
|
157
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000282_source')" id="l_M000282_source">show source</a> ]</p>
|
158
|
+
<div id="M000282_source" class="dyn-source">
|
159
159
|
<pre>
|
160
160
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 59</span>
|
161
161
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">max_items</span>)
|
@@ -169,7 +169,7 @@ href="LRUCache.html#M000280">lru</a> item.
|
|
169
169
|
<div class="sectiontitle">Public Instance methods</div>
|
170
170
|
<div class="method">
|
171
171
|
<div class="title">
|
172
|
-
<a name="
|
172
|
+
<a name="M000283"></a><b>[]</b>(key)
|
173
173
|
</div>
|
174
174
|
<div class="description">
|
175
175
|
<p>
|
@@ -177,8 +177,8 @@ Lookup an item in the cache.
|
|
177
177
|
</p>
|
178
178
|
</div>
|
179
179
|
<div class="sourcecode">
|
180
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
181
|
-
<div id="
|
180
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000283_source')" id="l_M000283_source">show source</a> ]</p>
|
181
|
+
<div id="M000283_source" class="dyn-source">
|
182
182
|
<pre>
|
183
183
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 66</span>
|
184
184
|
<span class="ruby-keyword kw">def</span> <span class="ruby-operator">[]</span>(<span class="ruby-identifier">key</span>)
|
@@ -192,7 +192,7 @@ Lookup an item in the cache.
|
|
192
192
|
</div>
|
193
193
|
<div class="method">
|
194
194
|
<div class="title">
|
195
|
-
<a name="
|
195
|
+
<a name="M000284"></a><b>[]=</b>(key, item)
|
196
196
|
</div>
|
197
197
|
<div class="description">
|
198
198
|
<p>
|
@@ -200,8 +200,8 @@ The inserted item is considered mru!
|
|
200
200
|
</p>
|
201
201
|
</div>
|
202
202
|
<div class="sourcecode">
|
203
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
204
|
-
<div id="
|
203
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000284_source')" id="l_M000284_source">show source</a> ]</p>
|
204
|
+
<div id="M000284_source" class="dyn-source">
|
205
205
|
<pre>
|
206
206
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 74</span>
|
207
207
|
<span class="ruby-keyword kw">def</span> <span class="ruby-operator">[]=</span>(<span class="ruby-identifier">key</span>, <span class="ruby-identifier">item</span>)
|
@@ -215,7 +215,7 @@ The inserted item is considered mru!
|
|
215
215
|
</div>
|
216
216
|
<div class="method">
|
217
217
|
<div class="title">
|
218
|
-
<a name="
|
218
|
+
<a name="M000286"></a><b>clear</b>()
|
219
219
|
</div>
|
220
220
|
<div class="description">
|
221
221
|
<p>
|
@@ -223,8 +223,8 @@ Clear the cache.
|
|
223
223
|
</p>
|
224
224
|
</div>
|
225
225
|
<div class="sourcecode">
|
226
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
227
|
-
<div id="
|
226
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000286_source')" id="l_M000286_source">show source</a> ]</p>
|
227
|
+
<div id="M000286_source" class="dyn-source">
|
228
228
|
<pre>
|
229
229
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 90</span>
|
230
230
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">clear</span>
|
@@ -237,7 +237,7 @@ Clear the cache.
|
|
237
237
|
</div>
|
238
238
|
<div class="method">
|
239
239
|
<div class="title">
|
240
|
-
<a name="
|
240
|
+
<a name="M000285"></a><b>delete</b>(key)
|
241
241
|
</div>
|
242
242
|
<div class="description">
|
243
243
|
<p>
|
@@ -245,8 +245,8 @@ Delete an item from the cache.
|
|
245
245
|
</p>
|
246
246
|
</div>
|
247
247
|
<div class="sourcecode">
|
248
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
249
|
-
<div id="
|
248
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000285_source')" id="l_M000285_source">show source</a> ]</p>
|
249
|
+
<div id="M000285_source" class="dyn-source">
|
250
250
|
<pre>
|
251
251
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 82</span>
|
252
252
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">delete</span>(<span class="ruby-identifier">key</span>)
|
@@ -260,16 +260,16 @@ Delete an item from the cache.
|
|
260
260
|
</div>
|
261
261
|
<div class="method">
|
262
262
|
<div class="title">
|
263
|
-
<a name="
|
263
|
+
<a name="M000287"></a><b>first</b>()
|
264
264
|
</div>
|
265
265
|
<div class="description">
|
266
266
|
<p>
|
267
|
-
The <a href="LRUCache.html#
|
267
|
+
The <a href="LRUCache.html#M000287">first</a> (mru) element in the cache.
|
268
268
|
</p>
|
269
269
|
</div>
|
270
270
|
<div class="sourcecode">
|
271
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
272
|
-
<div id="
|
271
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000287_source')" id="l_M000287_source">show source</a> ]</p>
|
272
|
+
<div id="M000287_source" class="dyn-source">
|
273
273
|
<pre>
|
274
274
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 97</span>
|
275
275
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">first</span>
|
@@ -281,21 +281,21 @@ The <a href="LRUCache.html#M000278">first</a> (mru) element in the cache.
|
|
281
281
|
</div>
|
282
282
|
<div class="method">
|
283
283
|
<div class="title">
|
284
|
-
<a name="
|
284
|
+
<a name="M000288"></a><b>last</b>()
|
285
285
|
</div>
|
286
286
|
<div class="description">
|
287
287
|
<p>
|
288
|
-
The <a href="LRUCache.html#
|
289
|
-
href="LRUCache.html#
|
288
|
+
The <a href="LRUCache.html#M000288">last</a> (<a
|
289
|
+
href="LRUCache.html#M000289">lru</a>) element in the cache.
|
290
290
|
</p>
|
291
291
|
</div>
|
292
292
|
<div class="aka">
|
293
293
|
This method is also aliased as
|
294
|
-
<a href="LRUCache.html#
|
294
|
+
<a href="LRUCache.html#M000289">lru</a>
|
295
295
|
</div>
|
296
296
|
<div class="sourcecode">
|
297
|
-
<p class="source-link">[ <a href="javascript:toggleSource('
|
298
|
-
<div id="
|
297
|
+
<p class="source-link">[ <a href="javascript:toggleSource('M000288_source')" id="l_M000288_source">show source</a> ]</p>
|
298
|
+
<div id="M000288_source" class="dyn-source">
|
299
299
|
<pre>
|
300
300
|
<span class="ruby-comment cmt"># File lib/more/facets/lrucache.rb, line 103</span>
|
301
301
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">last</span>
|
@@ -307,11 +307,11 @@ href="LRUCache.html#M000280">lru</a>) element in the cache.
|
|
307
307
|
</div>
|
308
308
|
<div class="method">
|
309
309
|
<div class="title">
|
310
|
-
<a name="
|
310
|
+
<a name="M000289"></a><b>lru</b>()
|
311
311
|
</div>
|
312
312
|
<div class="description">
|
313
313
|
<p>
|
314
|
-
Alias for <a href="LRUCache.html#
|
314
|
+
Alias for <a href="LRUCache.html#M000288">last</a>
|
315
315
|
</p>
|
316
316
|
</div>
|
317
317
|
</div>
|