facets 1.4.5 → 1.7.0
Sign up to get free protection for your applications and to get access to all the features.
- data/demo/tkxml/helloworld.rb +32 -0
- data/demo/tkxml/ui.xml +32 -0
- data/doc/AUTHORS +2 -0
- data/doc/ChangeLog +92 -337
- data/doc/ChangeLog.pre1.5 +337 -0
- data/doc/LATEST +41 -0
- data/doc/manifest +1209 -0
- data/lib/facet/array/op_div.rb +1 -0
- data/lib/facet/autoarray.rb +1 -0
- data/lib/facet/cut.rb +1 -0
- data/lib/facet/enumerable/divide.rb +1 -0
- data/lib/facet/eventhook.rb +1 -0
- data/lib/facet/hash/diff.rb +1 -0
- data/lib/facet/hash/having_aquisition.rb +1 -0
- data/lib/facet/hash/having_fallback.rb +1 -0
- data/lib/facet/hash/normalize_keys.rb +1 -0
- data/lib/facet/hash/op_div.rb +1 -0
- data/lib/facet/hash/reverse_merge.rb +1 -0
- data/lib/facet/hash/reverse_update.rb +1 -0
- data/lib/facet/hash/self/auto.rb +1 -0
- data/lib/facet/hash/symbolize_keys.rb +1 -0
- data/lib/facet/hash/to_struct.rb +1 -0
- data/lib/facet/infinity.rb +1 -0
- data/lib/facet/instance_intercept.rb +1 -0
- data/lib/facet/integer/each.rb +1 -0
- data/lib/facet/integer/of.rb +1 -0
- data/lib/facet/kernel/callee.rb +1 -0
- data/lib/facet/kernel/deep_clone.rb +1 -0
- data/lib/facet/kernel/instance_exec.rb +1 -0
- data/lib/facet/kernel/meta.rb +1 -0
- data/lib/facet/kernel/object_clone.rb +1 -0
- data/lib/facet/kernel/object_dup.rb +1 -0
- data/lib/facet/kernel/to_data.rb +1 -0
- data/lib/facet/methodfilter.rb +1 -0
- data/lib/facet/numeric/distance.rb +1 -0
- data/lib/facet/predicate.rb +1 -0
- data/lib/facet/rwdelegator.rb +1 -0
- data/lib/facet/settings.rb +1 -0
- data/lib/facet/string/divide.rb +1 -0
- data/lib/facet/symbol/self/generate.rb +1 -0
- data/lib/facet/tkxml.rb +1 -0
- data/lib/facets.rb +4 -2
- data/lib/facets/core/array/op_div.rb +11 -0
- data/lib/facets/core/enumerable/divide.rb +20 -0
- data/lib/facets/core/hash/diff.rb +8 -0
- data/lib/facets/core/hash/having_aquisition.rb +37 -0
- data/lib/facets/core/hash/having_fallback.rb +28 -0
- data/lib/facets/core/hash/keys_to_s.rb +2 -80
- data/lib/facets/core/hash/keys_to_sym.rb +2 -91
- data/lib/facets/core/hash/normalize_keys.rb +65 -0
- data/lib/facets/core/hash/op_div.rb +8 -0
- data/lib/facets/core/hash/reverse_merge.rb +22 -0
- data/lib/facets/core/hash/reverse_update.rb +3 -0
- data/lib/facets/core/hash/self/auto.rb +28 -0
- data/lib/facets/core/hash/stringify_keys.rb +74 -2
- data/lib/facets/core/hash/symbolize_keys.rb +87 -0
- data/lib/facets/core/hash/to_struct.rb +16 -0
- data/lib/facets/core/integer/each.rb +9 -0
- data/lib/facets/core/integer/of.rb +37 -0
- data/lib/facets/core/kernel/__method__.rb +2 -45
- data/lib/facets/core/kernel/callee.rb +46 -0
- data/lib/facets/core/kernel/deep_clone.rb +50 -0
- data/lib/facets/core/kernel/instance_exec.rb +58 -0
- data/lib/facets/core/kernel/meta.rb +21 -0
- data/lib/facets/core/kernel/object_clone.rb +4 -0
- data/lib/facets/core/kernel/object_dup.rb +2 -0
- data/lib/facets/core/kernel/to_data.rb +114 -0
- data/lib/facets/core/module/alias_method_chain.rb +1 -1
- data/lib/facets/core/module/wrap_method.rb +2 -2
- data/lib/facets/core/nilclass/status.rb +4 -4
- data/lib/facets/core/numeric/distance.rb +37 -0
- data/lib/facets/core/proc/compose.rb +3 -21
- data/lib/facets/core/proc/op_mul.rb +51 -2
- data/lib/facets/core/proc/to_method.rb +37 -36
- data/lib/facets/core/string/divide.rb +43 -0
- data/lib/facets/core/string/singular.rb +152 -67
- data/lib/facets/core/symbol/self/generate.rb +18 -0
- data/lib/facets/more/annattr.rb +4 -4
- data/lib/facets/more/annotation.rb +359 -296
- data/lib/facets/more/aspects.rb +1 -1
- data/lib/facets/more/autoarray.rb +82 -0
- data/lib/facets/more/builderobject.rb +5 -3
- data/lib/facets/more/command.rb +2 -0
- data/lib/facets/more/cut.rb +507 -0
- data/lib/facets/more/dictionary.rb +64 -30
- data/lib/facets/more/downloader.rb +6 -3
- data/lib/facets/more/elementor.rb +26 -16
- data/lib/facets/more/eventhook.rb +113 -0
- data/lib/facets/more/filelist.rb +8 -0
- data/lib/facets/more/functor.rb +28 -11
- data/lib/facets/more/hashbuilder.rb +7 -3
- data/lib/facets/more/infinity.rb +221 -0
- data/{snip/more/aspect.rb → lib/facets/more/instance_intercept.rb} +56 -20
- data/lib/facets/more/json.rb +5 -5
- data/lib/facets/more/methodfilter.rb +118 -0
- data/lib/facets/more/opencascade.rb +35 -66
- data/lib/facets/more/openobject.rb +213 -162
- data/lib/facets/more/orderedhash.rb +7 -0
- data/{snip → lib/facets}/more/predicate.rb +3 -0
- data/lib/facets/more/recorder.rb +9 -3
- data/lib/facets/more/reference.rb +7 -2
- data/lib/facets/more/rexmlbuilder.rb +7 -2
- data/lib/facets/more/rwdelegator.rb +51 -0
- data/lib/facets/more/settings.rb +219 -0
- data/lib/facets/more/snapshot.rb +4 -2
- data/lib/facets/more/tagiterator.rb +4 -4
- data/lib/facets/more/taskable.rb +5 -5
- data/lib/facets/more/tkxml.rb +171 -0
- data/meta/projectinfo +38 -0
- data/{Reapfile → meta/reapfile} +0 -0
- data/meta/task +74 -0
- data/meta/tasks/calibre.rb +16 -0
- data/meta/version +1 -0
- data/test/lib/facets/core/array/test_at_rand.rb +1 -1
- data/test/lib/facets/core/array/test_delete_unless.rb +1 -1
- data/test/lib/facets/core/array/test_delete_values.rb +1 -1
- data/test/lib/facets/core/array/test_delete_values_at.rb +1 -1
- data/test/lib/facets/core/array/test_first.rb +1 -1
- data/test/lib/facets/core/array/test_head.rb +1 -1
- data/test/lib/facets/core/array/test_last_index.rb +1 -1
- data/test/lib/facets/core/array/test_merge.rb +1 -1
- data/test/lib/facets/core/array/test_mid.rb +1 -1
- data/test/lib/facets/core/array/test_middle.rb +1 -1
- data/test/lib/facets/core/array/test_op_fetch.rb +1 -1
- data/test/lib/facets/core/array/test_op_store.rb +1 -1
- data/test/lib/facets/core/array/test_pick.rb +1 -1
- data/test/lib/facets/core/array/test_pos.rb +1 -1
- data/test/lib/facets/core/array/test_pot.rb +1 -1
- data/test/lib/facets/core/array/test_pull.rb +1 -1
- data/test/lib/facets/core/array/test_rand_index.rb +1 -1
- data/test/lib/facets/core/array/test_rand_subset.rb +1 -1
- data/test/lib/facets/core/array/test_range.rb +1 -1
- data/test/lib/facets/core/array/test_rotate.rb +1 -1
- data/test/lib/facets/core/array/test_select.rb +1 -1
- data/test/lib/facets/core/array/test_shuffle.rb +1 -1
- data/test/lib/facets/core/array/test_thru.rb +1 -1
- data/test/lib/facets/core/array/test_to_b.rb +1 -1
- data/test/lib/facets/core/array/test_to_h.rb +1 -1
- data/test/lib/facets/core/array/test_to_hash.rb +1 -1
- data/test/lib/facets/core/binding/self/test_of_caller.rb +1 -1
- data/test/lib/facets/core/binding/test___LINE__.rb +1 -1
- data/test/lib/facets/core/binding/test_call_stack.rb +1 -1
- data/test/lib/facets/core/binding/test_called.rb +1 -1
- data/test/lib/facets/core/binding/test_caller.rb +1 -1
- data/test/lib/facets/core/binding/test_defined.rb +1 -1
- data/test/lib/facets/core/binding/test_eval.rb +1 -1
- data/test/lib/facets/core/binding/test_local_variables.rb +1 -1
- data/test/lib/facets/core/binding/test_method_name.rb +1 -1
- data/test/lib/facets/core/binding/test_op_fetch.rb +1 -1
- data/test/lib/facets/core/binding/test_op_store.rb +1 -1
- data/test/lib/facets/core/binding/test_self.rb +1 -1
- data/test/lib/facets/core/class/test_cattr.rb +1 -1
- data/test/lib/facets/core/class/test_descendents.rb +1 -1
- data/test/lib/facets/core/class/test_method_name.rb +1 -1
- data/test/lib/facets/core/class/test_remove_descendents.rb +1 -1
- data/test/lib/facets/core/class/test_unix_path.rb +1 -1
- data/test/lib/facets/core/comparable/test_at_least.rb +1 -1
- data/test/lib/facets/core/comparable/test_clip.rb +1 -1
- data/test/lib/facets/core/comparable/test_cmp.rb +1 -1
- data/test/lib/facets/core/continuation/self/test_create.rb +1 -1
- data/test/lib/facets/core/date/test_days_in_month.rb +1 -1
- data/test/lib/facets/core/date/test_days_of_month.rb +1 -1
- data/test/lib/facets/core/date/test_stamp.rb +1 -1
- data/test/lib/facets/core/date/test_to_date.rb +1 -1
- data/test/lib/facets/core/date/test_to_s.rb +1 -1
- data/test/lib/facets/core/date/test_to_time.rb +1 -1
- data/test/lib/facets/core/dir/self/test_ancestor.rb +1 -1
- data/test/lib/facets/core/dir/self/test_ascend.rb +1 -1
- data/test/lib/facets/core/enumerable/self/test_combinations.rb +1 -1
- data/test/lib/facets/core/enumerable/self/test_cross.rb +1 -1
- data/test/lib/facets/core/enumerable/test_collect_with_index.rb +1 -1
- data/test/lib/facets/core/enumerable/test_commonality.rb +1 -1
- data/test/lib/facets/core/enumerable/test_compact_collect.rb +1 -1
- data/test/lib/facets/core/enumerable/test_count.rb +1 -1
- data/test/lib/facets/core/enumerable/test_cross.rb +1 -1
- data/test/lib/facets/core/enumerable/test_each_combination.rb +1 -1
- data/test/lib/facets/core/enumerable/test_each_pair.rb +1 -1
- data/test/lib/facets/core/enumerable/test_each_slice.rb +1 -1
- data/test/lib/facets/core/enumerable/test_each_unique_pair.rb +1 -1
- data/test/lib/facets/core/enumerable/test_entropy.rb +1 -1
- data/test/lib/facets/core/enumerable/test_every.rb +1 -1
- data/test/lib/facets/core/enumerable/test_ew.rb +1 -1
- data/test/lib/facets/core/enumerable/test_filter_collect.rb +1 -1
- data/test/lib/facets/core/enumerable/test_find_collisions.rb +1 -1
- data/test/lib/facets/core/enumerable/test_frequency.rb +1 -1
- data/test/lib/facets/core/enumerable/test_graph.rb +1 -1
- data/test/lib/facets/core/enumerable/test_ideal_entropy.rb +1 -1
- data/test/lib/facets/core/enumerable/test_none.rb +1 -1
- data/test/lib/facets/core/enumerable/test_occur.rb +1 -1
- data/test/lib/facets/core/enumerable/test_one.rb +1 -1
- data/test/lib/facets/core/enumerable/test_op_pow.rb +1 -1
- data/test/lib/facets/core/enumerable/test_partition_by.rb +1 -1
- data/test/lib/facets/core/enumerable/test_permute.rb +1 -1
- data/test/lib/facets/core/enumerable/test_probability.rb +1 -1
- data/test/lib/facets/core/enumerable/test_to_h.rb +1 -1
- data/test/lib/facets/core/enumerable/test_uniq_by.rb +1 -1
- data/test/lib/facets/core/file/self/test_create.rb +1 -1
- data/test/lib/facets/core/file/self/test_open_as_string.rb +1 -1
- data/test/lib/facets/core/file/self/test_read_list.rb +1 -1
- data/test/lib/facets/core/file/self/test_sanitize.rb +1 -1
- data/test/lib/facets/core/file/self/test_split_all.rb +1 -1
- data/test/lib/facets/core/float/test_round_at.rb +1 -1
- data/test/lib/facets/core/float/test_round_to.rb +1 -1
- data/test/lib/facets/core/hash/self/test_zipnew.rb +1 -1
- data/test/lib/facets/core/hash/test_alias.rb +1 -1
- data/test/lib/facets/core/hash/test_assert_has_keys.rb +1 -1
- data/test/lib/facets/core/hash/test_assert_has_only_keys.rb +1 -1
- data/test/lib/facets/core/hash/test_at.rb +1 -1
- data/test/lib/facets/core/hash/test_collate.rb +1 -1
- data/test/lib/facets/core/hash/test_each.rb +1 -1
- data/test/lib/facets/core/hash/test_each_with_index.rb +1 -1
- data/test/lib/facets/core/hash/test_each_with_key.rb +1 -1
- data/test/lib/facets/core/hash/test_graph.rb +1 -1
- data/test/lib/facets/core/hash/test_has_keys.rb +1 -1
- data/test/lib/facets/core/hash/test_has_only_keys.rb +1 -1
- data/test/lib/facets/core/hash/test_inverse.rb +1 -1
- data/test/lib/facets/core/hash/test_normalize_keys.rb +34 -0
- data/test/lib/facets/core/hash/test_op_fetch.rb +1 -1
- data/test/lib/facets/core/hash/test_op_lshift.rb +1 -1
- data/test/lib/facets/core/hash/test_rand_key.rb +1 -1
- data/test/lib/facets/core/hash/test_rand_pair.rb +1 -1
- data/test/lib/facets/core/hash/test_rand_value.rb +1 -1
- data/test/lib/facets/core/hash/test_replace_each.rb +1 -1
- data/test/lib/facets/core/hash/test_shuffle.rb +1 -1
- data/test/lib/facets/core/hash/test_slice.rb +1 -1
- data/test/lib/facets/core/hash/{test_keys_to_s.rb → test_stringify_keys.rb} +5 -5
- data/test/lib/facets/core/hash/test_swap.rb +1 -1
- data/test/lib/facets/core/hash/test_swapkey.rb +1 -1
- data/test/lib/facets/core/hash/{test_keys_to_sym.rb → test_symbolize_keys.rb} +5 -5
- data/test/lib/facets/core/hash/test_to_h.rb +1 -1
- data/test/lib/facets/core/hash/test_to_ostruct.rb +1 -1
- data/test/lib/facets/core/hash/test_to_ostruct_recurse.rb +1 -1
- data/test/lib/facets/core/hash/test_traverse.rb +1 -1
- data/test/lib/facets/core/hash/test_update_each.rb +1 -1
- data/test/lib/facets/core/hash/test_update_keys.rb +1 -1
- data/test/lib/facets/core/hash/test_update_values.rb +1 -1
- data/test/lib/facets/core/hash/test_weave.rb +1 -1
- data/test/lib/facets/core/integer/test_factorial.rb +1 -1
- data/test/lib/facets/core/integer/test_multiple.rb +1 -1
- data/test/lib/facets/core/integer/test_of.rb +28 -0
- data/test/lib/facets/core/integer/test_ordinal.rb +1 -1
- data/test/lib/facets/core/integer/test_times_collect.rb +1 -1
- data/test/lib/facets/core/kernel/test___class__.rb +1 -1
- data/test/lib/facets/core/kernel/test___method__.rb +1 -1
- data/test/lib/facets/core/kernel/test_as.rb +1 -1
- data/test/lib/facets/core/kernel/test_assign_from.rb +1 -1
- data/test/lib/facets/core/kernel/test_assign_with.rb +1 -1
- data/test/lib/facets/core/kernel/test_bool.rb +1 -1
- data/test/lib/facets/core/kernel/test_bug.rb +1 -1
- data/test/lib/facets/core/kernel/test_call_stack.rb +1 -1
- data/test/lib/facets/core/kernel/test_called.rb +1 -1
- data/test/lib/facets/core/kernel/test_callee.rb +26 -0
- data/test/lib/facets/core/kernel/test_constant.rb +1 -1
- data/test/lib/facets/core/kernel/test_copy.rb +1 -1
- data/test/lib/facets/core/kernel/test_deep_copy.rb +1 -1
- data/test/lib/facets/core/kernel/test_demo.rb +1 -1
- data/test/lib/facets/core/kernel/test_fn.rb +1 -1
- data/test/lib/facets/core/kernel/test_get_by_id.rb +1 -1
- data/test/lib/facets/core/kernel/test_here.rb +1 -1
- data/test/lib/facets/core/kernel/test_in.rb +1 -1
- data/test/lib/facets/core/kernel/test_instance_exec.rb +52 -0
- data/test/lib/facets/core/kernel/test_maybe.rb +1 -1
- data/test/lib/facets/core/kernel/test_metaclass.rb +1 -1
- data/test/lib/facets/core/kernel/test_method.rb +1 -1
- data/test/lib/facets/core/kernel/test_methods.rb +1 -1
- data/test/lib/facets/core/kernel/test_new.rb +1 -1
- data/test/lib/facets/core/kernel/test_object_class.rb +1 -1
- data/test/lib/facets/core/kernel/test_object_hexid.rb +1 -1
- data/test/lib/facets/core/kernel/test_quaclass.rb +1 -1
- data/test/lib/facets/core/kernel/test_require_all.rb +1 -1
- data/test/lib/facets/core/kernel/test_require_esc.rb +1 -1
- data/test/lib/facets/core/kernel/test_require_facet.rb +1 -1
- data/test/lib/facets/core/kernel/test_resc.rb +1 -1
- data/test/lib/facets/core/kernel/test_returning.rb +1 -1
- data/test/lib/facets/core/kernel/test_send_as.rb +1 -1
- data/test/lib/facets/core/kernel/test_set_from.rb +1 -1
- data/test/lib/facets/core/kernel/test_set_with.rb +1 -1
- data/test/lib/facets/core/kernel/test_silently.rb +1 -1
- data/test/lib/facets/core/kernel/test_singleton.rb +1 -1
- data/test/lib/facets/core/kernel/test_singleton_class.rb +1 -1
- data/test/lib/facets/core/kernel/test_superior.rb +1 -1
- data/test/lib/facets/core/kernel/test_supermethod.rb +1 -1
- data/test/lib/facets/core/kernel/test_this.rb +1 -1
- data/test/lib/facets/core/kernel/test_to_b.rb +1 -1
- data/test/lib/facets/core/kernel/test_to_bool.rb +1 -1
- data/test/lib/facets/core/kernel/test_to_data.rb +59 -0
- data/test/lib/facets/core/kernel/test_uri.rb +1 -1
- data/test/lib/facets/core/kernel/test_val.rb +1 -1
- data/test/lib/facets/core/kernel/test_with_accessor.rb +1 -1
- data/test/lib/facets/core/matchdata/test_match.rb +1 -1
- data/test/lib/facets/core/matchdata/test_matchtree.rb +1 -1
- data/test/lib/facets/core/module/test_abstract.rb +1 -1
- data/test/lib/facets/core/module/test_alias_module_function.rb +1 -1
- data/test/lib/facets/core/module/test_ancestor.rb +1 -1
- data/test/lib/facets/core/module/test_basename.rb +1 -1
- data/test/lib/facets/core/module/test_by_name.rb +1 -1
- data/test/lib/facets/core/module/test_class_extension.rb +1 -1
- data/test/lib/facets/core/module/test_clone_using.rb +1 -1
- data/test/lib/facets/core/module/test_dirname.rb +1 -1
- data/test/lib/facets/core/module/test_equate_on.rb +1 -1
- data/test/lib/facets/core/module/test_include_as.rb +1 -1
- data/test/lib/facets/core/module/test_initializer.rb +1 -1
- data/test/lib/facets/core/module/test_instance_methods.rb +1 -1
- data/test/lib/facets/core/module/test_integrate.rb +1 -1
- data/test/lib/facets/core/module/test_memoize.rb +1 -1
- data/test/lib/facets/core/module/test_modspace.rb +1 -1
- data/test/lib/facets/core/module/test_namespace.rb +1 -1
- data/test/lib/facets/core/module/test_nesting.rb +1 -1
- data/test/lib/facets/core/module/test_nodef.rb +1 -1
- data/test/lib/facets/core/module/test_on_included.rb +1 -1
- data/test/lib/facets/core/module/test_redef.rb +1 -1
- data/test/lib/facets/core/module/test_redefine_method.rb +1 -1
- data/test/lib/facets/core/module/test_redirect.rb +1 -1
- data/test/lib/facets/core/module/test_redirect_method.rb +1 -1
- data/test/lib/facets/core/module/test_remove.rb +1 -1
- data/test/lib/facets/core/module/test_rename.rb +1 -1
- data/test/lib/facets/core/module/test_rename_method.rb +1 -1
- data/test/lib/facets/core/module/test_revisal.rb +1 -1
- data/test/lib/facets/core/module/test_shadow_method.rb +1 -1
- data/test/lib/facets/core/module/test_sort_on.rb +1 -1
- data/test/lib/facets/core/module/test_this.rb +1 -1
- data/test/lib/facets/core/module/test_wrap.rb +1 -1
- data/test/lib/facets/core/module/test_wrap_method.rb +1 -1
- data/test/lib/facets/core/nilclass/test_blank.rb +1 -1
- data/test/lib/facets/core/nilclass/test_empty.rb +1 -1
- data/test/lib/facets/core/nilclass/test_include.rb +1 -1
- data/test/lib/facets/core/nilclass/test_op_fetch.rb +1 -1
- data/test/lib/facets/core/nilclass/test_size.rb +1 -1
- data/test/lib/facets/core/nilclass/test_to_h.rb +1 -1
- data/test/lib/facets/core/numeric/test_approx.rb +1 -1
- data/test/lib/facets/core/numeric/test_ceil_multiple.rb +1 -1
- data/test/lib/facets/core/numeric/test_distance.rb +28 -0
- data/test/lib/facets/core/numeric/test_succ.rb +1 -1
- data/test/lib/facets/core/numeric/test_to_b.rb +1 -1
- data/test/lib/facets/core/ostruct/test___merge__.rb +1 -1
- data/test/lib/facets/core/ostruct/test___update__.rb +1 -1
- data/test/lib/facets/core/ostruct/test_op_fetch.rb +1 -1
- data/test/lib/facets/core/ostruct/test_op_store.rb +1 -1
- data/test/lib/facets/core/proc/test_compose.rb +1 -8
- data/test/lib/facets/core/proc/test_op_mul.rb +34 -0
- data/test/lib/facets/core/proc/test_to_method.rb +15 -2
- data/test/lib/facets/core/range/test_to_r.rb +1 -1
- data/test/lib/facets/core/range/test_to_range.rb +1 -1
- data/test/lib/facets/core/range/test_umbrella.rb +1 -1
- data/test/lib/facets/core/range/test_within.rb +1 -1
- data/test/lib/facets/core/regexp/test_arity.rb +1 -1
- data/test/lib/facets/core/regexp/test_to_re.rb +1 -1
- data/test/lib/facets/core/regexp/test_to_regexp.rb +1 -1
- data/test/lib/facets/core/string/self/test_interpolate.rb +1 -1
- data/test/lib/facets/core/string/self/test_patterns.rb +1 -1
- data/test/lib/facets/core/string/self/test_rand_letter.rb +1 -1
- data/test/lib/facets/core/string/test_align_center.rb +1 -1
- data/test/lib/facets/core/string/test_at_rand.rb +1 -1
- data/test/lib/facets/core/string/test_basename.rb +1 -1
- data/test/lib/facets/core/string/test_blank.rb +1 -1
- data/test/lib/facets/core/string/test_bracket.rb +1 -1
- data/test/lib/facets/core/string/test_camelcase.rb +1 -1
- data/test/lib/facets/core/string/test_camelize.rb +1 -1
- data/test/lib/facets/core/string/test_capitalized.rb +1 -1
- data/test/lib/facets/core/string/test_chars.rb +1 -1
- data/test/lib/facets/core/string/test_cmp.rb +1 -1
- data/test/lib/facets/core/string/test_demodulize.rb +1 -1
- data/test/lib/facets/core/string/test_divide.rb +29 -0
- data/test/lib/facets/core/string/test_downcase.rb +1 -1
- data/test/lib/facets/core/string/test_dresner.rb +1 -1
- data/test/lib/facets/core/string/test_each_char.rb +1 -1
- data/test/lib/facets/core/string/test_each_word.rb +1 -1
- data/test/lib/facets/core/string/test_first.rb +1 -1
- data/test/lib/facets/core/string/test_fold.rb +1 -1
- data/test/lib/facets/core/string/test_humanize.rb +1 -1
- data/test/lib/facets/core/string/test_indent.rb +1 -1
- data/test/lib/facets/core/string/test_index_all.rb +1 -1
- data/test/lib/facets/core/string/test_last.rb +1 -1
- data/test/lib/facets/core/string/test_line_wrap.rb +1 -1
- data/test/lib/facets/core/string/test_lines.rb +1 -1
- data/test/lib/facets/core/string/test_lowercase.rb +1 -1
- data/test/lib/facets/core/string/test_margin.rb +1 -1
- data/test/lib/facets/core/string/test_methodize.rb +1 -1
- data/test/lib/facets/core/string/test_modulize.rb +1 -1
- data/test/lib/facets/core/string/test_mscan.rb +1 -1
- data/test/lib/facets/core/string/test_natcmp.rb +1 -1
- data/test/lib/facets/core/string/test_nchar.rb +1 -1
- data/test/lib/facets/core/string/test_pathize.rb +1 -1
- data/test/lib/facets/core/string/test_pop.rb +1 -1
- data/test/lib/facets/core/string/test_pot.rb +1 -1
- data/test/lib/facets/core/string/test_push.rb +1 -1
- data/test/lib/facets/core/string/test_quote.rb +1 -1
- data/test/lib/facets/core/string/test_rand_byte.rb +1 -1
- data/test/lib/facets/core/string/test_rand_index.rb +1 -1
- data/test/lib/facets/core/string/test_range.rb +1 -1
- data/test/lib/facets/core/string/test_range_all.rb +1 -1
- data/test/lib/facets/core/string/test_range_of_line.rb +1 -1
- data/test/lib/facets/core/string/test_regesc.rb +1 -1
- data/test/lib/facets/core/string/test_shatter.rb +1 -1
- data/test/lib/facets/core/string/test_shift.rb +1 -1
- data/test/lib/facets/core/string/test_shuffle.rb +1 -1
- data/test/lib/facets/core/string/test_similarity.rb +1 -1
- data/test/lib/facets/core/string/test_singular.rb +62 -8
- data/test/lib/facets/core/string/test_soundex.rb +1 -1
- data/test/lib/facets/core/string/test_succ.rb +1 -1
- data/test/lib/facets/core/string/test_to_a.rb +1 -1
- data/test/lib/facets/core/string/test_to_b.rb +1 -1
- data/test/lib/facets/core/string/test_to_const.rb +1 -1
- data/test/lib/facets/core/string/test_to_date.rb +1 -1
- data/test/lib/facets/core/string/test_to_proc.rb +1 -1
- data/test/lib/facets/core/string/test_to_re.rb +1 -1
- data/test/lib/facets/core/string/test_to_time.rb +1 -1
- data/test/lib/facets/core/string/test_unix_crypt.rb +1 -1
- data/test/lib/facets/core/string/test_unpack.rb +1 -1
- data/test/lib/facets/core/string/test_unshift.rb +1 -1
- data/test/lib/facets/core/string/test_upcase.rb +1 -1
- data/test/lib/facets/core/string/test_whitespace.rb +1 -1
- data/test/lib/facets/core/string/test_word_filter.rb +1 -1
- data/test/lib/facets/core/string/test_word_wrap.rb +1 -1
- data/test/lib/facets/core/string/test_words.rb +1 -1
- data/test/lib/facets/core/symbol/test_camelcase.rb +1 -1
- data/test/lib/facets/core/symbol/test_camelize.rb +1 -1
- data/test/lib/facets/core/symbol/test_capitalize.rb +1 -1
- data/test/lib/facets/core/symbol/test_capitalized.rb +1 -1
- data/test/lib/facets/core/symbol/test_downcase.rb +1 -1
- data/test/lib/facets/core/symbol/test_not.rb +1 -1
- data/test/lib/facets/core/symbol/test_pad.rb +1 -1
- data/test/lib/facets/core/symbol/test_succ.rb +1 -1
- data/test/lib/facets/core/symbol/test_to_const.rb +1 -1
- data/test/lib/facets/core/symbol/test_to_proc.rb +1 -1
- data/test/lib/facets/core/symbol/test_to_str.rb +1 -1
- data/test/lib/facets/core/symbol/test_underscore.rb +1 -1
- data/test/lib/facets/core/symbol/test_upcase.rb +1 -1
- data/test/lib/facets/core/time/test_change.rb +1 -1
- data/test/lib/facets/core/time/test_elapse.rb +1 -1
- data/test/lib/facets/core/time/test_stamp.rb +1 -1
- data/test/lib/facets/core/time/test_to_date.rb +1 -1
- data/test/lib/facets/core/time/test_to_s.rb +1 -1
- data/test/lib/facets/core/time/test_to_time.rb +1 -1
- data/test/lib/facets/more/test_annattr.rb +1 -1
- data/test/lib/facets/more/test_annotation.rb +225 -113
- data/test/lib/facets/more/test_ansicode.rb +1 -1
- data/test/lib/facets/more/test_association.rb +1 -1
- data/test/lib/facets/more/test_autoarray.rb +32 -0
- data/test/lib/facets/more/test_basicobject.rb +1 -1
- data/test/lib/facets/more/test_bbcode.rb +1 -1
- data/test/lib/facets/more/test_binaryreader.rb +1 -1
- data/test/lib/facets/more/test_bitmask.rb +1 -1
- data/test/lib/facets/more/test_bytes.rb +1 -1
- data/test/lib/facets/more/test_classmethods.rb +1 -1
- data/test/lib/facets/more/test_command.rb +1 -1
- data/test/lib/facets/more/test_coroutine.rb +1 -1
- data/test/lib/facets/more/test_crypt.rb +1 -1
- data/test/lib/facets/more/test_cut.rb +198 -0
- data/test/lib/facets/more/test_dictionary.rb +1 -1
- data/test/lib/facets/more/test_elementor.rb +5 -1
- data/test/lib/facets/more/test_enumerablepass.rb +1 -1
- data/test/lib/facets/more/test_floatstring.rb +1 -1
- data/test/lib/facets/more/test_functor.rb +1 -1
- data/test/lib/facets/more/test_htmlbuilder.rb +1 -1
- data/test/lib/facets/more/test_infinity.rb +50 -0
- data/test/lib/facets/more/test_inheritor.rb +1 -1
- data/test/lib/facets/more/test_instance_intercept.rb +50 -0
- data/test/lib/facets/more/test_interval.rb +1 -1
- data/test/lib/facets/more/test_json.rb +1 -1
- data/test/lib/facets/more/test_lisp.rb +1 -1
- data/test/lib/facets/more/test_lisp_format.rb +1 -1
- data/test/lib/facets/more/test_lrucache.rb +1 -1
- data/test/lib/facets/more/test_mathconstants.rb +1 -1
- data/test/lib/facets/more/test_methodfilter.rb +45 -0
- data/test/lib/facets/more/test_methodprobe.rb +1 -1
- data/test/lib/facets/more/test_multipliers.rb +1 -1
- data/test/lib/facets/more/test_multiton.rb +1 -1
- data/test/lib/facets/more/test_nackclass.rb +1 -1
- data/test/lib/facets/more/test_nilcomparable.rb +1 -1
- data/test/lib/facets/more/test_opencascade.rb +24 -15
- data/test/lib/facets/more/test_openobject.rb +70 -22
- data/test/lib/facets/more/test_overload.rb +1 -1
- data/test/lib/facets/more/test_paramix.rb +1 -1
- data/test/lib/facets/more/test_pqueue.rb +1 -1
- data/test/lib/facets/more/test_predicate.rb +79 -0
- data/test/lib/facets/more/test_preinitialize.rb +1 -1
- data/test/lib/facets/more/test_promoteself.rb +1 -1
- data/test/lib/facets/more/test_recorder.rb +1 -1
- data/test/lib/facets/more/test_snapshot.rb +1 -1
- data/test/lib/facets/more/test_statichash.rb +1 -1
- data/test/lib/facets/more/test_syncarray.rb +1 -1
- data/test/lib/facets/more/test_synchash.rb +1 -1
- data/test/lib/facets/more/test_tagiterator.rb +1 -1
- data/test/lib/facets/more/test_taskable.rb +1 -1
- data/test/lib/facets/more/test_timer.rb +1 -1
- data/test/lib/facets/more/test_times.rb +1 -1
- data/test/lib/facets/more/test_tuple.rb +1 -1
- data/test/lib/facets/more/test_typecast.rb +1 -1
- data/test/lib/facets/more/test_uninheritable.rb +1 -1
- data/test/lib/facets/more/test_units.rb +1 -1
- data/test/lib/facets/more/test_xmlbuilder.rb +1 -1
- data/test/lib/facets/more/test_xmlhelper.rb +1 -1
- data/test/lib/facets/more/test_xoxo.rb +1 -1
- data/test/lib/facets/more/test_yamlstruct.rb +1 -1
- metadata +1147 -2081
- data/doc/api/core/classes/Array.html +0 -1356
- data/doc/api/core/classes/Binding.html +0 -538
- data/doc/api/core/classes/Class.html +0 -476
- data/doc/api/core/classes/Comparable.html +0 -231
- data/doc/api/core/classes/Config.html +0 -120
- data/doc/api/core/classes/Continuation.html +0 -168
- data/doc/api/core/classes/Date.html +0 -219
- data/doc/api/core/classes/Dir.html +0 -208
- data/doc/api/core/classes/Enumerable.html +0 -1462
- data/doc/api/core/classes/FalseClass.html +0 -115
- data/doc/api/core/classes/File.html +0 -383
- data/doc/api/core/classes/FileUtils.html +0 -468
- data/doc/api/core/classes/Float.html +0 -157
- data/doc/api/core/classes/Gem.html +0 -150
- data/doc/api/core/classes/Hash.html +0 -1627
- data/doc/api/core/classes/Integer.html +0 -353
- data/doc/api/core/classes/Kernal.html +0 -86
- data/doc/api/core/classes/Kernel.html +0 -2010
- data/doc/api/core/classes/Logger.html +0 -157
- data/doc/api/core/classes/MatchData.html +0 -195
- data/doc/api/core/classes/Module.html +0 -1812
- data/doc/api/core/classes/NackClass.html +0 -92
- data/doc/api/core/classes/NilClass.html +0 -385
- data/doc/api/core/classes/Numeric.html +0 -306
- data/doc/api/core/classes/Object.html +0 -332
- data/doc/api/core/classes/OpenStruct.html +0 -315
- data/doc/api/core/classes/Pathname.html +0 -154
- data/doc/api/core/classes/Proc.html +0 -154
- data/doc/api/core/classes/Range.html +0 -235
- data/doc/api/core/classes/Regexp.html +0 -185
- data/doc/api/core/classes/ScriptBug.html +0 -92
- data/doc/api/core/classes/String.html +0 -3250
- data/doc/api/core/classes/Symbol.html +0 -463
- data/doc/api/core/classes/Time.html +0 -307
- data/doc/api/core/classes/TrueClass.html +0 -115
- data/doc/api/core/classes/UnboundMethod.html +0 -121
- data/doc/api/core/created.rid +0 -1
- data/doc/api/core/files/COPYING.html +0 -517
- data/doc/api/core/files/README.html +0 -386
- data/doc/api/core/files/lib/facets/core/all_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/array/at_rand_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/body_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/array/delete_unless_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/delete_values_at_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/delete_values_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/each_with_key_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/first_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/array/foot_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/array/head_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/join_sentence_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/last_index_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/last_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/array/merge_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/mid_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/middle_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/op_fetch_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/op_mod_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/op_store_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/array/pick_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/pos_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/pot_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/pull_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/rand_index_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/rand_subset_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/range_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/rotate_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/select_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/shuffle_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/store_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/tail_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/array/thru_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/to_b_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/to_h_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/to_hash_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/array/unzip_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/binding/__DIR___rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/binding/__FILE___rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/binding/__LINE___rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/call_stack_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/binding/called_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/caller_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/defined_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/eval_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/binding/local_variables_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/method_name_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/op_fetch_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/binding/op_store_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/binding/self/of_caller_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding/self_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/binding_rb.html +0 -109
- data/doc/api/core/files/lib/facets/core/class/by_name_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/class/cattr_accessor_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/class/cattr_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/class/cattr_reader_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/class/cattr_writer_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/class/descendents_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/class/method_name_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/class/remove_descendents_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/class/remove_subclasses_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/class/subclasses_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/class/to_proc_rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/class/unix_path_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/comparable/at_least_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/comparable/at_most_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/comparable/cap_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/comparable/clip_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/comparable/cmp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/config/datadir_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/continuation/self/create_rb.html +0 -148
- data/doc/api/core/files/lib/facets/core/date/days_in_month_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/date/days_of_month_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/date/stamp_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/date/to_date_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/date/to_s_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/date/to_time_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/dir/self/ancestor_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/dir/self/ascend_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/dir/self/descend_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/dir/self/ls_r_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/dir/self/recurse_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/accumulate_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/cascade_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/collect_if_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/collect_with_counter_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/collect_with_index_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/commonality_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/compact_collect_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/compact_map_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/count_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/cross_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/each_by_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/each_combination_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/each_pair_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/each_permutation_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/each_slice_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/each_unique_pair_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/each_with_counter_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/elementwise_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/entropy_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/enumerable/every_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/ew_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/filter_collect_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/filter_map_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/find_collisions_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/frequency_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/graph_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/ideal_entropy_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/map_if_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/map_with_counter_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/map_with_index_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/enumerable/mode_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/none_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/nonuniq_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/occur_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/one_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/op_pow_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/partition_by_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/permute_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/probability_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/project_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/self/combinations_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/self/cross_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/enumerable/to_h_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/uniq_by_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/enumerable/where_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/file/self/append_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/file/self/create_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/file/self/open_as_string_rb.html +0 -118
- data/doc/api/core/files/lib/facets/core/file/self/read_binary_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/file/self/read_list_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/file/self/rootname_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/file/self/sanitize_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/file/self/split_all_rb.html +0 -101
- data/doc/api/core/files/lib/facets/core/file/self/write_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/fileutils/head_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/fileutils/safe_ln_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/fileutils/slice_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/fileutils/split_all_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/fileutils/tail_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/fileutils/wc_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/fileutils/whereis_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/fileutils/which_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/float/approx_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/float/round_at_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/float/round_off_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/float/round_to_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/gem/self/active_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/gem/self/gempath_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/gem/self/gemspec_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/alias_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/assert_has_keys_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/assert_has_only_keys_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/at_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/collate_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/delete_unless_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/each_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/each_with_index_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/hash/each_with_key_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/graph_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/has_keys_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/has_only_keys_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/inverse_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/join_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/keys_to_s_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/keys_to_sym_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/op_fetch_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/op_lshift_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/op_store_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/hash/rand_key_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/rand_pair_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/rand_value_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/replace_each_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/self/zipnew_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/shuffle_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/slice_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/stringify_keys_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/hash/swap_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/swapkey_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/symoblize_keys_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/hash/to_h_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/to_ostruct_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/hash/to_ostruct_recurse_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/hash/to_proc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/traverse_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/update_each_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/update_keys_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/update_values_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/variablize_keys_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/hash/weave_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/inflect_rb.html +0 -117
- data/doc/api/core/files/lib/facets/core/integer/even_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/integer/fac_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/integer/fact_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/integer/factorial_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/integer/multiple_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/integer/odd_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/integer/ordinal_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/integer/times_collect_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/integer/times_map_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/__DIR___rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/__callee___rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/__class___rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/__get___rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/__method___rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/__self___rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/__set___rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/as_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/assign_from_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/assign_with_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/kernel/autoreload_files_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/autoreload_glob_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/autoreload_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/bool_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/bug_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/cache_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/call_stack_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/called_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/complete_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/constant_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/copy_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/deep_copy_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/demo_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/eigenclass_rb.html +0 -103
- data/doc/api/core/files/lib/facets/core/kernel/false_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/fn_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/generate_method_name_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/get_by_id_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/here_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/in_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/instance_assign_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/instvar_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/is_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/maybe_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/metaclass_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/methods_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/nack_rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/kernel/new_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/object_class_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/object_hexid_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/op_esc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/own_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/p_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/pp_exception_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/quaclass_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/require_all_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/require_esc_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/require_facet_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/require_local_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/resc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/respond_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/returning_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/send_as_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/set_from_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/set_with_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/silence_warnings_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/silently_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/singleton_class_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/singleton_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/superior_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/supermethod_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/this_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/to_b_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/to_bool_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/true_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/unuri_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/uri_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/kernel/val_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/warn_with_line_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/with_accessor_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/kernel/with_reader_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/kernel/with_writer_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/logger/format_message_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/logger/format_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/matchdata/match_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/matchdata/matchset_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/matchdata/matchtree_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/abstract_rb.html +0 -105
- data/doc/api/core/files/lib/facets/core/module/alias_method_chain_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/alias_module_function_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/ancestor_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/attr_query_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/attr_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/attr_setter_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/attr_tester_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/attr_validator_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/basename_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/by_name_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/class_extension_rb.html +0 -124
- data/doc/api/core/files/lib/facets/core/module/class_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/clone_removing_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/module/clone_renaming_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/module/clone_using_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/dirname_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/equate_on_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/generate_instance_method_name_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/include_as_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/initializer_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/instance_methods_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/integrate_rb.html +0 -104
- data/doc/api/core/files/lib/facets/core/module/is_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/memoize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/modspace_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/module/namespace_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/nesting_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/nodef_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/on_included_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/redef_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/redefine_method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/redirect_method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/redirect_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/remove_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/rename_method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/rename_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/revisal_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/module/shadow_all_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/shadow_method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/sort_on_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/this_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/module/wrap_method_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/module/wrap_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/nil_as_emptiness_rb.html +0 -116
- data/doc/api/core/files/lib/facets/core/nilclass/blank_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/empty_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/include_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/length_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/nilclass/op_cmp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/op_fetch_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/size_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/status_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/succ_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/nilclass/to_h_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/numeric/approx_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/numeric/ceil_multiple_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/numeric/pred_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/numeric/succ_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/numeric/to_b_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/ostruct/__merge___rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/ostruct/__table___rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/ostruct/__update___rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/ostruct/instance_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/ostruct/op_fetch_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/ostruct/op_store_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/ostruct/to_h_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/ostruct_rb.html +0 -102
- data/doc/api/core/files/lib/facets/core/pathname/ascend_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/pathname/descend_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/proc/compose_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/proc/op_mul_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/proc/to_method_rb.html +0 -133
- data/doc/api/core/files/lib/facets/core/random_rb.html +0 -111
- data/doc/api/core/files/lib/facets/core/range/to_r_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/range/to_range_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/range/umbrella_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/range/within_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/regexp/arity_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/regexp/to_re_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/regexp/to_regexp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/align_center_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/align_left_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/align_right_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/at_rand_rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/string/at_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/basename_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/blank_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/bracket_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/brief_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/bytes_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/camelcase_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/camelize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/capitalized_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/chars_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/cmp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/demodulize_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/dequote_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/downcase_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/dresner_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/each_char_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/each_word_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/ends_with_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/first_char_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/first_rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/string/fold_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/format_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/humanize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/indent_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/index_all_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/last_char_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/last_rb.html +0 -98
- data/doc/api/core/files/lib/facets/core/string/line_wrap_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/lines_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/lowercase_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/margin_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/methodize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/modulize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/mscan_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/natcmp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/nchar_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/ordinal_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/pathize_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/plural_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/pop_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/pot_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/pull_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/push_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/quote_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/rand_byte_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/rand_index_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/range_all_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/range_of_line_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/range_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/regesc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/self/format_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/self/interpolate_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/self/patterns_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/self/rand_letter_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/self/random_rb.html +0 -99
- data/doc/api/core/files/lib/facets/core/string/shatter_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/shell_escape_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/shift_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/shuffle_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/similarity_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/singular_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/soundex_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/starts_with_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/succ_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/tab_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/tabto_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/to_a_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/to_b_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/to_const_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/to_date_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/string/to_proc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/to_re_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/to_rx_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/to_time_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/unbracket_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/underscore_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/unix_crypt_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/unpack_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/unshift_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/upcase_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/uppercase_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/string/whitespace_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/string/word_filter_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/word_wrap_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string/words_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/string_as_array_rb.html +0 -109
- data/doc/api/core/files/lib/facets/core/symbol/camelcase_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/camelize_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/capitalize_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/capitalized_rb.html +0 -97
- data/doc/api/core/files/lib/facets/core/symbol/downcase_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/not_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/symbol/pad_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/symbol/succ_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/symbol/to_const_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/to_proc_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/symbol/to_str_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/symbol/underscore_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/symbol/upcase_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/time/change_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/time/elapse_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/time/self/days_extrema_rb.html +0 -114
- data/doc/api/core/files/lib/facets/core/time/self/stamp_rb.html +0 -100
- data/doc/api/core/files/lib/facets/core/time/stamp_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/time/to_date_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/time/to_s_rb.html +0 -96
- data/doc/api/core/files/lib/facets/core/time/to_time_rb.html +0 -92
- data/doc/api/core/files/lib/facets/core/unboundmethod/name_rb.html +0 -92
- data/doc/api/core/fr_class_index.html +0 -81
- data/doc/api/core/fr_file_index.html +0 -521
- data/doc/api/core/fr_method_index.html +0 -559
- data/doc/api/core/index.html +0 -26
- data/doc/api/core/rdoc-style.css +0 -175
- data/doc/api/more/classes/Annotation.html +0 -258
- data/doc/api/more/classes/Array.html +0 -363
- data/doc/api/more/classes/Aspect.html +0 -159
- data/doc/api/more/classes/Aspects.html +0 -240
- data/doc/api/more/classes/Aspects/ClassMethods.html +0 -254
- data/doc/api/more/classes/Association.html +0 -289
- data/doc/api/more/classes/BBCode.html +0 -531
- data/doc/api/more/classes/BasicObject.html +0 -281
- data/doc/api/more/classes/BasicObject/Self.html +0 -143
- data/doc/api/more/classes/BinaryReader.html +0 -535
- data/doc/api/more/classes/BinaryReader/ByteOrder.html +0 -225
- data/doc/api/more/classes/BuilderObject.html +0 -248
- data/doc/api/more/classes/Class.html +0 -200
- data/doc/api/more/classes/Client.html +0 -1251
- data/doc/api/more/classes/Cloneable.html +0 -133
- data/doc/api/more/classes/Console.html +0 -105
- data/doc/api/more/classes/Console/ANSICode.html +0 -488
- data/doc/api/more/classes/Console/Command.html +0 -286
- data/doc/api/more/classes/Console/ProgressBar.html +0 -640
- data/doc/api/more/classes/Coroutine.html +0 -284
- data/doc/api/more/classes/Crypt.html +0 -270
- data/doc/api/more/classes/DebugSocket.html +0 -242
- data/doc/api/more/classes/Dictionary.html +0 -974
- data/doc/api/more/classes/Downloader.html +0 -515
- data/doc/api/more/classes/Downloader/Checksum.html +0 -96
- data/doc/api/more/classes/Downloader/Mirror.html +0 -134
- data/doc/api/more/classes/Elementor.html +0 -202
- data/doc/api/more/classes/Enumerable.html +0 -86
- data/doc/api/more/classes/EnumerablePass.html +0 -217
- data/doc/api/more/classes/Expirable.html +0 -197
- data/doc/api/more/classes/FalseClass.html +0 -119
- data/doc/api/more/classes/FileList.html +0 -971
- data/doc/api/more/classes/Float.html +0 -141
- data/doc/api/more/classes/FloatString.html +0 -413
- data/doc/api/more/classes/Functor.html +0 -224
- data/doc/api/more/classes/HTMLBuilder.html +0 -132
- data/doc/api/more/classes/HTMLHelper.html +0 -189
- data/doc/api/more/classes/HTTP.html +0 -154
- data/doc/api/more/classes/HTTP/BadResponseError.html +0 -94
- data/doc/api/more/classes/HTTP/Error.html +0 -96
- data/doc/api/more/classes/HTTP/Message.html +0 -633
- data/doc/api/more/classes/HTTP/Message/Body.html +0 -299
- data/doc/api/more/classes/HTTP/Message/Headers.html +0 -641
- data/doc/api/more/classes/HTTP/Status.html +0 -148
- data/doc/api/more/classes/HTTPAccess.html +0 -115
- data/doc/api/more/classes/Hash.html +0 -257
- data/doc/api/more/classes/HashBuilder.html +0 -216
- data/doc/api/more/classes/Heap.html +0 -535
- data/doc/api/more/classes/Heap/EmptyHeapException.html +0 -92
- data/doc/api/more/classes/Heap/Max.html +0 -133
- data/doc/api/more/classes/Heap/Min.html +0 -133
- data/doc/api/more/classes/IORedirect.html +0 -224
- data/doc/api/more/classes/Integer.html +0 -299
- data/doc/api/more/classes/Interval.html +0 -853
- data/doc/api/more/classes/InvalidNackError.html +0 -117
- data/doc/api/more/classes/JSON.html +0 -410
- data/doc/api/more/classes/JSON/Parser.html +0 -374
- data/doc/api/more/classes/JSON/State.html +0 -280
- data/doc/api/more/classes/Kernel.html +0 -400
- data/doc/api/more/classes/LRUCache.html +0 -461
- data/doc/api/more/classes/LRUCache/Item.html +0 -114
- data/doc/api/more/classes/LRUCache/Sentinel.html +0 -102
- data/doc/api/more/classes/Lazy.html +0 -96
- data/doc/api/more/classes/Lazy/Future.html +0 -100
- data/doc/api/more/classes/Lazy/Promise.html +0 -114
- data/doc/api/more/classes/Lazy/PromiseSafe.html +0 -99
- data/doc/api/more/classes/Lisp.html +0 -846
- data/doc/api/more/classes/Lisp/DottedPair.html +0 -289
- data/doc/api/more/classes/Lisp/Format.html +0 -147
- data/doc/api/more/classes/Math.html +0 -110
- data/doc/api/more/classes/Math/Constants.html +0 -691
- data/doc/api/more/classes/Math/Constants/CGS.html +0 -584
- data/doc/api/more/classes/Method.html +0 -170
- data/doc/api/more/classes/Method/Probe.html +0 -267
- data/doc/api/more/classes/Mock.html +0 -276
- data/doc/api/more/classes/Module.html +0 -599
- data/doc/api/more/classes/Multiton.html +0 -256
- data/doc/api/more/classes/NackClass.html +0 -245
- data/doc/api/more/classes/NilClass.html +0 -238
- data/doc/api/more/classes/NullClass.html +0 -202
- data/doc/api/more/classes/Numeric.html +0 -1104
- data/doc/api/more/classes/ORMSupport.html +0 -357
- data/doc/api/more/classes/Object.html +0 -328
- data/doc/api/more/classes/OpenCascade.html +0 -230
- data/doc/api/more/classes/OpenObject.html +0 -552
- data/doc/api/more/classes/PQueue.html +0 -471
- data/doc/api/more/classes/PathList.html +0 -162
- data/doc/api/more/classes/PathList/Finder.html +0 -137
- data/doc/api/more/classes/Pool.html +0 -207
- data/doc/api/more/classes/Proc.html +0 -140
- data/doc/api/more/classes/PromoteSelf.html +0 -138
- data/doc/api/more/classes/Quaternion.html +0 -1497
- data/doc/api/more/classes/REXMLBuilder.html +0 -357
- data/doc/api/more/classes/REXMLBuilder/REXMLUtil.html +0 -396
- data/doc/api/more/classes/Recorder.html +0 -208
- data/doc/api/more/classes/Reference.html +0 -201
- data/doc/api/more/classes/RubyOneLiners.html +0 -139
- data/doc/api/more/classes/RubyTals.html +0 -316
- data/doc/api/more/classes/SSLSocketWrap.html +0 -410
- data/doc/api/more/classes/Semaphore.html +0 -264
- data/doc/api/more/classes/SimpleStringIO.html +0 -139
- data/doc/api/more/classes/Snapshot.html +0 -191
- data/doc/api/more/classes/StateMachine.html +0 -248
- data/doc/api/more/classes/StateParser.html +0 -276
- data/doc/api/more/classes/StateParser/Constants.html +0 -109
- data/doc/api/more/classes/StateParser/Marker.html +0 -269
- data/doc/api/more/classes/StateParser/State.html +0 -448
- data/doc/api/more/classes/StaticHash.html +0 -144
- data/doc/api/more/classes/String.html +0 -300
- data/doc/api/more/classes/Struct.html +0 -134
- data/doc/api/more/classes/Symbol.html +0 -118
- data/doc/api/more/classes/SyncArray.html +0 -131
- data/doc/api/more/classes/SyncHash.html +0 -135
- data/doc/api/more/classes/SyncHash/Delegator.html +0 -213
- data/doc/api/more/classes/SyncHash/Inheritor.html +0 -213
- data/doc/api/more/classes/System.html +0 -1055
- data/doc/api/more/classes/TSort.html +0 -123
- data/doc/api/more/classes/TagIterator.html +0 -706
- data/doc/api/more/classes/Task.html +0 -237
- data/doc/api/more/classes/Task/Graph.html +0 -165
- data/doc/api/more/classes/Taskable.html +0 -300
- data/doc/api/more/classes/Time.html +0 -746
- data/doc/api/more/classes/Timer.html +0 -471
- data/doc/api/more/classes/Timer/Dummy.html +0 -141
- data/doc/api/more/classes/TracePoint.html +0 -456
- data/doc/api/more/classes/TrueClass.html +0 -118
- data/doc/api/more/classes/Tuple.html +0 -907
- data/doc/api/more/classes/TypeCastException.html +0 -163
- data/doc/api/more/classes/Uninheritable.html +0 -130
- data/doc/api/more/classes/Units.html +0 -191
- data/doc/api/more/classes/Units/Config.html +0 -120
- data/doc/api/more/classes/Units/Converter.html +0 -808
- data/doc/api/more/classes/Units/Converter/ExchangeRate.html +0 -155
- data/doc/api/more/classes/Units/Converter/ExchangeRate/CachedXMethods.html +0 -143
- data/doc/api/more/classes/Units/Converter/ExchangeRate/XMethods.html +0 -197
- data/doc/api/more/classes/Units/Unit.html +0 -434
- data/doc/api/more/classes/Units/Value.html +0 -331
- data/doc/api/more/classes/ValueHolder.html +0 -167
- data/doc/api/more/classes/Web.html +0 -103
- data/doc/api/more/classes/Web/Cookie.html +0 -560
- data/doc/api/more/classes/Web/CookieManager.html +0 -567
- data/doc/api/more/classes/Web/CookieManager/Error.html +0 -96
- data/doc/api/more/classes/Web/CookieManager/ErrorOverrideOK.html +0 -94
- data/doc/api/more/classes/Web/CookieManager/NoDotError.html +0 -94
- data/doc/api/more/classes/Web/CookieManager/SpecialError.html +0 -94
- data/doc/api/more/classes/Web/CookieUtils.html +0 -179
- data/doc/api/more/classes/XMLBuilder.html +0 -132
- data/doc/api/more/classes/XMLHelper.html +0 -428
- data/doc/api/more/classes/XOXO.html +0 -251
- data/doc/api/more/classes/YAMLStruct.html +0 -166
- data/doc/api/more/created.rid +0 -1
- data/doc/api/more/files/COPYING.html +0 -517
- data/doc/api/more/files/README.html +0 -389
- data/doc/api/more/files/lib/facets/more/annattr_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/annotation_rb.html +0 -117
- data/doc/api/more/files/lib/facets/more/ansicode_rb.html +0 -128
- data/doc/api/more/files/lib/facets/more/aspects_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/association_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/basicobject_rb.html +0 -129
- data/doc/api/more/files/lib/facets/more/bbcode_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/binaryreader_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/bitmask_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/blankslate_rb.html +0 -113
- data/doc/api/more/files/lib/facets/more/builderobject_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/bytes_rb.html +0 -131
- data/doc/api/more/files/lib/facets/more/classmethods_rb.html +0 -121
- data/doc/api/more/files/lib/facets/more/cloneable_rb.html +0 -132
- data/doc/api/more/files/lib/facets/more/command_rb.html +0 -119
- data/doc/api/more/files/lib/facets/more/cookie_rb.html +0 -136
- data/doc/api/more/files/lib/facets/more/coroutine_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/crypt_rb.html +0 -146
- data/doc/api/more/files/lib/facets/more/dictionary_rb.html +0 -123
- data/doc/api/more/files/lib/facets/more/downloader_rb.html +0 -124
- data/doc/api/more/files/lib/facets/more/elementor_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/enumerablepass_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/expirable_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/filelist_rb.html +0 -128
- data/doc/api/more/files/lib/facets/more/floatstring_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/functor_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/hashbuilder_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/heap_rb.html +0 -131
- data/doc/api/more/files/lib/facets/more/htmlbuilder_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/htmlhelper_rb.html +0 -119
- data/doc/api/more/files/lib/facets/more/http_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/httpaccess_rb.html +0 -137
- data/doc/api/more/files/lib/facets/more/inheritor_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/interval_rb.html +0 -120
- data/doc/api/more/files/lib/facets/more/ioredirect_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/json_rb.html +0 -141
- data/doc/api/more/files/lib/facets/more/lazy_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/lisp_format_rb.html +0 -129
- data/doc/api/more/files/lib/facets/more/lisp_rb.html +0 -119
- data/doc/api/more/files/lib/facets/more/lrucache_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/mathconstants_rb.html +0 -121
- data/doc/api/more/files/lib/facets/more/methodprobe_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/mock_rb.html +0 -208
- data/doc/api/more/files/lib/facets/more/multipliers_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/multiton_rb.html +0 -114
- data/doc/api/more/files/lib/facets/more/nackclass_rb.html +0 -151
- data/doc/api/more/files/lib/facets/more/nilcomparable_rb.html +0 -118
- data/doc/api/more/files/lib/facets/more/nullclass_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/one_rb.html +0 -158
- data/doc/api/more/files/lib/facets/more/opencascade_rb.html +0 -129
- data/doc/api/more/files/lib/facets/more/openobject_rb.html +0 -120
- data/doc/api/more/files/lib/facets/more/orderedhash_rb.html +0 -113
- data/doc/api/more/files/lib/facets/more/ormsupport_rb.html +0 -125
- data/doc/api/more/files/lib/facets/more/overload_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/paramix_rb.html +0 -118
- data/doc/api/more/files/lib/facets/more/pathlist_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/pool_rb.html +0 -120
- data/doc/api/more/files/lib/facets/more/pqueue_rb.html +0 -122
- data/doc/api/more/files/lib/facets/more/preinitialize_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/progressbar_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/promoteself_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/quaternion_rb.html +0 -150
- data/doc/api/more/files/lib/facets/more/recorder_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/reference_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/rexmlbuilder_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/rtals_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/semaphore_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/snapshot_rb.html +0 -121
- data/doc/api/more/files/lib/facets/more/stateparser_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/statichash_rb.html +0 -133
- data/doc/api/more/files/lib/facets/more/syncarray_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/synchash_rb.html +0 -115
- data/doc/api/more/files/lib/facets/more/system_rb.html +0 -123
- data/doc/api/more/files/lib/facets/more/tagiterator_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/taskable_rb.html +0 -118
- data/doc/api/more/files/lib/facets/more/timer_rb.html +0 -127
- data/doc/api/more/files/lib/facets/more/times_rb.html +0 -127
- data/doc/api/more/files/lib/facets/more/tracepoint_rb.html +0 -131
- data/doc/api/more/files/lib/facets/more/tuple_rb.html +0 -122
- data/doc/api/more/files/lib/facets/more/typecast_rb.html +0 -133
- data/doc/api/more/files/lib/facets/more/uninheritable_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/units_rb.html +0 -118
- data/doc/api/more/files/lib/facets/more/xmlbuilder_rb.html +0 -116
- data/doc/api/more/files/lib/facets/more/xmlhelper_rb.html +0 -111
- data/doc/api/more/files/lib/facets/more/xoxo_rb.html +0 -125
- data/doc/api/more/files/lib/facets/more/yamlstruct_rb.html +0 -123
- data/doc/api/more/fr_class_index.html +0 -196
- data/doc/api/more/fr_file_index.html +0 -133
- data/doc/api/more/fr_method_index.html +0 -1284
- data/doc/api/more/index.html +0 -26
- data/doc/api/more/rdoc-style.css +0 -175
- data/doc/web/documentation.html +0 -174
- data/doc/web/images/abc.png +0 -0
- data/doc/web/images/abc1.png +0 -0
- data/doc/web/images/apple_core.jpg +0 -0
- data/doc/web/images/apples3.jpg +0 -0
- data/doc/web/images/core.jpg +0 -0
- data/doc/web/images/favicon.ico +0 -0
- data/doc/web/images/gray.jpg +0 -0
- data/doc/web/images/ruby-lg.png +0 -0
- data/doc/web/images/ruby.gif +0 -0
- data/doc/web/images/three_apples.jpg +0 -0
- data/doc/web/images/yellow_fade.jpg +0 -0
- data/doc/web/images/yellow_fade2.jpg +0 -0
- data/doc/web/index.html +0 -224
- data/doc/web/style.css +0 -153
- data/lib/facet/blankslate.rb +0 -1
- data/lib/facet/hash/symoblize_keys.rb +0 -1
- data/lib/facet/kernel/generate_method_name.rb +0 -1
- data/lib/facet/module/generate_instance_method_name.rb +0 -1
- data/lib/facets/core/hash/symoblize_keys.rb +0 -2
- data/lib/facets/core/kernel/generate_method_name.rb +0 -39
- data/lib/facets/core/module/generate_instance_method_name.rb +0 -47
- data/lib/facets/more/blankslate.rb +0 -7
- data/proj/calibre/ProjectInfo.annotation +0 -46
- data/proj/calibre/ProjectInfo.ansicode +0 -33
- data/proj/calibre/ProjectInfo.asociation +0 -34
- data/proj/calibre/ProjectInfo.basicobject +0 -36
- data/proj/calibre/ProjectInfo.bbcode +0 -34
- data/proj/calibre/ProjectInfo.binaryreader +0 -35
- data/proj/calibre/ProjectInfo.bitmask +0 -33
- data/proj/calibre/ProjectInfo.classinherit +0 -36
- data/proj/calibre/ProjectInfo.classmethods +0 -36
- data/proj/calibre/ProjectInfo.cloneable +0 -33
- data/proj/calibre/ProjectInfo.consoleapp +0 -35
- data/proj/calibre/ProjectInfo.coroutine +0 -37
- data/proj/calibre/ProjectInfo.crypt +0 -33
- data/proj/calibre/ProjectInfo.dictionary +0 -40
- data/proj/calibre/ProjectInfo.downloader +0 -39
- data/proj/calibre/ProjectInfo.enumerablepass +0 -35
- data/proj/calibre/ProjectInfo.expirable +0 -37
- data/proj/calibre/ProjectInfo.floatstring +0 -35
- data/proj/calibre/ProjectInfo.functor +0 -40
- data/proj/calibre/ProjectInfo.heap +0 -33
- data/proj/calibre/ProjectInfo.inheritor +0 -36
- data/proj/calibre/ProjectInfo.interval +0 -36
- data/proj/calibre/ProjectInfo.lisp +0 -38
- data/proj/calibre/ProjectInfo.lrucache +0 -34
- data/proj/calibre/ProjectInfo.mathconstants +0 -41
- data/proj/calibre/ProjectInfo.methodprobe +0 -38
- data/proj/calibre/ProjectInfo.mock +0 -34
- data/proj/calibre/ProjectInfo.multiton +0 -36
- data/proj/calibre/ProjectInfo.nackclass +0 -33
- data/proj/calibre/ProjectInfo.nilcomparable +0 -35
- data/proj/calibre/ProjectInfo.nullclass +0 -35
- data/proj/calibre/ProjectInfo.one +0 -37
- data/proj/calibre/ProjectInfo.openobject +0 -39
- data/proj/calibre/ProjectInfo.paramix +0 -38
- data/proj/calibre/ProjectInfo.pool +0 -33
- data/proj/calibre/ProjectInfo.progressbar +0 -37
- data/proj/calibre/ProjectInfo.reference +0 -36
- data/proj/calibre/ProjectInfo.semaphore +0 -36
- data/proj/calibre/ProjectInfo.stateparser +0 -39
- data/proj/calibre/ProjectInfo.statichash +0 -33
- data/proj/calibre/ProjectInfo.system +0 -34
- data/proj/calibre/ProjectInfo.tagiterator +0 -36
- data/proj/calibre/ProjectInfo.timer +0 -35
- data/proj/calibre/ProjectInfo.tracepoint +0 -37
- data/proj/calibre/ProjectInfo.tuple +0 -36
- data/proj/calibre/ProjectInfo.uniheritable +0 -34
- data/proj/calibre/ProjectInfo.units +0 -34
- data/proj/calibre/ProjectInfo.yamlstruct +0 -34
- data/proj/info +0 -117
- data/proj/metadata +0 -36
- data/proj/tasks/calibre.rb +0 -15
- data/snip/ProjectInfo +0 -115
- data/snip/README +0 -13
- data/snip/TODO +0 -73
- data/snip/autorequire.rb +0 -83
- data/snip/core/array/at_rand.rb +0 -95
- data/snip/core/array/each_slice.rb +0 -23
- data/snip/core/array/pick_values.rb +0 -32
- data/snip/core/array/rand_indexes.rb +0 -33
- data/snip/core/binding/class.rb +0 -11
- data/snip/core/binding/delegate-binding.rb +0 -19
- data/snip/core/binding/delegate.rb +0 -15
- data/snip/core/binding/proc.rb +0 -6
- data/snip/core/class/to_module.rb +0 -3
- data/snip/core/enumerable/op_fetch.rb +0 -30
- data/snip/core/fileutils/nl_convert.rb +0 -133
- data/snip/core/io/expect.rb +0 -127
- data/snip/core/kernel/__clone__.rb +0 -4
- data/snip/core/kernel/__dup__.rb +0 -4
- data/snip/core/kernel/call_line.rb +0 -15
- data/snip/core/kernel/does.rb +0 -7
- data/snip/core/kernel/message.rb +0 -6
- data/snip/core/kernel/query.rb +0 -15
- data/snip/core/kernel/taint.rb +0 -10
- data/snip/core/logger/clean_logger.rb +0 -10
- data/snip/core/module/attr-old.rb +0 -308
- data/snip/core/module/attr.rb +0 -98
- data/snip/core/module/attr_xxx.rb +0 -22
- data/snip/core/module/by_regexp.rb +0 -21
- data/snip/core/module/cast.rb +0 -64
- data/snip/core/module/class_attribute_accessors.rb +0 -57
- data/snip/core/module/inherit.rb +0 -99
- data/snip/core/module/inherit0.rb +0 -59
- data/snip/core/module/let.rb +0 -51
- data/snip/core/module/meta_attr.rb +0 -60
- data/snip/core/module/module_attribute_accessors.rb +0 -57
- data/snip/core/module/permissions.rb +0 -32
- data/snip/core/module/preserved.rb +0 -108
- data/snip/core/module/sattr_accessor.rb +0 -1
- data/snip/core/module/sattr_reader.rb +0 -1
- data/snip/core/module/sattr_setter.rb +0 -1
- data/snip/core/module/sattr_tester.rb +0 -1
- data/snip/core/module/sattr_writer.rb +0 -1
- data/snip/core/module/tc_attr.rb +0 -107
- data/snip/core/module/to_module.rb +0 -37
- data/snip/core/module/version.rb +0 -23
- data/snip/core/string/frequency.rb +0 -40
- data/snip/core/string/op_add.rb +0 -24
- data/snip/core/string/op_div.rb +0 -15
- data/snip/core/string/pred.rb +0 -217
- data/snip/core/string/probability.rb +0 -35
- data/snip/core/string/to_arr.rb +0 -57
- data/snip/core/string/to_ary.rb +0 -12
- data/snip/core/string/word_wrap.rb +0 -62
- data/snip/more/actionplan.rb +0 -21
- data/snip/more/autoarray.rb +0 -29
- data/snip/more/cache.rb +0 -189
- data/snip/more/capsule2.rb +0 -152
- data/snip/more/class_inheritable_attributes.rb +0 -120
- data/snip/more/classinherit.rb +0 -198
- data/snip/more/clean.rb +0 -35
- data/snip/more/codepack.rb +0 -64
- data/snip/more/commandrunner.rb +0 -101
- data/snip/more/conditionals.rb +0 -106
- data/snip/more/contracts.rb +0 -37
- data/snip/more/daemon.rb +0 -70
- data/snip/more/datetime.rb +0 -42
- data/snip/more/detach.rb +0 -423
- data/snip/more/enumtype.rb +0 -115
- data/snip/more/fixnum_const.rb +0 -55
- data/snip/more/function.rb +0 -278
- data/snip/more/hookse.rb +0 -107
- data/snip/more/indexable.rb +0 -85
- data/snip/more/infinity.rb +0 -123
- data/snip/more/ioreactor.rb +0 -671
- data/snip/more/knowself.rb +0 -42
- data/snip/more/logger_sing.rb +0 -207
- data/snip/more/must.rb +0 -37
- data/snip/more/openproxy.rb +0 -245
- data/snip/more/ostructable.rb +0 -212
- data/snip/more/pairhash.rb +0 -55
- data/snip/more/pathname.rb +0 -1309
- data/snip/more/prereq.rb +0 -36
- data/snip/more/print_exception.rb +0 -35
- data/snip/more/rand.rb +0 -412
- data/snip/more/range.rb +0 -383
- data/snip/more/sanitize.rb +0 -48
- data/snip/more/service.rb +0 -266
- data/snip/more/superstruct.rb +0 -735
- data/snip/more/tag.rb +0 -27
- data/snip/more/testfacility.rb +0 -80
- data/snip/more/timer.rb +0 -164
- data/snip/more/toplevel.rb +0 -76
- data/snip/more/type.rb +0 -232
- data/snip/more/vars.rb +0 -94
- data/snip/more/version.rb +0 -245
- data/snip/more/world.rb +0 -53
- data/snip/reference/sys.rb +0 -186
- data/snip/reference/utils.rb +0 -518
- data/test/lib/facets/core/kernel/test_generate_method_name.rb +0 -26
- data/test/lib/facets/core/module/test_generate_instance_method_name.rb +0 -33
@@ -1,353 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
-
<!DOCTYPE html
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
-
<html>
|
6
|
-
<head>
|
7
|
-
<title>Class: Integer</title>
|
8
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
9
|
-
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
10
|
-
|
11
|
-
<script language="JavaScript" type="text/javascript">
|
12
|
-
// <![CDATA[
|
13
|
-
|
14
|
-
function toggleSource( id )
|
15
|
-
{
|
16
|
-
var elem
|
17
|
-
var link
|
18
|
-
|
19
|
-
if( document.getElementById )
|
20
|
-
{
|
21
|
-
elem = document.getElementById( id )
|
22
|
-
link = document.getElementById( "l_" + id )
|
23
|
-
}
|
24
|
-
else if ( document.all )
|
25
|
-
{
|
26
|
-
elem = eval( "document.all." + id )
|
27
|
-
link = eval( "document.all.l_" + id )
|
28
|
-
}
|
29
|
-
else
|
30
|
-
return false;
|
31
|
-
|
32
|
-
if( elem.style.display == "block" )
|
33
|
-
{
|
34
|
-
elem.style.display = "none"
|
35
|
-
link.innerHTML = "show source"
|
36
|
-
}
|
37
|
-
else
|
38
|
-
{
|
39
|
-
elem.style.display = "block"
|
40
|
-
link.innerHTML = "hide source"
|
41
|
-
}
|
42
|
-
}
|
43
|
-
|
44
|
-
function openCode( url )
|
45
|
-
{
|
46
|
-
window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
|
47
|
-
}
|
48
|
-
// ]]>
|
49
|
-
</script>
|
50
|
-
</head>
|
51
|
-
|
52
|
-
<body>
|
53
|
-
<table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
|
54
|
-
<td class="file-title"><span class="file-title-prefix">Class</span><br />Integer</td>
|
55
|
-
<td align="right">
|
56
|
-
<table cellspacing=0 cellpadding=2>
|
57
|
-
<tr valign="top">
|
58
|
-
<td>In:</td>
|
59
|
-
<td>
|
60
|
-
<a href="../files/lib/facets/core/float/round_at_rb.html">lib/facets/core/float/round_at.rb</a>
|
61
|
-
<a href="../files/lib/facets/core/float/round_to_rb.html">lib/facets/core/float/round_to.rb</a>
|
62
|
-
<a href="../files/lib/facets/core/integer/multiple_rb.html">lib/facets/core/integer/multiple.rb</a>
|
63
|
-
<a href="../files/lib/facets/core/integer/times_collect_rb.html">lib/facets/core/integer/times_collect.rb</a>
|
64
|
-
<a href="../files/lib/facets/core/integer/factorial_rb.html">lib/facets/core/integer/factorial.rb</a>
|
65
|
-
<a href="../files/lib/facets/core/integer/ordinal_rb.html">lib/facets/core/integer/ordinal.rb</a>
|
66
|
-
<a href="../files/lib/facets/core/numeric/succ_rb.html">lib/facets/core/numeric/succ.rb</a>
|
67
|
-
</td>
|
68
|
-
</tr>
|
69
|
-
<tr>
|
70
|
-
<td>Parent:</td>
|
71
|
-
<td>
|
72
|
-
<a href="Object.html">
|
73
|
-
Object
|
74
|
-
</a>
|
75
|
-
</td>
|
76
|
-
</tr>
|
77
|
-
</table>
|
78
|
-
</td>
|
79
|
-
</tr>
|
80
|
-
</table>
|
81
|
-
<!-- banner header -->
|
82
|
-
|
83
|
-
<div id="bodyContent">
|
84
|
-
<div id="content">
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
<div class="sectiontitle">Methods</div>
|
90
|
-
<ul>
|
91
|
-
<li><a href="#M000009">even?</a></li>
|
92
|
-
<li><a href="#M000014">fac</a></li>
|
93
|
-
<li><a href="#M000015">fact</a></li>
|
94
|
-
<li><a href="#M000013">factorial</a></li>
|
95
|
-
<li><a href="#M000010">multiple?</a></li>
|
96
|
-
<li><a href="#M000008">odd?</a></li>
|
97
|
-
<li><a href="#M000016">ordinal</a></li>
|
98
|
-
<li><a href="#M000006">round_at</a></li>
|
99
|
-
<li><a href="#M000007">round_to</a></li>
|
100
|
-
<li><a href="#M000011">times_collect</a></li>
|
101
|
-
<li><a href="#M000012">times_map</a></li>
|
102
|
-
</ul>
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
<div class="sectiontitle">Public Instance methods</div>
|
110
|
-
<div class="method">
|
111
|
-
<div class="title">
|
112
|
-
<a name="M000009"></a><b>even?</b>()
|
113
|
-
</div>
|
114
|
-
<div class="description">
|
115
|
-
<p>
|
116
|
-
Is an integer even?
|
117
|
-
</p>
|
118
|
-
<pre>
|
119
|
-
2.even? #=> true
|
120
|
-
3.even? #=> false
|
121
|
-
</pre>
|
122
|
-
</div>
|
123
|
-
<div class="sourcecode">
|
124
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000009_source')" id="l_M000009_source">show source</a> ]</p>
|
125
|
-
<div id="M000009_source" class="dyn-source">
|
126
|
-
<pre>
|
127
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/multiple.rb, line 18</span>
|
128
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">even?</span>
|
129
|
-
<span class="ruby-keyword kw">self</span> <span class="ruby-operator">%</span> <span class="ruby-value">2</span> <span class="ruby-operator">==</span> <span class="ruby-value">0</span>
|
130
|
-
<span class="ruby-keyword kw">end</span>
|
131
|
-
</pre>
|
132
|
-
</div>
|
133
|
-
</div>
|
134
|
-
</div>
|
135
|
-
<div class="method">
|
136
|
-
<div class="title">
|
137
|
-
<a name="M000014"></a><b>fac</b>()
|
138
|
-
</div>
|
139
|
-
<div class="description">
|
140
|
-
<p>
|
141
|
-
Alias for <a href="Integer.html#M000013">factorial</a>
|
142
|
-
</p>
|
143
|
-
</div>
|
144
|
-
</div>
|
145
|
-
<div class="method">
|
146
|
-
<div class="title">
|
147
|
-
<a name="M000015"></a><b>fact</b>()
|
148
|
-
</div>
|
149
|
-
<div class="description">
|
150
|
-
<p>
|
151
|
-
Alias for <a href="Integer.html#M000013">factorial</a>
|
152
|
-
</p>
|
153
|
-
</div>
|
154
|
-
</div>
|
155
|
-
<div class="method">
|
156
|
-
<div class="title">
|
157
|
-
<a name="M000013"></a><b>factorial</b>()
|
158
|
-
</div>
|
159
|
-
<div class="description">
|
160
|
-
<p>
|
161
|
-
Calculate the factorial of an integer.
|
162
|
-
</p>
|
163
|
-
<pre>
|
164
|
-
2.factorial #=> 2
|
165
|
-
3.factorial #=> 6
|
166
|
-
3.factorial #=> 24
|
167
|
-
</pre>
|
168
|
-
</div>
|
169
|
-
<div class="aka">
|
170
|
-
This method is also aliased as
|
171
|
-
<a href="Integer.html#M000014">fac</a>
|
172
|
-
<a href="Integer.html#M000015">fact</a>
|
173
|
-
</div>
|
174
|
-
<div class="sourcecode">
|
175
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000013_source')" id="l_M000013_source">show source</a> ]</p>
|
176
|
-
<div id="M000013_source" class="dyn-source">
|
177
|
-
<pre>
|
178
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/factorial.rb, line 14</span>
|
179
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">factorial</span>
|
180
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-value">1</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">zero?</span>
|
181
|
-
<span class="ruby-identifier">f</span> = <span class="ruby-value">1</span>
|
182
|
-
<span class="ruby-value">2</span>.<span class="ruby-identifier">upto</span>(<span class="ruby-keyword kw">self</span>) { <span class="ruby-operator">|</span><span class="ruby-identifier">n</span><span class="ruby-operator">|</span> <span class="ruby-identifier">f</span> <span class="ruby-operator">*=</span> <span class="ruby-identifier">n</span> }
|
183
|
-
<span class="ruby-identifier">f</span>
|
184
|
-
<span class="ruby-keyword kw">end</span>
|
185
|
-
</pre>
|
186
|
-
</div>
|
187
|
-
</div>
|
188
|
-
</div>
|
189
|
-
<div class="method">
|
190
|
-
<div class="title">
|
191
|
-
<a name="M000010"></a><b>multiple?</b>(number)
|
192
|
-
</div>
|
193
|
-
<div class="description">
|
194
|
-
<p>
|
195
|
-
Is is a multiple of a given number?
|
196
|
-
</p>
|
197
|
-
<pre>
|
198
|
-
7.multiple?(2) #=> false
|
199
|
-
8.multiple?(2) #=> true
|
200
|
-
</pre>
|
201
|
-
</div>
|
202
|
-
<div class="sourcecode">
|
203
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000010_source')" id="l_M000010_source">show source</a> ]</p>
|
204
|
-
<div id="M000010_source" class="dyn-source">
|
205
|
-
<pre>
|
206
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/multiple.rb, line 27</span>
|
207
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">multiple?</span>(<span class="ruby-identifier">number</span>)
|
208
|
-
<span class="ruby-keyword kw">self</span> <span class="ruby-operator">%</span> <span class="ruby-identifier">number</span> <span class="ruby-operator">==</span> <span class="ruby-value">0</span>
|
209
|
-
<span class="ruby-keyword kw">end</span>
|
210
|
-
</pre>
|
211
|
-
</div>
|
212
|
-
</div>
|
213
|
-
</div>
|
214
|
-
<div class="method">
|
215
|
-
<div class="title">
|
216
|
-
<a name="M000008"></a><b>odd?</b>()
|
217
|
-
</div>
|
218
|
-
<div class="description">
|
219
|
-
<p>
|
220
|
-
Is an integer odd?
|
221
|
-
</p>
|
222
|
-
<pre>
|
223
|
-
2.odd? #=> false
|
224
|
-
3.odd? #=> true
|
225
|
-
</pre>
|
226
|
-
</div>
|
227
|
-
<div class="sourcecode">
|
228
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000008_source')" id="l_M000008_source">show source</a> ]</p>
|
229
|
-
<div id="M000008_source" class="dyn-source">
|
230
|
-
<pre>
|
231
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/multiple.rb, line 9</span>
|
232
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">odd?</span>
|
233
|
-
<span class="ruby-keyword kw">self</span> <span class="ruby-operator">%</span> <span class="ruby-value">2</span> <span class="ruby-operator">==</span> <span class="ruby-value">1</span>
|
234
|
-
<span class="ruby-keyword kw">end</span>
|
235
|
-
</pre>
|
236
|
-
</div>
|
237
|
-
</div>
|
238
|
-
</div>
|
239
|
-
<div class="method">
|
240
|
-
<div class="title">
|
241
|
-
<a name="M000016"></a><b>ordinal</b>()
|
242
|
-
</div>
|
243
|
-
<div class="sourcecode">
|
244
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000016_source')" id="l_M000016_source">show source</a> ]</p>
|
245
|
-
<div id="M000016_source" class="dyn-source">
|
246
|
-
<pre>
|
247
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/ordinal.rb, line 4</span>
|
248
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">ordinal</span>
|
249
|
-
<span class="ruby-keyword kw">if</span> (<span class="ruby-value">11</span><span class="ruby-operator">..</span><span class="ruby-value">13</span>).<span class="ruby-identifier">include?</span>(<span class="ruby-keyword kw">self</span> <span class="ruby-operator">%</span> <span class="ruby-value">100</span>)
|
250
|
-
<span class="ruby-node">"#{self}th"</span>
|
251
|
-
<span class="ruby-keyword kw">else</span>
|
252
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-keyword kw">self</span> <span class="ruby-operator">%</span> <span class="ruby-value">10</span>
|
253
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value">1</span><span class="ruby-operator">:</span> <span class="ruby-node">"#{self}st"</span>
|
254
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value">2</span><span class="ruby-operator">:</span> <span class="ruby-node">"#{self}nd"</span>
|
255
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value">3</span><span class="ruby-operator">:</span> <span class="ruby-node">"#{self}rd"</span>
|
256
|
-
<span class="ruby-keyword kw">else</span> <span class="ruby-node">"#{self}th"</span>
|
257
|
-
<span class="ruby-keyword kw">end</span>
|
258
|
-
<span class="ruby-keyword kw">end</span>
|
259
|
-
<span class="ruby-keyword kw">end</span>
|
260
|
-
</pre>
|
261
|
-
</div>
|
262
|
-
</div>
|
263
|
-
</div>
|
264
|
-
<div class="method">
|
265
|
-
<div class="title">
|
266
|
-
<a name="M000006"></a><b>round_at</b>(*args)
|
267
|
-
</div>
|
268
|
-
<div class="description">
|
269
|
-
<p>
|
270
|
-
To properly support <a href="Float.html">Float</a>’s rounding
|
271
|
-
methods, <a href="Integer.html">Integer</a> must also be augmented.
|
272
|
-
</p>
|
273
|
-
</div>
|
274
|
-
<div class="sourcecode">
|
275
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000006_source')" id="l_M000006_source">show source</a> ]</p>
|
276
|
-
<div id="M000006_source" class="dyn-source">
|
277
|
-
<pre>
|
278
|
-
<span class="ruby-comment cmt"># File lib/facets/core/float/round_at.rb, line 29</span>
|
279
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">round_at</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
280
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">to_f</span>.<span class="ruby-identifier">round_at</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
281
|
-
<span class="ruby-keyword kw">end</span>
|
282
|
-
</pre>
|
283
|
-
</div>
|
284
|
-
</div>
|
285
|
-
</div>
|
286
|
-
<div class="method">
|
287
|
-
<div class="title">
|
288
|
-
<a name="M000007"></a><b>round_to</b>(*args)
|
289
|
-
</div>
|
290
|
-
<div class="description">
|
291
|
-
<p>
|
292
|
-
To properly support <a href="Float.html">Float</a>’s rounding
|
293
|
-
methods, <a href="Integer.html">Integer</a> must also be augmented.
|
294
|
-
</p>
|
295
|
-
</div>
|
296
|
-
<div class="sourcecode">
|
297
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000007_source')" id="l_M000007_source">show source</a> ]</p>
|
298
|
-
<div id="M000007_source" class="dyn-source">
|
299
|
-
<pre>
|
300
|
-
<span class="ruby-comment cmt"># File lib/facets/core/float/round_to.rb, line 30</span>
|
301
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">round_to</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
302
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">to_f</span>.<span class="ruby-identifier">round_to</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
303
|
-
<span class="ruby-keyword kw">end</span>
|
304
|
-
</pre>
|
305
|
-
</div>
|
306
|
-
</div>
|
307
|
-
</div>
|
308
|
-
<div class="method">
|
309
|
-
<div class="title">
|
310
|
-
<a name="M000011"></a><b>times_collect</b>(&yld)
|
311
|
-
</div>
|
312
|
-
<div class="description">
|
313
|
-
<p>
|
314
|
-
Like times but returns a collection of the yield results.
|
315
|
-
</p>
|
316
|
-
<pre>
|
317
|
-
a = 3.times_collect { |i| "#{i+1}" }
|
318
|
-
a => [ "1", "2", "3" ]
|
319
|
-
</pre>
|
320
|
-
</div>
|
321
|
-
<div class="aka">
|
322
|
-
This method is also aliased as
|
323
|
-
<a href="Integer.html#M000012">times_map</a>
|
324
|
-
</div>
|
325
|
-
<div class="sourcecode">
|
326
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000011_source')" id="l_M000011_source">show source</a> ]</p>
|
327
|
-
<div id="M000011_source" class="dyn-source">
|
328
|
-
<pre>
|
329
|
-
<span class="ruby-comment cmt"># File lib/facets/core/integer/times_collect.rb, line 9</span>
|
330
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">times_collect</span>(<span class="ruby-operator">&</span><span class="ruby-identifier">yld</span>)
|
331
|
-
<span class="ruby-identifier">a</span> = []; <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">times</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-identifier">a</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">yld</span>.<span class="ruby-identifier">call</span>(<span class="ruby-identifier">i</span>) }
|
332
|
-
<span class="ruby-identifier">a</span>
|
333
|
-
<span class="ruby-keyword kw">end</span>
|
334
|
-
</pre>
|
335
|
-
</div>
|
336
|
-
</div>
|
337
|
-
</div>
|
338
|
-
<div class="method">
|
339
|
-
<div class="title">
|
340
|
-
<a name="M000012"></a><b>times_map</b>(&yld)
|
341
|
-
</div>
|
342
|
-
<div class="description">
|
343
|
-
<p>
|
344
|
-
Alias for <a href="Integer.html#M000011">times_collect</a>
|
345
|
-
</p>
|
346
|
-
</div>
|
347
|
-
</div>
|
348
|
-
</div>
|
349
|
-
|
350
|
-
</div>
|
351
|
-
|
352
|
-
</body>
|
353
|
-
</html>
|
@@ -1,86 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
-
<!DOCTYPE html
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
-
<html>
|
6
|
-
<head>
|
7
|
-
<title>Module: Kernal</title>
|
8
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
9
|
-
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
10
|
-
|
11
|
-
<script language="JavaScript" type="text/javascript">
|
12
|
-
// <![CDATA[
|
13
|
-
|
14
|
-
function toggleSource( id )
|
15
|
-
{
|
16
|
-
var elem
|
17
|
-
var link
|
18
|
-
|
19
|
-
if( document.getElementById )
|
20
|
-
{
|
21
|
-
elem = document.getElementById( id )
|
22
|
-
link = document.getElementById( "l_" + id )
|
23
|
-
}
|
24
|
-
else if ( document.all )
|
25
|
-
{
|
26
|
-
elem = eval( "document.all." + id )
|
27
|
-
link = eval( "document.all.l_" + id )
|
28
|
-
}
|
29
|
-
else
|
30
|
-
return false;
|
31
|
-
|
32
|
-
if( elem.style.display == "block" )
|
33
|
-
{
|
34
|
-
elem.style.display = "none"
|
35
|
-
link.innerHTML = "show source"
|
36
|
-
}
|
37
|
-
else
|
38
|
-
{
|
39
|
-
elem.style.display = "block"
|
40
|
-
link.innerHTML = "hide source"
|
41
|
-
}
|
42
|
-
}
|
43
|
-
|
44
|
-
function openCode( url )
|
45
|
-
{
|
46
|
-
window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
|
47
|
-
}
|
48
|
-
// ]]>
|
49
|
-
</script>
|
50
|
-
</head>
|
51
|
-
|
52
|
-
<body>
|
53
|
-
<table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
|
54
|
-
<td class="file-title"><span class="file-title-prefix">Module</span><br />Kernal</td>
|
55
|
-
<td align="right">
|
56
|
-
<table cellspacing=0 cellpadding=2>
|
57
|
-
<tr valign="top">
|
58
|
-
<td>In:</td>
|
59
|
-
<td>
|
60
|
-
<a href="../files/lib/facets/core/kernel/__get___rb.html">lib/facets/core/kernel/__get__.rb</a>
|
61
|
-
</td>
|
62
|
-
</tr>
|
63
|
-
</table>
|
64
|
-
</td>
|
65
|
-
</tr>
|
66
|
-
</table>
|
67
|
-
<!-- banner header -->
|
68
|
-
|
69
|
-
<div id="bodyContent">
|
70
|
-
<div id="content">
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
</div>
|
82
|
-
|
83
|
-
</div>
|
84
|
-
|
85
|
-
</body>
|
86
|
-
</html>
|
@@ -1,2010 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
-
<!DOCTYPE html
|
3
|
-
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
-
<html>
|
6
|
-
<head>
|
7
|
-
<title>Module: Kernel</title>
|
8
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
9
|
-
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
10
|
-
|
11
|
-
<script language="JavaScript" type="text/javascript">
|
12
|
-
// <![CDATA[
|
13
|
-
|
14
|
-
function toggleSource( id )
|
15
|
-
{
|
16
|
-
var elem
|
17
|
-
var link
|
18
|
-
|
19
|
-
if( document.getElementById )
|
20
|
-
{
|
21
|
-
elem = document.getElementById( id )
|
22
|
-
link = document.getElementById( "l_" + id )
|
23
|
-
}
|
24
|
-
else if ( document.all )
|
25
|
-
{
|
26
|
-
elem = eval( "document.all." + id )
|
27
|
-
link = eval( "document.all.l_" + id )
|
28
|
-
}
|
29
|
-
else
|
30
|
-
return false;
|
31
|
-
|
32
|
-
if( elem.style.display == "block" )
|
33
|
-
{
|
34
|
-
elem.style.display = "none"
|
35
|
-
link.innerHTML = "show source"
|
36
|
-
}
|
37
|
-
else
|
38
|
-
{
|
39
|
-
elem.style.display = "block"
|
40
|
-
link.innerHTML = "hide source"
|
41
|
-
}
|
42
|
-
}
|
43
|
-
|
44
|
-
function openCode( url )
|
45
|
-
{
|
46
|
-
window.open( url, "SOURCE_CODE", "width=400,height=400,scrollbars=yes" )
|
47
|
-
}
|
48
|
-
// ]]>
|
49
|
-
</script>
|
50
|
-
</head>
|
51
|
-
|
52
|
-
<body>
|
53
|
-
<table width="100%" border='0' cellpadding='0' cellspacing='0' class='banner'><tr>
|
54
|
-
<td class="file-title"><span class="file-title-prefix">Module</span><br />Kernel</td>
|
55
|
-
<td align="right">
|
56
|
-
<table cellspacing=0 cellpadding=2>
|
57
|
-
<tr valign="top">
|
58
|
-
<td>In:</td>
|
59
|
-
<td>
|
60
|
-
<a href="../files/lib/facets/core/kernel/call_stack_rb.html">lib/facets/core/kernel/call_stack.rb</a>
|
61
|
-
<a href="../files/lib/facets/core/kernel/p_rb.html">lib/facets/core/kernel/p.rb</a>
|
62
|
-
<a href="../files/lib/facets/core/kernel/get_by_id_rb.html">lib/facets/core/kernel/get_by_id.rb</a>
|
63
|
-
<a href="../files/lib/facets/core/kernel/constant_rb.html">lib/facets/core/kernel/constant.rb</a>
|
64
|
-
<a href="../files/lib/facets/core/kernel/copy_rb.html">lib/facets/core/kernel/copy.rb</a>
|
65
|
-
<a href="../files/lib/facets/core/kernel/demo_rb.html">lib/facets/core/kernel/demo.rb</a>
|
66
|
-
<a href="../files/lib/facets/core/kernel/resc_rb.html">lib/facets/core/kernel/resc.rb</a>
|
67
|
-
<a href="../files/lib/facets/core/kernel/__self___rb.html">lib/facets/core/kernel/__self__.rb</a>
|
68
|
-
<a href="../files/lib/facets/core/kernel/set_with_rb.html">lib/facets/core/kernel/set_with.rb</a>
|
69
|
-
<a href="../files/lib/facets/core/kernel/require_all_rb.html">lib/facets/core/kernel/require_all.rb</a>
|
70
|
-
<a href="../files/lib/facets/core/kernel/as_rb.html">lib/facets/core/kernel/as.rb</a>
|
71
|
-
<a href="../files/lib/facets/core/kernel/fn_rb.html">lib/facets/core/kernel/fn.rb</a>
|
72
|
-
<a href="../files/lib/facets/core/kernel/in_rb.html">lib/facets/core/kernel/in.rb</a>
|
73
|
-
<a href="../files/lib/facets/core/kernel/is_rb.html">lib/facets/core/kernel/is.rb</a>
|
74
|
-
<a href="../files/lib/facets/core/kernel/require_esc_rb.html">lib/facets/core/kernel/require_esc.rb</a>
|
75
|
-
<a href="../files/lib/facets/core/kernel/singleton_rb.html">lib/facets/core/kernel/singleton.rb</a>
|
76
|
-
<a href="../files/lib/facets/core/kernel/instance_assign_rb.html">lib/facets/core/kernel/instance_assign.rb</a>
|
77
|
-
<a href="../files/lib/facets/core/kernel/autoreload_rb.html">lib/facets/core/kernel/autoreload.rb</a>
|
78
|
-
<a href="../files/lib/facets/core/kernel/methods_rb.html">lib/facets/core/kernel/methods.rb</a>
|
79
|
-
<a href="../files/lib/facets/core/kernel/assign_from_rb.html">lib/facets/core/kernel/assign_from.rb</a>
|
80
|
-
<a href="../files/lib/facets/core/kernel/__DIR___rb.html">lib/facets/core/kernel/__DIR__.rb</a>
|
81
|
-
<a href="../files/lib/facets/core/kernel/__class___rb.html">lib/facets/core/kernel/__class__.rb</a>
|
82
|
-
<a href="../files/lib/facets/core/kernel/cache_rb.html">lib/facets/core/kernel/cache.rb</a>
|
83
|
-
<a href="../files/lib/facets/core/kernel/send_as_rb.html">lib/facets/core/kernel/send_as.rb</a>
|
84
|
-
<a href="../files/lib/facets/core/kernel/this_rb.html">lib/facets/core/kernel/this.rb</a>
|
85
|
-
<a href="../files/lib/facets/core/kernel/nack_rb.html">lib/facets/core/kernel/nack.rb</a>
|
86
|
-
<a href="../files/lib/facets/core/kernel/bug_rb.html">lib/facets/core/kernel/bug.rb</a>
|
87
|
-
<a href="../files/lib/facets/core/kernel/generate_method_name_rb.html">lib/facets/core/kernel/generate_method_name.rb</a>
|
88
|
-
<a href="../files/lib/facets/core/kernel/supermethod_rb.html">lib/facets/core/kernel/supermethod.rb</a>
|
89
|
-
<a href="../files/lib/facets/core/kernel/op_esc_rb.html">lib/facets/core/kernel/op_esc.rb</a>
|
90
|
-
<a href="../files/lib/facets/core/kernel/maybe_rb.html">lib/facets/core/kernel/maybe.rb</a>
|
91
|
-
<a href="../files/lib/facets/core/kernel/require_local_rb.html">lib/facets/core/kernel/require_local.rb</a>
|
92
|
-
<a href="../files/lib/facets/core/kernel/complete_rb.html">lib/facets/core/kernel/complete.rb</a>
|
93
|
-
<a href="../files/lib/facets/core/kernel/object_class_rb.html">lib/facets/core/kernel/object_class.rb</a>
|
94
|
-
<a href="../files/lib/facets/core/kernel/new_rb.html">lib/facets/core/kernel/new.rb</a>
|
95
|
-
<a href="../files/lib/facets/core/kernel/returning_rb.html">lib/facets/core/kernel/returning.rb</a>
|
96
|
-
<a href="../files/lib/facets/core/kernel/own_rb.html">lib/facets/core/kernel/own.rb</a>
|
97
|
-
<a href="../files/lib/facets/core/kernel/instvar_rb.html">lib/facets/core/kernel/instvar.rb</a>
|
98
|
-
<a href="../files/lib/facets/core/kernel/here_rb.html">lib/facets/core/kernel/here.rb</a>
|
99
|
-
<a href="../files/lib/facets/core/kernel/called_rb.html">lib/facets/core/kernel/called.rb</a>
|
100
|
-
<a href="../files/lib/facets/core/kernel/assign_with_rb.html">lib/facets/core/kernel/assign_with.rb</a>
|
101
|
-
<a href="../files/lib/facets/core/kernel/uri_rb.html">lib/facets/core/kernel/uri.rb</a>
|
102
|
-
<a href="../files/lib/facets/core/kernel/set_from_rb.html">lib/facets/core/kernel/set_from.rb</a>
|
103
|
-
<a href="../files/lib/facets/core/kernel/eigenclass_rb.html">lib/facets/core/kernel/eigenclass.rb</a>
|
104
|
-
<a href="../files/lib/facets/core/kernel/warn_with_line_rb.html">lib/facets/core/kernel/warn_with_line.rb</a>
|
105
|
-
<a href="../files/lib/facets/core/kernel/object_hexid_rb.html">lib/facets/core/kernel/object_hexid.rb</a>
|
106
|
-
<a href="../files/lib/facets/core/kernel/method_rb.html">lib/facets/core/kernel/method.rb</a>
|
107
|
-
<a href="../files/lib/facets/core/kernel/deep_copy_rb.html">lib/facets/core/kernel/deep_copy.rb</a>
|
108
|
-
<a href="../files/lib/facets/core/kernel/bool_rb.html">lib/facets/core/kernel/bool.rb</a>
|
109
|
-
<a href="../files/lib/facets/core/kernel/require_facet_rb.html">lib/facets/core/kernel/require_facet.rb</a>
|
110
|
-
<a href="../files/lib/facets/core/kernel/silently_rb.html">lib/facets/core/kernel/silently.rb</a>
|
111
|
-
<a href="../files/lib/facets/core/kernel/pp_exception_rb.html">lib/facets/core/kernel/pp_exception.rb</a>
|
112
|
-
<a href="../files/lib/facets/core/kernel/quaclass_rb.html">lib/facets/core/kernel/quaclass.rb</a>
|
113
|
-
<a href="../files/lib/facets/core/kernel/__method___rb.html">lib/facets/core/kernel/__method__.rb</a>
|
114
|
-
<a href="../files/lib/facets/core/kernel/respond_rb.html">lib/facets/core/kernel/respond.rb</a>
|
115
|
-
<a href="../files/lib/facets/core/kernel/singleton_class_rb.html">lib/facets/core/kernel/singleton_class.rb</a>
|
116
|
-
</td>
|
117
|
-
</tr>
|
118
|
-
</table>
|
119
|
-
</td>
|
120
|
-
</tr>
|
121
|
-
</table>
|
122
|
-
<!-- banner header -->
|
123
|
-
|
124
|
-
<div id="bodyContent">
|
125
|
-
<div id="content">
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
<div class="sectiontitle">Methods</div>
|
131
|
-
<ul>
|
132
|
-
<li><a href="#M000424">__DIR__</a></li>
|
133
|
-
<li><a href="#M000412">__as__</a></li>
|
134
|
-
<li><a href="#M000462">__callee__</a></li>
|
135
|
-
<li><a href="#M000461">__method__</a></li>
|
136
|
-
<li><a href="#M000460">__quaclass__</a></li>
|
137
|
-
<li><a href="#M000409">__self__</a></li>
|
138
|
-
<li><a href="#M000417">__singleton__</a></li>
|
139
|
-
<li><a href="#M000465">__singleton_class__</a></li>
|
140
|
-
<li><a href="#M000413">as</a></li>
|
141
|
-
<li><a href="#M000423">assign_from</a></li>
|
142
|
-
<li><a href="#M000443">assign_with</a></li>
|
143
|
-
<li><a href="#M000419">autoreload</a></li>
|
144
|
-
<li><a href="#M000420">autoreload_files</a></li>
|
145
|
-
<li><a href="#M000421">autoreload_glob</a></li>
|
146
|
-
<li><a href="#M000454">bool?</a></li>
|
147
|
-
<li><a href="#M000429">bug!</a></li>
|
148
|
-
<li><a href="#M000425">cache</a></li>
|
149
|
-
<li><a href="#M000402">call_stack</a></li>
|
150
|
-
<li><a href="#M000442">called</a></li>
|
151
|
-
<li><a href="#M000436">complete</a></li>
|
152
|
-
<li><a href="#M000405">constant</a></li>
|
153
|
-
<li><a href="#M000406">copy</a></li>
|
154
|
-
<li><a href="#M000451">deep_copy</a></li>
|
155
|
-
<li><a href="#M000407">demo</a></li>
|
156
|
-
<li><a href="#M000447">eigenclass</a></li>
|
157
|
-
<li><a href="#M000453">false?</a></li>
|
158
|
-
<li><a href="#M000430">generate_method_name</a></li>
|
159
|
-
<li><a href="#M000404">get_by_id</a></li>
|
160
|
-
<li><a href="#M000414">in?</a></li>
|
161
|
-
<li><a href="#M000418">instance_assign</a></li>
|
162
|
-
<li><a href="#M000440">instvar</a></li>
|
163
|
-
<li><a href="#M000441">instvar!</a></li>
|
164
|
-
<li><a href="#M000434">maybe</a></li>
|
165
|
-
<li><a href="#M000450">method!</a></li>
|
166
|
-
<li><a href="#M000422">methods</a></li>
|
167
|
-
<li><a href="#M000428">nack</a></li>
|
168
|
-
<li><a href="#M000437">new</a></li>
|
169
|
-
<li><a href="#M000449">object_hexid</a></li>
|
170
|
-
<li><a href="#M000433">op_esc</a></li>
|
171
|
-
<li><a href="#M000439">own</a></li>
|
172
|
-
<li><a href="#M000403">p</a></li>
|
173
|
-
<li><a href="#M000458">pp_exception</a></li>
|
174
|
-
<li><a href="#M000459">quaclass</a></li>
|
175
|
-
<li><a href="#M000411">require_all</a></li>
|
176
|
-
<li><a href="#M000415">require_esc</a></li>
|
177
|
-
<li><a href="#M000455">require_facet</a></li>
|
178
|
-
<li><a href="#M000435">require_local</a></li>
|
179
|
-
<li><a href="#M000408">resc</a></li>
|
180
|
-
<li><a href="#M000463">respond</a></li>
|
181
|
-
<li><a href="#M000438">returning</a></li>
|
182
|
-
<li><a href="#M000426">send_as</a></li>
|
183
|
-
<li><a href="#M000446">set_from</a></li>
|
184
|
-
<li><a href="#M000410">set_with</a></li>
|
185
|
-
<li><a href="#M000457">silence_warnings</a></li>
|
186
|
-
<li><a href="#M000456">silently</a></li>
|
187
|
-
<li><a href="#M000416">singleton</a></li>
|
188
|
-
<li><a href="#M000464">singleton_class</a></li>
|
189
|
-
<li><a href="#M000432">super_method</a></li>
|
190
|
-
<li><a href="#M000431">supermethod</a></li>
|
191
|
-
<li><a href="#M000427">this</a></li>
|
192
|
-
<li><a href="#M000452">true?</a></li>
|
193
|
-
<li><a href="#M000445">unuri</a></li>
|
194
|
-
<li><a href="#M000444">uri</a></li>
|
195
|
-
<li><a href="#M000448">warn_with_line</a></li>
|
196
|
-
</ul>
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
<div class="sectiontitle">Constants</div>
|
202
|
-
<table border='0' cellpadding='5'>
|
203
|
-
<tr valign='top'>
|
204
|
-
<td class="attr-name">OPERATORS</td>
|
205
|
-
<td>=</td>
|
206
|
-
<td class="attr-value">%w{ +@ -@ + - ** * / % ~ <=> << >> < > === == =~ <= >= | & ^ []= [] }</td>
|
207
|
-
</tr>
|
208
|
-
<tr valign='top'>
|
209
|
-
<td class="attr-name">OPERATORS_REGEXP</td>
|
210
|
-
<td>=</td>
|
211
|
-
<td class="attr-value">Regexp.new( '(' << OPERATORS.collect{ |k| Regexp.escape(k) }.join('|') << ')' )</td>
|
212
|
-
</tr>
|
213
|
-
<tr valign='top'>
|
214
|
-
<td class="attr-name">OPERATORS_ESC_TABLE</td>
|
215
|
-
<td>=</td>
|
216
|
-
<td class="attr-value">{ "+@" => "op_plus_self", "-@" => "op_minus_self", "+" => "op_plus", "-" => "op_minus", "**" => "op_pow", "*" => "op_mul", "/" => "op_div", "%" => "op_mod", "~" => "op_tilde", "<=>" => "op_cmp", "<<" => "op_lshift", ">>" => "op_rshift", "<" => "op_lt", ">" => "op_gt", "===" => "op_case_eq", "==" => "op_equal", "=~" => "op_apply", "<=" => "op_lt_eq", ">=" => "op_gt_eq", "|" => "op_or", "&" => "op_and", "^" => "op_xor", "[]=" => "op_store", "[]" => "op_fetch"</td>
|
217
|
-
</tr>
|
218
|
-
</table>
|
219
|
-
|
220
|
-
|
221
|
-
<div class="sectiontitle">Public Instance methods</div>
|
222
|
-
<div class="method">
|
223
|
-
<div class="title">
|
224
|
-
<a name="M000424"></a><b>__DIR__</b>()
|
225
|
-
</div>
|
226
|
-
<div class="description">
|
227
|
-
<p>
|
228
|
-
Similar to <em>FILE</em> and <em>LINE</em>, <em>DIR</em> provides the
|
229
|
-
directory path to the current executing script.
|
230
|
-
</p>
|
231
|
-
</div>
|
232
|
-
<div class="sourcecode">
|
233
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000424_source')" id="l_M000424_source">show source</a> ]</p>
|
234
|
-
<div id="M000424_source" class="dyn-source">
|
235
|
-
<pre>
|
236
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/__DIR__.rb, line 7</span>
|
237
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">__DIR__</span>
|
238
|
-
(<span class="ruby-regexp re">/^(.+)?:\d+/</span> <span class="ruby-operator">=~</span> <span class="ruby-identifier">caller</span>[<span class="ruby-value">0</span>]) <span class="ruby-operator">?</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dirname</span>(<span class="ruby-identifier">$1</span>) <span class="ruby-operator">:</span> <span class="ruby-keyword kw">nil</span>
|
239
|
-
<span class="ruby-keyword kw">end</span>
|
240
|
-
</pre>
|
241
|
-
</div>
|
242
|
-
</div>
|
243
|
-
</div>
|
244
|
-
<div class="method">
|
245
|
-
<div class="title">
|
246
|
-
<a name="M000412"></a><b>__as__</b>( klass=nil, &blk )
|
247
|
-
</div>
|
248
|
-
<div class="description">
|
249
|
-
<p>
|
250
|
-
Returns a Functor that allows one to call any parent method directly.
|
251
|
-
</p>
|
252
|
-
<pre>
|
253
|
-
class A
|
254
|
-
def x ; 1 ; end
|
255
|
-
end
|
256
|
-
|
257
|
-
class B < A
|
258
|
-
def x ; 2 ; end
|
259
|
-
end
|
260
|
-
|
261
|
-
class C < B
|
262
|
-
def x ; as(A).x ; end
|
263
|
-
end
|
264
|
-
|
265
|
-
C.new.x #=> 1
|
266
|
-
</pre>
|
267
|
-
</div>
|
268
|
-
<div class="aka">
|
269
|
-
This method is also aliased as
|
270
|
-
<a href="Kernel.html#M000413">as</a>
|
271
|
-
</div>
|
272
|
-
<div class="sourcecode">
|
273
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000412_source')" id="l_M000412_source">show source</a> ]</p>
|
274
|
-
<div id="M000412_source" class="dyn-source">
|
275
|
-
<pre>
|
276
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/as.rb, line 22</span>
|
277
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">__as__</span>( <span class="ruby-identifier">klass</span>=<span class="ruby-keyword kw">nil</span>, <span class="ruby-operator">&</span><span class="ruby-identifier">blk</span> )
|
278
|
-
<span class="ruby-identifier">selfclass</span> = <span class="ruby-constant">Kernel</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">:class</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>).<span class="ruby-identifier">call</span>
|
279
|
-
<span class="ruby-identifier">klass</span> <span class="ruby-operator">||=</span> <span class="ruby-identifier">selfclass</span>.<span class="ruby-identifier">superclass</span>
|
280
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">selfclass</span>.<span class="ruby-identifier">ancestors</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">klass</span>)
|
281
|
-
<span class="ruby-constant">Functor</span>.<span class="ruby-identifier">new</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">meth</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span><span class="ruby-operator">|</span> <span class="ruby-comment cmt"># &blk|</span>
|
282
|
-
<span class="ruby-identifier">klass</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">meth</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>).<span class="ruby-identifier">call</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>) <span class="ruby-comment cmt"># ,&blk)</span>
|
283
|
-
<span class="ruby-keyword kw">end</span>
|
284
|
-
<span class="ruby-keyword kw">else</span>
|
285
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-node">"#{klass} is not an ancestor"</span>
|
286
|
-
<span class="ruby-keyword kw">end</span>
|
287
|
-
<span class="ruby-keyword kw">end</span>
|
288
|
-
</pre>
|
289
|
-
</div>
|
290
|
-
</div>
|
291
|
-
</div>
|
292
|
-
<div class="method">
|
293
|
-
<div class="title">
|
294
|
-
<a name="M000460"></a><b>__quaclass__</b>( &block )
|
295
|
-
</div>
|
296
|
-
<div class="description">
|
297
|
-
<p>
|
298
|
-
Alias for <a href="Kernel.html#M000459">quaclass</a>
|
299
|
-
</p>
|
300
|
-
</div>
|
301
|
-
</div>
|
302
|
-
<div class="method">
|
303
|
-
<div class="title">
|
304
|
-
<a name="M000409"></a><b>__self__</b>()
|
305
|
-
</div>
|
306
|
-
<div class="description">
|
307
|
-
<p>
|
308
|
-
Returns a Functor that allows one to call any <a
|
309
|
-
href="Kernel.html">Kernel</a> or <a href="Object.html">Object</a> method
|
310
|
-
bound to self, making it possible to bypass overrides of <a
|
311
|
-
href="Kernel.html">Kernel</a> and <a href="Object.html">Object</a> methods.
|
312
|
-
</p>
|
313
|
-
<pre>
|
314
|
-
class A
|
315
|
-
def object_id ; "OBTUSE" ; end
|
316
|
-
end
|
317
|
-
|
318
|
-
c = C.new
|
319
|
-
c.object_id #=> "OBTUSE"
|
320
|
-
c.__self__.object_id #=> 6664875832
|
321
|
-
</pre>
|
322
|
-
</div>
|
323
|
-
<div class="sourcecode">
|
324
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000409_source')" id="l_M000409_source">show source</a> ]</p>
|
325
|
-
<div id="M000409_source" class="dyn-source">
|
326
|
-
<pre>
|
327
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/__self__.rb, line 24</span>
|
328
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">__self__</span>
|
329
|
-
<span class="ruby-ivar">@__self__</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">Functor</span>.<span class="ruby-identifier">new</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">meth</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span><span class="ruby-operator">|</span> <span class="ruby-comment cmt"># &blk|</span>
|
330
|
-
<span class="ruby-constant">Object</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">meth</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>).<span class="ruby-identifier">call</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>) <span class="ruby-comment cmt"># ,&blk)</span>
|
331
|
-
<span class="ruby-keyword kw">end</span>
|
332
|
-
<span class="ruby-keyword kw">end</span>
|
333
|
-
</pre>
|
334
|
-
</div>
|
335
|
-
</div>
|
336
|
-
</div>
|
337
|
-
<div class="method">
|
338
|
-
<div class="title">
|
339
|
-
<a name="M000417"></a><b>__singleton__</b>()
|
340
|
-
</div>
|
341
|
-
<div class="description">
|
342
|
-
<p>
|
343
|
-
Alias for <a href="Kernel.html#M000416">singleton</a>
|
344
|
-
</p>
|
345
|
-
</div>
|
346
|
-
</div>
|
347
|
-
<div class="method">
|
348
|
-
<div class="title">
|
349
|
-
<a name="M000465"></a><b>__singleton_class__</b>()
|
350
|
-
</div>
|
351
|
-
<div class="description">
|
352
|
-
<p>
|
353
|
-
Alias for <a href="Kernel.html#M000464">singleton_class</a>
|
354
|
-
</p>
|
355
|
-
</div>
|
356
|
-
</div>
|
357
|
-
<div class="method">
|
358
|
-
<div class="title">
|
359
|
-
<a name="M000413"></a><b>as</b>( klass=nil, &blk )
|
360
|
-
</div>
|
361
|
-
<div class="description">
|
362
|
-
<p>
|
363
|
-
Alias for #<em>as</em>
|
364
|
-
</p>
|
365
|
-
</div>
|
366
|
-
</div>
|
367
|
-
<div class="method">
|
368
|
-
<div class="title">
|
369
|
-
<a name="M000423"></a><b>assign_from</b>(obj, *fields)
|
370
|
-
</div>
|
371
|
-
<div class="description">
|
372
|
-
<p>
|
373
|
-
Set instance vars using another object.
|
374
|
-
</p>
|
375
|
-
<pre>
|
376
|
-
class O
|
377
|
-
attr_accessor :d
|
378
|
-
def initialize( a, b, c, d)
|
379
|
-
@a = a
|
380
|
-
@b = b
|
381
|
-
@c = c
|
382
|
-
@d = d
|
383
|
-
end
|
384
|
-
end
|
385
|
-
o1 = O.new(1,2,3,4)
|
386
|
-
o2 = O.new(0,0,0,0)
|
387
|
-
|
388
|
-
o2.assign_from( o1, '@a', '@b', '@c', '@d' )
|
389
|
-
o2.instance_eval{ @a } #=> 1
|
390
|
-
o2.instance_eval{ @b } #=> 2
|
391
|
-
o2.instance_eval{ @c } #=> 3
|
392
|
-
o2.instance_eval{ @d } #=> 4
|
393
|
-
</pre>
|
394
|
-
<p>
|
395
|
-
See also <a href="Kernel.html#M000443">assign_with</a>.
|
396
|
-
</p>
|
397
|
-
</div>
|
398
|
-
<div class="sourcecode">
|
399
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000423_source')" id="l_M000423_source">show source</a> ]</p>
|
400
|
-
<div id="M000423_source" class="dyn-source">
|
401
|
-
<pre>
|
402
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/assign_from.rb, line 27</span>
|
403
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">assign_from</span>(<span class="ruby-identifier">obj</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">fields</span>)
|
404
|
-
<span class="ruby-identifier">force</span> = <span class="ruby-keyword kw">false</span>
|
405
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">fields</span>.<span class="ruby-identifier">last</span> <span class="ruby-keyword kw">when</span> <span class="ruby-keyword kw">true</span>, <span class="ruby-keyword kw">false</span>, <span class="ruby-keyword kw">nil</span>
|
406
|
-
<span class="ruby-identifier">force</span> = <span class="ruby-identifier">fields</span>.<span class="ruby-identifier">pop</span>
|
407
|
-
<span class="ruby-keyword kw">end</span>
|
408
|
-
|
409
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">fields</span>.<span class="ruby-identifier">empty?</span>
|
410
|
-
<span class="ruby-identifier">fields</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span><span class="ruby-operator">|</span>
|
411
|
-
<span class="ruby-identifier">var</span> = <span class="ruby-identifier">k</span>.<span class="ruby-identifier">to_s</span>
|
412
|
-
<span class="ruby-identifier">var</span> = <span class="ruby-identifier">var</span>.<span class="ruby-identifier">slice</span>(<span class="ruby-value">0</span>,<span class="ruby-value">1</span>) <span class="ruby-operator">==</span> <span class="ruby-value str">'@'</span> <span class="ruby-operator">?</span> <span class="ruby-identifier">var</span> <span class="ruby-operator">:</span> <span class="ruby-node">"@#{var}"</span>
|
413
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">instance_variables</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">var</span>)
|
414
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-identifier">var</span>, <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">var</span>) )
|
415
|
-
<span class="ruby-keyword kw">end</span>
|
416
|
-
<span class="ruby-keyword kw">end</span>
|
417
|
-
<span class="ruby-keyword kw">else</span>
|
418
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">force</span>
|
419
|
-
<span class="ruby-identifier">fields</span> = <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">instance_variables</span>
|
420
|
-
<span class="ruby-keyword kw">else</span>
|
421
|
-
<span class="ruby-identifier">fields</span> = <span class="ruby-identifier">instance_variables</span> <span class="ruby-operator">|</span> <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">instance_variables</span>
|
422
|
-
<span class="ruby-keyword kw">end</span>
|
423
|
-
<span class="ruby-identifier">fields</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">var</span><span class="ruby-operator">|</span>
|
424
|
-
<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-identifier">var</span>, <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">var</span>) )
|
425
|
-
<span class="ruby-keyword kw">end</span>
|
426
|
-
<span class="ruby-keyword kw">end</span>
|
427
|
-
|
428
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">self</span>
|
429
|
-
<span class="ruby-keyword kw">end</span>
|
430
|
-
</pre>
|
431
|
-
</div>
|
432
|
-
</div>
|
433
|
-
</div>
|
434
|
-
<div class="method">
|
435
|
-
<div class="title">
|
436
|
-
<a name="M000443"></a><b>assign_with</b>(*args)
|
437
|
-
</div>
|
438
|
-
<div class="description">
|
439
|
-
<p>
|
440
|
-
Set setter methods and/or vars using a hash (or assoc array). <a
|
441
|
-
href="Kernel.html#M000443">assign_with</a> is a meta-programming method,
|
442
|
-
which allows you to use a hash to do any kind of variable assignment and/or
|
443
|
-
setting:
|
444
|
-
</p>
|
445
|
-
<p>
|
446
|
-
For example, assuming that there is an accessor defined as <tt>d</tt>:
|
447
|
-
</p>
|
448
|
-
<pre>
|
449
|
-
assign_with( '@a'=>1, '@@b'=>2, '$c'=>3, 'd'=>4 )
|
450
|
-
@a #=> 1
|
451
|
-
@@b #=> 2
|
452
|
-
$c #=> 3
|
453
|
-
d #=> 4
|
454
|
-
</pre>
|
455
|
-
<p>
|
456
|
-
Note that while the global variable is strictly unnecessary, it works for
|
457
|
-
completeness sake.
|
458
|
-
</p>
|
459
|
-
</div>
|
460
|
-
<div class="sourcecode">
|
461
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000443_source')" id="l_M000443_source">show source</a> ]</p>
|
462
|
-
<div id="M000443_source" class="dyn-source">
|
463
|
-
<pre>
|
464
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/assign_with.rb, line 32</span>
|
465
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">assign_with</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
466
|
-
<span class="ruby-identifier">harg</span> = <span class="ruby-identifier">args</span>.<span class="ruby-identifier">last</span>.<span class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Hash</span>) <span class="ruby-operator">?</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">pop</span> <span class="ruby-operator">:</span> {}
|
467
|
-
|
468
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">empty?</span>
|
469
|
-
<span class="ruby-comment cmt"># if not assoc array, eg. [ [], [], ... ]</span>
|
470
|
-
<span class="ruby-comment cmt"># preserves order of opertation</span>
|
471
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">args</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Array</span>)
|
472
|
-
<span class="ruby-identifier">i</span> = <span class="ruby-value">0</span>; <span class="ruby-identifier">a</span> = []
|
473
|
-
<span class="ruby-keyword kw">while</span> <span class="ruby-identifier">i</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">size</span>
|
474
|
-
<span class="ruby-identifier">a</span> <span class="ruby-operator"><<</span> [ <span class="ruby-identifier">args</span>[<span class="ruby-identifier">i</span>], <span class="ruby-identifier">args</span>[<span class="ruby-identifier">i</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>] ]
|
475
|
-
<span class="ruby-identifier">i</span> <span class="ruby-operator">+=</span> <span class="ruby-value">2</span>
|
476
|
-
<span class="ruby-keyword kw">end</span>
|
477
|
-
<span class="ruby-identifier">args</span> = <span class="ruby-identifier">a</span>
|
478
|
-
<span class="ruby-keyword kw">end</span>
|
479
|
-
<span class="ruby-keyword kw">end</span>
|
480
|
-
|
481
|
-
<span class="ruby-identifier">args</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>,<span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
482
|
-
<span class="ruby-identifier">instance_assign</span>( <span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span> )
|
483
|
-
<span class="ruby-keyword kw">end</span>
|
484
|
-
|
485
|
-
<span class="ruby-identifier">harg</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>,<span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
486
|
-
<span class="ruby-identifier">instance_assign</span>( <span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span> )
|
487
|
-
<span class="ruby-keyword kw">end</span>
|
488
|
-
|
489
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">self</span>
|
490
|
-
<span class="ruby-keyword kw">end</span>
|
491
|
-
</pre>
|
492
|
-
</div>
|
493
|
-
</div>
|
494
|
-
</div>
|
495
|
-
<div class="method">
|
496
|
-
<div class="title">
|
497
|
-
<a name="M000419"></a><b>autoreload</b>( *args )
|
498
|
-
</div>
|
499
|
-
<div class="description">
|
500
|
-
<p>
|
501
|
-
Autoreload feature files.
|
502
|
-
</p>
|
503
|
-
<p>
|
504
|
-
Automatically reload, at regular intervals, any previously loaded features,
|
505
|
-
and/or other files not already loaded, if they have been modified since the
|
506
|
-
last interval check. A numeric parameter sets the reload interval in
|
507
|
-
seconds and the file parameter can either be a glob string or an array of
|
508
|
-
file paths. If a glob string, it is expanded only once on the initial
|
509
|
-
method call. Supplying a boolean parameter of ‘false’ will
|
510
|
-
force autreload to skip previously loaded features and only reload the
|
511
|
-
specified files. Also keeps a "dirty" flag.
|
512
|
-
</p>
|
513
|
-
</div>
|
514
|
-
<div class="sourcecode">
|
515
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000419_source')" id="l_M000419_source">show source</a> ]</p>
|
516
|
-
<div id="M000419_source" class="dyn-source">
|
517
|
-
<pre>
|
518
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/autoreload.rb, line 19</span>
|
519
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">autoreload</span>( <span class="ruby-operator">*</span><span class="ruby-identifier">args</span> )
|
520
|
-
|
521
|
-
<span class="ruby-identifier">check_interval</span>=<span class="ruby-value">10</span>
|
522
|
-
<span class="ruby-identifier">include_features</span> = <span class="ruby-keyword kw">true</span>
|
523
|
-
<span class="ruby-identifier">files</span> = <span class="ruby-keyword kw">nil</span>
|
524
|
-
|
525
|
-
<span class="ruby-identifier">args</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">arg</span><span class="ruby-operator">|</span>
|
526
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">arg</span>
|
527
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">Numeric</span>
|
528
|
-
<span class="ruby-identifier">check_interval</span> = <span class="ruby-identifier">arg</span>
|
529
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">String</span>
|
530
|
-
<span class="ruby-identifier">files</span> = <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">glob</span>( <span class="ruby-identifier">arg</span> )
|
531
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">Array</span>
|
532
|
-
<span class="ruby-identifier">files</span> = <span class="ruby-identifier">arg</span>
|
533
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">TrueClass</span>, <span class="ruby-constant">FalseClass</span>
|
534
|
-
<span class="ruby-identifier">include_features</span> = <span class="ruby-identifier">arg</span>
|
535
|
-
<span class="ruby-keyword kw">end</span>
|
536
|
-
<span class="ruby-keyword kw">end</span>
|
537
|
-
|
538
|
-
<span class="ruby-identifier">file_mtime</span> = {}
|
539
|
-
|
540
|
-
<span class="ruby-constant">Thread</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">start_time</span><span class="ruby-operator">|</span>
|
541
|
-
<span class="ruby-identifier">loop</span> <span class="ruby-keyword kw">do</span>
|
542
|
-
<span class="ruby-identifier">sleep</span> <span class="ruby-identifier">check_interval</span>
|
543
|
-
|
544
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">include_features</span>
|
545
|
-
<span class="ruby-identifier">feature_files</span> = <span class="ruby-identifier">$LOADED_FEATURES</span>.<span class="ruby-identifier">collect</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">feature</span><span class="ruby-operator">|</span>
|
546
|
-
<span class="ruby-identifier">$LOAD_PATH</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">lp</span><span class="ruby-operator">|</span> <span class="ruby-identifier">file</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">lp</span>, <span class="ruby-identifier">feature</span>) }
|
547
|
-
}.<span class="ruby-identifier">flatten</span>
|
548
|
-
|
549
|
-
<span class="ruby-identifier">feature_files</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">file</span><span class="ruby-operator">|</span>
|
550
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exists?</span>(<span class="ruby-identifier">file</span>) <span class="ruby-keyword kw">and</span> (<span class="ruby-identifier">mtime</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">file</span>).<span class="ruby-identifier">mtime</span>) <span class="ruby-operator">></span> (<span class="ruby-identifier">file_mtime</span>[<span class="ruby-identifier">file</span>] <span class="ruby-operator">||</span> <span class="ruby-identifier">start_time</span>)
|
551
|
-
<span class="ruby-identifier">$autoreload_dirty</span> = <span class="ruby-keyword kw">true</span>
|
552
|
-
<span class="ruby-identifier">file_mtime</span>[<span class="ruby-identifier">file</span>] = <span class="ruby-identifier">mtime</span>
|
553
|
-
<span class="ruby-constant">STDERR</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"File '#{ file }' reloaded"</span>
|
554
|
-
<span class="ruby-keyword kw">begin</span>
|
555
|
-
<span class="ruby-identifier">load</span>(<span class="ruby-identifier">file</span>)
|
556
|
-
<span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">Exception</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">e</span>
|
557
|
-
<span class="ruby-constant">STDERR</span>.<span class="ruby-identifier">puts</span> <span class="ruby-identifier">e</span>.<span class="ruby-identifier">inspect</span>
|
558
|
-
<span class="ruby-keyword kw">end</span>
|
559
|
-
<span class="ruby-keyword kw">end</span>
|
560
|
-
}
|
561
|
-
<span class="ruby-keyword kw">end</span>
|
562
|
-
|
563
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">files</span>
|
564
|
-
<span class="ruby-identifier">files</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">file</span><span class="ruby-operator">|</span>
|
565
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exists?</span>(<span class="ruby-identifier">file</span>) <span class="ruby-keyword kw">and</span> (<span class="ruby-identifier">mtime</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">file</span>).<span class="ruby-identifier">mtime</span>) <span class="ruby-operator">></span> (<span class="ruby-identifier">file_mtime</span>[<span class="ruby-identifier">file</span>] <span class="ruby-operator">||</span> <span class="ruby-identifier">start_time</span>)
|
566
|
-
<span class="ruby-identifier">$autoreload_dirty</span> = <span class="ruby-keyword kw">true</span>
|
567
|
-
<span class="ruby-identifier">file_mtime</span>[<span class="ruby-identifier">file</span>] = <span class="ruby-identifier">mtime</span>
|
568
|
-
<span class="ruby-constant">STDERR</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"File '#{ file }' changed"</span>
|
569
|
-
<span class="ruby-keyword kw">end</span>
|
570
|
-
<span class="ruby-keyword kw">end</span>
|
571
|
-
<span class="ruby-keyword kw">end</span>
|
572
|
-
|
573
|
-
<span class="ruby-keyword kw">end</span>
|
574
|
-
<span class="ruby-keyword kw">end</span>
|
575
|
-
|
576
|
-
<span class="ruby-keyword kw">end</span>
|
577
|
-
</pre>
|
578
|
-
</div>
|
579
|
-
</div>
|
580
|
-
</div>
|
581
|
-
<div class="method">
|
582
|
-
<div class="title">
|
583
|
-
<a name="M000420"></a><b>autoreload_files</b>( *args )
|
584
|
-
</div>
|
585
|
-
<div class="description">
|
586
|
-
<p>
|
587
|
-
Same as <a href="Kernel.html#M000419">autoreload</a>, but does not include
|
588
|
-
previously loaded features. This is equivalent to as adding a
|
589
|
-
‘false’ parameter to <a
|
590
|
-
href="Kernel.html#M000419">autoreload</a>.
|
591
|
-
</p>
|
592
|
-
</div>
|
593
|
-
<div class="aka">
|
594
|
-
This method is also aliased as
|
595
|
-
<a href="Kernel.html#M000421">autoreload_glob</a>
|
596
|
-
</div>
|
597
|
-
<div class="sourcecode">
|
598
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000420_source')" id="l_M000420_source">show source</a> ]</p>
|
599
|
-
<div id="M000420_source" class="dyn-source">
|
600
|
-
<pre>
|
601
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/autoreload.rb, line 82</span>
|
602
|
-
<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> )
|
603
|
-
<span class="ruby-identifier">autoreload</span>( <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-keyword kw">false</span> )
|
604
|
-
<span class="ruby-keyword kw">end</span>
|
605
|
-
</pre>
|
606
|
-
</div>
|
607
|
-
</div>
|
608
|
-
</div>
|
609
|
-
<div class="method">
|
610
|
-
<div class="title">
|
611
|
-
<a name="M000421"></a><b>autoreload_glob</b>( *args )
|
612
|
-
</div>
|
613
|
-
<div class="description">
|
614
|
-
<p>
|
615
|
-
Alias for <a href="Kernel.html#M000420">autoreload_files</a>
|
616
|
-
</p>
|
617
|
-
</div>
|
618
|
-
</div>
|
619
|
-
<div class="method">
|
620
|
-
<div class="title">
|
621
|
-
<a name="M000454"></a><b>bool?</b>()
|
622
|
-
</div>
|
623
|
-
<div class="description">
|
624
|
-
<p>
|
625
|
-
Returns true is an object is class <a href="TrueClass.html">TrueClass</a>
|
626
|
-
or <a href="FalseClass.html">FalseClass</a>, otherwise false.
|
627
|
-
</p>
|
628
|
-
<pre>
|
629
|
-
true.bool? #=> true
|
630
|
-
false.bool? #=> true
|
631
|
-
nil.bool? #=> false
|
632
|
-
</pre>
|
633
|
-
</div>
|
634
|
-
<div class="sourcecode">
|
635
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000454_source')" id="l_M000454_source">show source</a> ]</p>
|
636
|
-
<div id="M000454_source" class="dyn-source">
|
637
|
-
<pre>
|
638
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/bool.rb, line 36</span>
|
639
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">bool?</span>
|
640
|
-
(<span class="ruby-keyword kw">true</span> <span class="ruby-operator">==</span> <span class="ruby-keyword kw">self</span> <span class="ruby-keyword kw">or</span> <span class="ruby-keyword kw">false</span> <span class="ruby-operator">==</span> <span class="ruby-keyword kw">self</span>)
|
641
|
-
<span class="ruby-keyword kw">end</span>
|
642
|
-
</pre>
|
643
|
-
</div>
|
644
|
-
</div>
|
645
|
-
</div>
|
646
|
-
<div class="method">
|
647
|
-
<div class="title">
|
648
|
-
<a name="M000429"></a><b>bug!</b>( message = 'must not happen' )
|
649
|
-
</div>
|
650
|
-
<div class="description">
|
651
|
-
<p>
|
652
|
-
Raises a ScritBug error with a message.
|
653
|
-
</p>
|
654
|
-
<pre>
|
655
|
-
if find_bug then
|
656
|
-
bug! "unknown bug found"
|
657
|
-
end
|
658
|
-
</pre>
|
659
|
-
</div>
|
660
|
-
<div class="sourcecode">
|
661
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000429_source')" id="l_M000429_source">show source</a> ]</p>
|
662
|
-
<div id="M000429_source" class="dyn-source">
|
663
|
-
<pre>
|
664
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/bug.rb, line 14</span>
|
665
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">bug!</span>( <span class="ruby-identifier">message</span> = <span class="ruby-value str">'must not happen'</span> )
|
666
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ScriptBug</span>, <span class="ruby-value str">"\n[SCRIPT BUG] "</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">message</span>
|
667
|
-
<span class="ruby-keyword kw">end</span>
|
668
|
-
</pre>
|
669
|
-
</div>
|
670
|
-
</div>
|
671
|
-
</div>
|
672
|
-
<div class="method">
|
673
|
-
<div class="title">
|
674
|
-
<a name="M000425"></a><b>cache</b>(m = nil)
|
675
|
-
</div>
|
676
|
-
<div class="description">
|
677
|
-
<p>
|
678
|
-
Object#cache is essentially like <a
|
679
|
-
href="Module.html#M000185">Module#memoize</a> except it can also be used on
|
680
|
-
singleton/eigen methods. OTOH, memoize’s implementation is arguably
|
681
|
-
better for it’s use of bind instead of alias. Eventually the two
|
682
|
-
implmenations will be reconciled with a single implmentation.
|
683
|
-
</p>
|
684
|
-
</div>
|
685
|
-
<div class="sourcecode">
|
686
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000425_source')" id="l_M000425_source">show source</a> ]</p>
|
687
|
-
<div id="M000425_source" class="dyn-source">
|
688
|
-
<pre>
|
689
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/cache.rb, line 10</span>
|
690
|
-
<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>
|
691
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">m</span>
|
692
|
-
(<span class="ruby-constant">Module</span> <span class="ruby-operator">===</span> <span class="ruby-keyword kw">self</span> <span class="ruby-operator">?</span> <span class="ruby-keyword kw">self</span> <span class="ruby-operator">:</span> (<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)).<span class="ruby-identifier">module_eval</span> <span class="ruby-value str">"alias_method '__\#{ m }__', '\#{ m }'\ndef \#{ m }(*__a__,&__b__)\nc = cache['\#{ m }']\nk = [__a__,__b__]\nif c.has_key? k\nc[k]\nelse\nc[k] = __\#{ m }__(*__a__,&__b__)\nend\nend\n"</span>
|
693
|
-
<span class="ruby-keyword kw">end</span>
|
694
|
-
<span class="ruby-ivar">@cache</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">Hash</span><span class="ruby-operator">::</span><span class="ruby-identifier">new</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">h</span>,<span class="ruby-identifier">k</span><span class="ruby-operator">|</span> <span class="ruby-identifier">h</span>[<span class="ruby-identifier">k</span>]={}}
|
695
|
-
<span class="ruby-keyword kw">end</span>
|
696
|
-
</pre>
|
697
|
-
</div>
|
698
|
-
</div>
|
699
|
-
</div>
|
700
|
-
<div class="method">
|
701
|
-
<div class="title">
|
702
|
-
<a name="M000402"></a><b>call_stack</b>( level = 1 )
|
703
|
-
</div>
|
704
|
-
<div class="sourcecode">
|
705
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000402_source')" id="l_M000402_source">show source</a> ]</p>
|
706
|
-
<div id="M000402_source" class="dyn-source">
|
707
|
-
<pre>
|
708
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/call_stack.rb, line 23</span>
|
709
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">call_stack</span>( <span class="ruby-identifier">level</span> = <span class="ruby-value">1</span> )
|
710
|
-
<span class="ruby-identifier">call_str_array</span> = <span class="ruby-identifier">pp_call_stack</span>(<span class="ruby-identifier">level</span>)
|
711
|
-
<span class="ruby-identifier">stack</span> = []
|
712
|
-
<span class="ruby-identifier">call_str_array</span>.<span class="ruby-identifier">each</span>{ <span class="ruby-operator">|</span><span class="ruby-identifier">call_str</span><span class="ruby-operator">|</span>
|
713
|
-
<span class="ruby-identifier">file</span>, <span class="ruby-identifier">lineno</span>, <span class="ruby-identifier">method</span> = <span class="ruby-identifier">call_str</span>.<span class="ruby-identifier">split</span>(<span class="ruby-value str">':'</span>)
|
714
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">method</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/in `(.*)'/</span> <span class="ruby-keyword kw">then</span>
|
715
|
-
<span class="ruby-identifier">method</span> = <span class="ruby-identifier">$1</span>.<span class="ruby-identifier">intern</span>()
|
716
|
-
<span class="ruby-keyword kw">end</span>
|
717
|
-
<span class="ruby-identifier">stack</span> <span class="ruby-operator"><<</span> [<span class="ruby-identifier">file</span>, <span class="ruby-identifier">lineno</span>.<span class="ruby-identifier">to_i</span>, <span class="ruby-identifier">method</span>]
|
718
|
-
}
|
719
|
-
<span class="ruby-identifier">stack</span>
|
720
|
-
<span class="ruby-keyword kw">end</span>
|
721
|
-
</pre>
|
722
|
-
</div>
|
723
|
-
</div>
|
724
|
-
</div>
|
725
|
-
<div class="method">
|
726
|
-
<div class="title">
|
727
|
-
<a name="M000436"></a><b>complete</b>() {|| ...}
|
728
|
-
</div>
|
729
|
-
<div class="sourcecode">
|
730
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000436_source')" id="l_M000436_source">show source</a> ]</p>
|
731
|
-
<div id="M000436_source" class="dyn-source">
|
732
|
-
<pre>
|
733
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/complete.rb, line 3</span>
|
734
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">complete</span>
|
735
|
-
<span class="ruby-identifier">loop</span> { <span class="ruby-keyword kw">break</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-keyword kw">yield</span> }
|
736
|
-
<span class="ruby-keyword kw">end</span>
|
737
|
-
</pre>
|
738
|
-
</div>
|
739
|
-
</div>
|
740
|
-
</div>
|
741
|
-
<div class="method">
|
742
|
-
<div class="title">
|
743
|
-
<a name="M000405"></a><b>constant</b>(const)
|
744
|
-
</div>
|
745
|
-
<div class="description">
|
746
|
-
<p>
|
747
|
-
This is similar to +Module#const_get+ but is accessible at all levels, and,
|
748
|
-
unlike <tt>const_get</tt>, can handle module hierarchy.
|
749
|
-
</p>
|
750
|
-
<pre>
|
751
|
-
constant("Fixnum") # -> Fixnum
|
752
|
-
constant(:Fixnum) # -> Fixnum
|
753
|
-
|
754
|
-
constant("Process::Sys") # -> Process::Sys
|
755
|
-
constant("Regexp::MULTILINE") # -> 4
|
756
|
-
|
757
|
-
require 'test/unit'
|
758
|
-
Test.constant("Unit::Assertions") # -> Test::Unit::Assertions
|
759
|
-
Test.constant("::Test::Unit") # -> Test::Unit
|
760
|
-
</pre>
|
761
|
-
</div>
|
762
|
-
<div class="sourcecode">
|
763
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000405_source')" id="l_M000405_source">show source</a> ]</p>
|
764
|
-
<div id="M000405_source" class="dyn-source">
|
765
|
-
<pre>
|
766
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/constant.rb, line 17</span>
|
767
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">constant</span>(<span class="ruby-identifier">const</span>)
|
768
|
-
<span class="ruby-identifier">const</span> = <span class="ruby-identifier">const</span>.<span class="ruby-identifier">to_s</span>.<span class="ruby-identifier">dup</span>
|
769
|
-
<span class="ruby-identifier">base</span> = <span class="ruby-identifier">const</span>.<span class="ruby-identifier">sub!</span>(<span class="ruby-regexp re">/^::/</span>, <span class="ruby-value str">''</span>) <span class="ruby-operator">?</span> <span class="ruby-constant">Object</span> <span class="ruby-operator">:</span> ( <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">kind_of?</span>(<span class="ruby-constant">Module</span>) <span class="ruby-operator">?</span> <span class="ruby-keyword kw">self</span> <span class="ruby-operator">:</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">class</span> )
|
770
|
-
<span class="ruby-identifier">const</span>.<span class="ruby-identifier">split</span>(<span class="ruby-regexp re">/::/</span>).<span class="ruby-identifier">inject</span>(<span class="ruby-identifier">base</span>){ <span class="ruby-operator">|</span><span class="ruby-identifier">mod</span>, <span class="ruby-identifier">name</span><span class="ruby-operator">|</span> <span class="ruby-identifier">mod</span>.<span class="ruby-identifier">const_get</span>(<span class="ruby-identifier">name</span>) }
|
771
|
-
<span class="ruby-keyword kw">end</span>
|
772
|
-
</pre>
|
773
|
-
</div>
|
774
|
-
</div>
|
775
|
-
</div>
|
776
|
-
<div class="method">
|
777
|
-
<div class="title">
|
778
|
-
<a name="M000406"></a><b>copy</b>()
|
779
|
-
</div>
|
780
|
-
<div class="description">
|
781
|
-
<p>
|
782
|
-
Anything that can be marshaled can be copied in totality. This is also
|
783
|
-
commonly called a <a href="Kernel.html#M000451">deep_copy</a>.
|
784
|
-
</p>
|
785
|
-
<pre>
|
786
|
-
"ABC".copy #=> "ABC"
|
787
|
-
</pre>
|
788
|
-
</div>
|
789
|
-
<div class="sourcecode">
|
790
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000406_source')" id="l_M000406_source">show source</a> ]</p>
|
791
|
-
<div id="M000406_source" class="dyn-source">
|
792
|
-
<pre>
|
793
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/copy.rb, line 9</span>
|
794
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">copy</span>
|
795
|
-
<span class="ruby-constant">Marshal</span><span class="ruby-operator">::</span><span class="ruby-identifier">load</span>(<span class="ruby-constant">Marshal</span><span class="ruby-operator">::</span><span class="ruby-identifier">dump</span>(<span class="ruby-keyword kw">self</span>))
|
796
|
-
<span class="ruby-keyword kw">end</span>
|
797
|
-
</pre>
|
798
|
-
</div>
|
799
|
-
</div>
|
800
|
-
</div>
|
801
|
-
<div class="method">
|
802
|
-
<div class="title">
|
803
|
-
<a name="M000451"></a><b>deep_copy</b>()
|
804
|
-
</div>
|
805
|
-
<div class="description">
|
806
|
-
<p>
|
807
|
-
Anything that can be marshaled can be copied in totality. This is also just
|
808
|
-
called copy.
|
809
|
-
</p>
|
810
|
-
<pre>
|
811
|
-
"ABC".deep_copy #=> "ABC"
|
812
|
-
</pre>
|
813
|
-
</div>
|
814
|
-
<div class="sourcecode">
|
815
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000451_source')" id="l_M000451_source">show source</a> ]</p>
|
816
|
-
<div id="M000451_source" class="dyn-source">
|
817
|
-
<pre>
|
818
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/deep_copy.rb, line 9</span>
|
819
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">deep_copy</span>
|
820
|
-
<span class="ruby-constant">Marshal</span><span class="ruby-operator">::</span><span class="ruby-identifier">load</span>(<span class="ruby-constant">Marshal</span><span class="ruby-operator">::</span><span class="ruby-identifier">dump</span>(<span class="ruby-keyword kw">self</span>))
|
821
|
-
<span class="ruby-keyword kw">end</span>
|
822
|
-
</pre>
|
823
|
-
</div>
|
824
|
-
</div>
|
825
|
-
</div>
|
826
|
-
<div class="method">
|
827
|
-
<div class="title">
|
828
|
-
<a name="M000407"></a><b>demo</b>(out=$stdout,&block)
|
829
|
-
</div>
|
830
|
-
<div class="description">
|
831
|
-
<p>
|
832
|
-
For debugging and showing examples. Currently this takes an argument of a
|
833
|
-
string in a block.
|
834
|
-
</p>
|
835
|
-
<pre>
|
836
|
-
demo {%{ a = [1,2,3] }}
|
837
|
-
demo {%{ a.slice(1,2) }}
|
838
|
-
demo {%{ a.map { |x| x**3 } }}
|
839
|
-
</pre>
|
840
|
-
<p>
|
841
|
-
Produces:
|
842
|
-
</p>
|
843
|
-
<pre>
|
844
|
-
a = [1,2,3] #=> [1, 2, 3]
|
845
|
-
a.slice(1,2) #=> [2, 3]
|
846
|
-
a.map { |x| x**3 } #=> [1, 8, 27]
|
847
|
-
</pre>
|
848
|
-
</div>
|
849
|
-
<div class="sourcecode">
|
850
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000407_source')" id="l_M000407_source">show source</a> ]</p>
|
851
|
-
<div id="M000407_source" class="dyn-source">
|
852
|
-
<pre>
|
853
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/demo.rb, line 23</span>
|
854
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">demo</span>(<span class="ruby-identifier">out</span>=<span class="ruby-identifier">$stdout</span>,<span class="ruby-operator">&</span><span class="ruby-identifier">block</span>)
|
855
|
-
<span class="ruby-identifier">out</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">sprintf</span>(<span class="ruby-value str">"%-25s#=> %s\n"</span>, <span class="ruby-identifier">expr</span> = <span class="ruby-identifier">block</span>.<span class="ruby-identifier">call</span>, <span class="ruby-identifier">eval</span>(<span class="ruby-identifier">expr</span>, <span class="ruby-identifier">block</span>.<span class="ruby-identifier">binding</span>).<span class="ruby-identifier">inspect</span>)
|
856
|
-
<span class="ruby-keyword kw">end</span>
|
857
|
-
</pre>
|
858
|
-
</div>
|
859
|
-
</div>
|
860
|
-
</div>
|
861
|
-
<div class="method">
|
862
|
-
<div class="title">
|
863
|
-
<a name="M000447"></a><b>eigenclass</b>()
|
864
|
-
</div>
|
865
|
-
<div class="sourcecode">
|
866
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000447_source')" id="l_M000447_source">show source</a> ]</p>
|
867
|
-
<div id="M000447_source" class="dyn-source">
|
868
|
-
<pre>
|
869
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/eigenclass.rb, line 14</span>
|
870
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">eigenclass</span>
|
871
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)
|
872
|
-
<span class="ruby-keyword kw">end</span>
|
873
|
-
</pre>
|
874
|
-
</div>
|
875
|
-
</div>
|
876
|
-
</div>
|
877
|
-
<div class="method">
|
878
|
-
<div class="title">
|
879
|
-
<a name="M000453"></a><b>false?</b>()
|
880
|
-
</div>
|
881
|
-
<div class="description">
|
882
|
-
<p>
|
883
|
-
Returns true is an object is class <a
|
884
|
-
href="FalseClass.html">FalseClass</a>, otherwise false.
|
885
|
-
</p>
|
886
|
-
<pre>
|
887
|
-
true.false? #=> false
|
888
|
-
false.false? #=> true
|
889
|
-
nil.false? #=> false
|
890
|
-
</pre>
|
891
|
-
</div>
|
892
|
-
<div class="sourcecode">
|
893
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000453_source')" id="l_M000453_source">show source</a> ]</p>
|
894
|
-
<div id="M000453_source" class="dyn-source">
|
895
|
-
<pre>
|
896
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/bool.rb, line 25</span>
|
897
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">false?</span>
|
898
|
-
(<span class="ruby-keyword kw">false</span> <span class="ruby-operator">==</span> <span class="ruby-keyword kw">self</span>)
|
899
|
-
<span class="ruby-keyword kw">end</span>
|
900
|
-
</pre>
|
901
|
-
</div>
|
902
|
-
</div>
|
903
|
-
</div>
|
904
|
-
<div class="method">
|
905
|
-
<div class="title">
|
906
|
-
<a name="M000430"></a><b>generate_method_name</b>( name='a' )
|
907
|
-
</div>
|
908
|
-
<div class="description">
|
909
|
-
<p>
|
910
|
-
Generates a new symbol that is unique among the method names of the object.
|
911
|
-
If a name argument is given, it will generate a similar name.
|
912
|
-
</p>
|
913
|
-
<pre>
|
914
|
-
Class.generate_method_name( :class ) => :_clast_
|
915
|
-
</pre>
|
916
|
-
</div>
|
917
|
-
<div class="sourcecode">
|
918
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000430_source')" id="l_M000430_source">show source</a> ]</p>
|
919
|
-
<div id="M000430_source" class="dyn-source">
|
920
|
-
<pre>
|
921
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/generate_method_name.rb, line 10</span>
|
922
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generate_method_name</span>( <span class="ruby-identifier">name</span>=<span class="ruby-value str">'a'</span> )
|
923
|
-
<span class="ruby-identifier">s</span> = <span class="ruby-identifier">name</span>.<span class="ruby-identifier">to_s</span>
|
924
|
-
<span class="ruby-keyword kw">while</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">respond_to?</span>( <span class="ruby-node">"_#{s}_"</span> )
|
925
|
-
<span class="ruby-identifier">s</span> = <span class="ruby-identifier">s</span>.<span class="ruby-identifier">succ</span>
|
926
|
-
<span class="ruby-keyword kw">end</span>
|
927
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-node">"_#{s}_"</span>.<span class="ruby-identifier">to_sym</span>
|
928
|
-
<span class="ruby-keyword kw">end</span>
|
929
|
-
</pre>
|
930
|
-
</div>
|
931
|
-
</div>
|
932
|
-
</div>
|
933
|
-
<div class="method">
|
934
|
-
<div class="title">
|
935
|
-
<a name="M000404"></a><b>get_by_id</b>( id )
|
936
|
-
</div>
|
937
|
-
<div class="sourcecode">
|
938
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000404_source')" id="l_M000404_source">show source</a> ]</p>
|
939
|
-
<div id="M000404_source" class="dyn-source">
|
940
|
-
<pre>
|
941
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/get_by_id.rb, line 6</span>
|
942
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">get_by_id</span>( <span class="ruby-identifier">id</span> )
|
943
|
-
<span class="ruby-constant">ObjectSpace</span>.<span class="ruby-identifier">_id2ref</span>( <span class="ruby-identifier">id</span> )
|
944
|
-
<span class="ruby-keyword kw">end</span>
|
945
|
-
</pre>
|
946
|
-
</div>
|
947
|
-
</div>
|
948
|
-
</div>
|
949
|
-
<div class="method">
|
950
|
-
<div class="title">
|
951
|
-
<a name="M000414"></a><b>in?</b>(other)
|
952
|
-
</div>
|
953
|
-
<div class="description">
|
954
|
-
<p>
|
955
|
-
Is self included in other?
|
956
|
-
</p>
|
957
|
-
<pre>
|
958
|
-
5.in?(0..10) #=> true
|
959
|
-
5.in?([0,1,2,3]) #=> false
|
960
|
-
</pre>
|
961
|
-
</div>
|
962
|
-
<div class="sourcecode">
|
963
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000414_source')" id="l_M000414_source">show source</a> ]</p>
|
964
|
-
<div id="M000414_source" class="dyn-source">
|
965
|
-
<pre>
|
966
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/in.rb, line 9</span>
|
967
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">in?</span>(<span class="ruby-identifier">other</span>)
|
968
|
-
<span class="ruby-identifier">other</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-keyword kw">self</span>)
|
969
|
-
<span class="ruby-keyword kw">end</span>
|
970
|
-
</pre>
|
971
|
-
</div>
|
972
|
-
</div>
|
973
|
-
</div>
|
974
|
-
<div class="method">
|
975
|
-
<div class="title">
|
976
|
-
<a name="M000418"></a><b>instance_assign</b>( name, value )
|
977
|
-
</div>
|
978
|
-
<div class="description">
|
979
|
-
<p>
|
980
|
-
Universal assignment. This is a meta-programming method, which allows you
|
981
|
-
to assign any type of variable.
|
982
|
-
</p>
|
983
|
-
</div>
|
984
|
-
<div class="sourcecode">
|
985
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000418_source')" id="l_M000418_source">show source</a> ]</p>
|
986
|
-
<div id="M000418_source" class="dyn-source">
|
987
|
-
<pre>
|
988
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/instance_assign.rb, line 7</span>
|
989
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">instance_assign</span>( <span class="ruby-identifier">name</span>, <span class="ruby-identifier">value</span> )
|
990
|
-
<span class="ruby-identifier">k</span> = <span class="ruby-identifier">name</span>.<span class="ruby-identifier">to_s</span>
|
991
|
-
<span class="ruby-identifier">v</span> = <span class="ruby-identifier">value</span>
|
992
|
-
<span class="ruby-regexp re">/^([@$]{0,2})/</span> <span class="ruby-operator">=~</span> <span class="ruby-identifier">k</span>
|
993
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">$1</span>
|
994
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value str">'$'</span>, <span class="ruby-value str">'@@'</span>
|
995
|
-
<span class="ruby-identifier">instance_eval</span> <span class="ruby-node">%Q{ #{k} = v }</span>
|
996
|
-
<span class="ruby-keyword kw">when</span> <span class="ruby-value str">'@'</span>
|
997
|
-
<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-identifier">k</span>, <span class="ruby-identifier">v</span> )
|
998
|
-
<span class="ruby-keyword kw">else</span>
|
999
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">__send__</span>( <span class="ruby-node">"#{k}="</span>, <span class="ruby-identifier">v</span> ) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">respond_to?</span>(<span class="ruby-node">"#{k}="</span>)
|
1000
|
-
<span class="ruby-comment cmt"># No accessor? What to do? Assume instance var, or error? ...</span>
|
1001
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-node">"@#{k}"</span>, <span class="ruby-identifier">v</span> )
|
1002
|
-
<span class="ruby-keyword kw">end</span>
|
1003
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">value</span>
|
1004
|
-
<span class="ruby-keyword kw">end</span>
|
1005
|
-
</pre>
|
1006
|
-
</div>
|
1007
|
-
</div>
|
1008
|
-
</div>
|
1009
|
-
<div class="method">
|
1010
|
-
<div class="title">
|
1011
|
-
<a name="M000440"></a><b>instvar</b>( sym )
|
1012
|
-
</div>
|
1013
|
-
<div class="sourcecode">
|
1014
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000440_source')" id="l_M000440_source">show source</a> ]</p>
|
1015
|
-
<div id="M000440_source" class="dyn-source">
|
1016
|
-
<pre>
|
1017
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/instvar.rb, line 5</span>
|
1018
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">instvar</span>( <span class="ruby-identifier">sym</span> )
|
1019
|
-
<span class="ruby-identifier">instance_variable_get</span>( <span class="ruby-node">"@#{sym}"</span> )
|
1020
|
-
<span class="ruby-keyword kw">end</span>
|
1021
|
-
</pre>
|
1022
|
-
</div>
|
1023
|
-
</div>
|
1024
|
-
</div>
|
1025
|
-
<div class="method">
|
1026
|
-
<div class="title">
|
1027
|
-
<a name="M000441"></a><b>instvar!</b>( sym, val )
|
1028
|
-
</div>
|
1029
|
-
<div class="sourcecode">
|
1030
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000441_source')" id="l_M000441_source">show source</a> ]</p>
|
1031
|
-
<div id="M000441_source" class="dyn-source">
|
1032
|
-
<pre>
|
1033
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/instvar.rb, line 9</span>
|
1034
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">instvar!</span>( <span class="ruby-identifier">sym</span>, <span class="ruby-identifier">val</span> )
|
1035
|
-
<span class="ruby-identifier">instance_variable_set</span>( <span class="ruby-node">"@#{sym}"</span>, <span class="ruby-identifier">val</span> )
|
1036
|
-
<span class="ruby-keyword kw">end</span>
|
1037
|
-
</pre>
|
1038
|
-
</div>
|
1039
|
-
</div>
|
1040
|
-
</div>
|
1041
|
-
<div class="method">
|
1042
|
-
<div class="title">
|
1043
|
-
<a name="M000434"></a><b>maybe</b>(chance = 0.5) {|if rand < chance| ...}
|
1044
|
-
</div>
|
1045
|
-
<div class="description">
|
1046
|
-
<p>
|
1047
|
-
Random generator that returns true or false. Can also take a block that has
|
1048
|
-
a 50/50 chance to being executed.
|
1049
|
-
</p>
|
1050
|
-
<pre>
|
1051
|
-
maybe #=> true
|
1052
|
-
maybe #=> false
|
1053
|
-
</pre>
|
1054
|
-
</div>
|
1055
|
-
<div class="sourcecode">
|
1056
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000434_source')" id="l_M000434_source">show source</a> ]</p>
|
1057
|
-
<div id="M000434_source" class="dyn-source">
|
1058
|
-
<pre>
|
1059
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/maybe.rb, line 10</span>
|
1060
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">maybe</span>(<span class="ruby-identifier">chance</span> = <span class="ruby-value">0</span><span class="ruby-value">.5</span>, <span class="ruby-operator">&</span><span class="ruby-identifier">block</span>)
|
1061
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block</span> <span class="ruby-keyword kw">then</span>
|
1062
|
-
<span class="ruby-keyword kw">yield</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">rand</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">chance</span>
|
1063
|
-
<span class="ruby-keyword kw">else</span>
|
1064
|
-
<span class="ruby-identifier">rand</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">chance</span>
|
1065
|
-
<span class="ruby-keyword kw">end</span>
|
1066
|
-
<span class="ruby-keyword kw">end</span>
|
1067
|
-
</pre>
|
1068
|
-
</div>
|
1069
|
-
</div>
|
1070
|
-
</div>
|
1071
|
-
<div class="method">
|
1072
|
-
<div class="title">
|
1073
|
-
<a name="M000450"></a><b>method!</b>(s)
|
1074
|
-
</div>
|
1075
|
-
<div class="description">
|
1076
|
-
<p>
|
1077
|
-
Easy access to method as objects, and they retain state!
|
1078
|
-
</p>
|
1079
|
-
<pre>
|
1080
|
-
def hello
|
1081
|
-
puts "Hello World!"
|
1082
|
-
end
|
1083
|
-
p method!(:hello) #=> <Method: #hello>
|
1084
|
-
</pre>
|
1085
|
-
</div>
|
1086
|
-
<div class="sourcecode">
|
1087
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000450_source')" id="l_M000450_source">show source</a> ]</p>
|
1088
|
-
<div id="M000450_source" class="dyn-source">
|
1089
|
-
<pre>
|
1090
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/method.rb, line 39</span>
|
1091
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">method!</span>(<span class="ruby-identifier">s</span>)
|
1092
|
-
( <span class="ruby-ivar">@__methods__</span> <span class="ruby-operator">||=</span> {} )[<span class="ruby-identifier">s</span>] <span class="ruby-operator">||=</span> <span class="ruby-identifier">method</span>(<span class="ruby-identifier">s</span>)
|
1093
|
-
<span class="ruby-keyword kw">end</span>
|
1094
|
-
</pre>
|
1095
|
-
</div>
|
1096
|
-
</div>
|
1097
|
-
</div>
|
1098
|
-
<div class="method">
|
1099
|
-
<div class="title">
|
1100
|
-
<a name="M000422"></a><b>methods</b>(*args)
|
1101
|
-
</div>
|
1102
|
-
<div class="description">
|
1103
|
-
<p>
|
1104
|
-
Returns a list of methods according to symbol(s) given.
|
1105
|
-
</p>
|
1106
|
-
<p>
|
1107
|
-
Usable symbols include:
|
1108
|
-
</p>
|
1109
|
-
<ul>
|
1110
|
-
<li><tt>:inherited</tt> or <tt>:ancestors</tt>
|
1111
|
-
|
1112
|
-
</li>
|
1113
|
-
<li><tt>:local</tt> or <tt>:no_ancestors</tt>
|
1114
|
-
|
1115
|
-
</li>
|
1116
|
-
<li><tt>:public</tt>
|
1117
|
-
|
1118
|
-
</li>
|
1119
|
-
<li><tt>:private</tt>
|
1120
|
-
|
1121
|
-
</li>
|
1122
|
-
<li><tt>:protected</tt>
|
1123
|
-
|
1124
|
-
</li>
|
1125
|
-
<li><tt>:singleton</tt>
|
1126
|
-
|
1127
|
-
</li>
|
1128
|
-
<li><tt>:all</tt>
|
1129
|
-
|
1130
|
-
</li>
|
1131
|
-
</ul>
|
1132
|
-
<p>
|
1133
|
-
It no symbol is given then :public is assumed. Unrecognized symbols raise
|
1134
|
-
an error.
|
1135
|
-
</p>
|
1136
|
-
<pre>
|
1137
|
-
def test
|
1138
|
-
puts("Hello World!")
|
1139
|
-
end
|
1140
|
-
|
1141
|
-
methods(:local) #=> ['test']
|
1142
|
-
</pre>
|
1143
|
-
</div>
|
1144
|
-
<div class="sourcecode">
|
1145
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000422_source')" id="l_M000422_source">show source</a> ]</p>
|
1146
|
-
<div id="M000422_source" class="dyn-source">
|
1147
|
-
<pre>
|
1148
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/methods.rb, line 26</span>
|
1149
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">methods</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
1150
|
-
<span class="ruby-identifier">args</span> = [ <span class="ruby-identifier">:public</span>, <span class="ruby-identifier">:local</span>, <span class="ruby-identifier">:ancestors</span> ] <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">empty?</span>
|
1151
|
-
<span class="ruby-identifier">m</span> = <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">instance_methods</span>( <span class="ruby-operator">*</span><span class="ruby-identifier">args</span> )
|
1152
|
-
<span class="ruby-identifier">m</span> <span class="ruby-operator">|=</span> <span class="ruby-identifier">singleton_methods</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">include?</span>( <span class="ruby-identifier">:singleton</span> ) <span class="ruby-keyword kw">or</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">include?</span>( <span class="ruby-identifier">:all</span> )
|
1153
|
-
<span class="ruby-identifier">m</span>
|
1154
|
-
<span class="ruby-keyword kw">end</span>
|
1155
|
-
</pre>
|
1156
|
-
</div>
|
1157
|
-
</div>
|
1158
|
-
</div>
|
1159
|
-
<div class="method">
|
1160
|
-
<div class="title">
|
1161
|
-
<a name="M000428"></a><b>nack</b>()
|
1162
|
-
</div>
|
1163
|
-
<div class="sourcecode">
|
1164
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000428_source')" id="l_M000428_source">show source</a> ]</p>
|
1165
|
-
<div id="M000428_source" class="dyn-source">
|
1166
|
-
<pre>
|
1167
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/nack.rb, line 9</span>
|
1168
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">nack</span>; <span class="ruby-constant">NackClass</span>.<span class="ruby-identifier">new</span> ; <span class="ruby-keyword kw">end</span>
|
1169
|
-
</pre>
|
1170
|
-
</div>
|
1171
|
-
</div>
|
1172
|
-
</div>
|
1173
|
-
<div class="method">
|
1174
|
-
<div class="title">
|
1175
|
-
<a name="M000437"></a><b>new</b>()
|
1176
|
-
</div>
|
1177
|
-
<div class="description">
|
1178
|
-
<p>
|
1179
|
-
Synonymous with clone, this is an interesting method in that it promotes
|
1180
|
-
prototype-based Ruby. Now Classes aren’t the only things that respond
|
1181
|
-
to <a href="Kernel.html#M000437">new</a>.
|
1182
|
-
</p>
|
1183
|
-
<pre>
|
1184
|
-
"ABC".new => "ABC"
|
1185
|
-
</pre>
|
1186
|
-
</div>
|
1187
|
-
<div class="sourcecode">
|
1188
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000437_source')" id="l_M000437_source">show source</a> ]</p>
|
1189
|
-
<div id="M000437_source" class="dyn-source">
|
1190
|
-
<pre>
|
1191
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/new.rb, line 10</span>
|
1192
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">new</span>
|
1193
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">clone</span>
|
1194
|
-
<span class="ruby-keyword kw">end</span>
|
1195
|
-
</pre>
|
1196
|
-
</div>
|
1197
|
-
</div>
|
1198
|
-
</div>
|
1199
|
-
<div class="method">
|
1200
|
-
<div class="title">
|
1201
|
-
<a name="M000449"></a><b>object_hexid</b>()
|
1202
|
-
</div>
|
1203
|
-
<div class="description">
|
1204
|
-
<p>
|
1205
|
-
Returns the object id as a string in hexideciaml, which is how Ruby reports
|
1206
|
-
them with inspect.
|
1207
|
-
</p>
|
1208
|
-
<pre>
|
1209
|
-
"ABC".object_hexid #=> "0x402d359c"
|
1210
|
-
</pre>
|
1211
|
-
</div>
|
1212
|
-
<div class="sourcecode">
|
1213
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000449_source')" id="l_M000449_source">show source</a> ]</p>
|
1214
|
-
<div id="M000449_source" class="dyn-source">
|
1215
|
-
<pre>
|
1216
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/object_hexid.rb, line 9</span>
|
1217
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">object_hexid</span>
|
1218
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-value str">"0x"</span> <span class="ruby-operator"><<</span> (<span class="ruby-value str">'%.x'</span> <span class="ruby-operator">%</span> (<span class="ruby-value">2</span><span class="ruby-operator">*</span><span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">__id__</span>))[<span class="ruby-value">1</span><span class="ruby-operator">..</span><span class="ruby-value">-1</span>]
|
1219
|
-
<span class="ruby-keyword kw">end</span>
|
1220
|
-
</pre>
|
1221
|
-
</div>
|
1222
|
-
</div>
|
1223
|
-
</div>
|
1224
|
-
<div class="method">
|
1225
|
-
<div class="title">
|
1226
|
-
<a name="M000433"></a><b>op_esc</b>( str )
|
1227
|
-
</div>
|
1228
|
-
<div class="sourcecode">
|
1229
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000433_source')" id="l_M000433_source">show source</a> ]</p>
|
1230
|
-
<div id="M000433_source" class="dyn-source">
|
1231
|
-
<pre>
|
1232
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/op_esc.rb, line 33</span>
|
1233
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">op_esc</span>( <span class="ruby-identifier">str</span> )
|
1234
|
-
<span class="ruby-identifier">str</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-constant">OPERATORS_REGEXP</span>){ <span class="ruby-constant">OPERATORS_ESC_TABLE</span>[<span class="ruby-identifier">$1</span>] }
|
1235
|
-
<span class="ruby-keyword kw">end</span>
|
1236
|
-
</pre>
|
1237
|
-
</div>
|
1238
|
-
</div>
|
1239
|
-
</div>
|
1240
|
-
<div class="method">
|
1241
|
-
<div class="title">
|
1242
|
-
<a name="M000439"></a><b>own</b>(&blk)
|
1243
|
-
</div>
|
1244
|
-
<div class="description">
|
1245
|
-
<p>
|
1246
|
-
Easy access to an object’s specialized class, otherwise known as
|
1247
|
-
it’s metaclass or singleton class.
|
1248
|
-
</p>
|
1249
|
-
</div>
|
1250
|
-
<div class="sourcecode">
|
1251
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000439_source')" id="l_M000439_source">show source</a> ]</p>
|
1252
|
-
<div id="M000439_source" class="dyn-source">
|
1253
|
-
<pre>
|
1254
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/own.rb, line 7</span>
|
1255
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">own</span>(<span class="ruby-operator">&</span><span class="ruby-identifier">blk</span>)
|
1256
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>).<span class="ruby-identifier">module_eval</span>( <span class="ruby-operator">&</span><span class="ruby-identifier">blk</span> ) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">blk</span>
|
1257
|
-
<span class="ruby-keyword kw">return</span> (<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)
|
1258
|
-
<span class="ruby-keyword kw">end</span>
|
1259
|
-
</pre>
|
1260
|
-
</div>
|
1261
|
-
</div>
|
1262
|
-
</div>
|
1263
|
-
<div class="method">
|
1264
|
-
<div class="title">
|
1265
|
-
<a name="M000403"></a><b>p</b>( x )
|
1266
|
-
</div>
|
1267
|
-
<div class="description">
|
1268
|
-
<p>
|
1269
|
-
alias_method :pr, :p
|
1270
|
-
</p>
|
1271
|
-
<pre>
|
1272
|
-
REdefines standrard #p kernel method
|
1273
|
-
to pass through its argument.
|
1274
|
-
</pre>
|
1275
|
-
</div>
|
1276
|
-
<div class="sourcecode">
|
1277
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000403_source')" id="l_M000403_source">show source</a> ]</p>
|
1278
|
-
<div id="M000403_source" class="dyn-source">
|
1279
|
-
<pre>
|
1280
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/p.rb, line 7</span>
|
1281
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">p</span>( <span class="ruby-identifier">x</span> )
|
1282
|
-
<span class="ruby-identifier">puts</span> <span class="ruby-identifier">x</span>.<span class="ruby-identifier">inspect</span>
|
1283
|
-
<span class="ruby-identifier">x</span>
|
1284
|
-
<span class="ruby-keyword kw">end</span>
|
1285
|
-
</pre>
|
1286
|
-
</div>
|
1287
|
-
</div>
|
1288
|
-
</div>
|
1289
|
-
<div class="method">
|
1290
|
-
<div class="title">
|
1291
|
-
<a name="M000458"></a><b>pp_exception</b>(ex)
|
1292
|
-
</div>
|
1293
|
-
<div class="description">
|
1294
|
-
<p>
|
1295
|
-
Pretty prints an exception/error object usefull for helpfull debug messages
|
1296
|
-
</p>
|
1297
|
-
<p>
|
1298
|
-
Input: The Exception/StandardError object
|
1299
|
-
</p>
|
1300
|
-
<p>
|
1301
|
-
Output: the pretty printed string
|
1302
|
-
</p>
|
1303
|
-
</div>
|
1304
|
-
<div class="sourcecode">
|
1305
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000458_source')" id="l_M000458_source">show source</a> ]</p>
|
1306
|
-
<div id="M000458_source" class="dyn-source">
|
1307
|
-
<pre>
|
1308
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/pp_exception.rb, line 13</span>
|
1309
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">pp_exception</span>(<span class="ruby-identifier">ex</span>)
|
1310
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-node">%{#{ex.message}\n #{ex.backtrace.join("\n ")}\n LOGGED FROM: #{caller[0]}}</span>
|
1311
|
-
<span class="ruby-keyword kw">end</span>
|
1312
|
-
</pre>
|
1313
|
-
</div>
|
1314
|
-
</div>
|
1315
|
-
</div>
|
1316
|
-
<div class="method">
|
1317
|
-
<div class="title">
|
1318
|
-
<a name="M000459"></a><b>quaclass</b>( &block )
|
1319
|
-
</div>
|
1320
|
-
<div class="description">
|
1321
|
-
<p>
|
1322
|
-
Easy access to an object qua class, otherwise known as the object’s
|
1323
|
-
metaclass or singleton class.
|
1324
|
-
</p>
|
1325
|
-
<pre>
|
1326
|
-
It is what it is.
|
1327
|
-
|
1328
|
-
-- transonoma
|
1329
|
-
</pre>
|
1330
|
-
</div>
|
1331
|
-
<div class="aka">
|
1332
|
-
This method is also aliased as
|
1333
|
-
<a href="Kernel.html#M000460">__quaclass__</a>
|
1334
|
-
</div>
|
1335
|
-
<div class="sourcecode">
|
1336
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000459_source')" id="l_M000459_source">show source</a> ]</p>
|
1337
|
-
<div id="M000459_source" class="dyn-source">
|
1338
|
-
<pre>
|
1339
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/quaclass.rb, line 11</span>
|
1340
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">quaclass</span>( <span class="ruby-operator">&</span><span class="ruby-identifier">block</span> )
|
1341
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>).<span class="ruby-identifier">module_eval</span>(<span class="ruby-operator">&</span><span class="ruby-identifier">block</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block</span>
|
1342
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)
|
1343
|
-
<span class="ruby-keyword kw">end</span>
|
1344
|
-
</pre>
|
1345
|
-
</div>
|
1346
|
-
</div>
|
1347
|
-
</div>
|
1348
|
-
<div class="method">
|
1349
|
-
<div class="title">
|
1350
|
-
<a name="M000408"></a><b>resc</b>(x)
|
1351
|
-
</div>
|
1352
|
-
<div class="description">
|
1353
|
-
<p>
|
1354
|
-
Provides a shortcut to the Regexp.escape module method.
|
1355
|
-
</p>
|
1356
|
-
</div>
|
1357
|
-
<div class="sourcecode">
|
1358
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000408_source')" id="l_M000408_source">show source</a> ]</p>
|
1359
|
-
<div id="M000408_source" class="dyn-source">
|
1360
|
-
<pre>
|
1361
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/resc.rb, line 5</span>
|
1362
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">resc</span>(<span class="ruby-identifier">x</span>)
|
1363
|
-
<span class="ruby-constant">Regexp</span>.<span class="ruby-identifier">escape</span>(<span class="ruby-identifier">x</span>)
|
1364
|
-
<span class="ruby-keyword kw">end</span>
|
1365
|
-
</pre>
|
1366
|
-
</div>
|
1367
|
-
</div>
|
1368
|
-
</div>
|
1369
|
-
<div class="method">
|
1370
|
-
<div class="title">
|
1371
|
-
<a name="M000463"></a><b>respond</b>(sym, *args)
|
1372
|
-
</div>
|
1373
|
-
<div class="description">
|
1374
|
-
<p>
|
1375
|
-
Like respond_to? but returns the result of the call if it does respond.
|
1376
|
-
</p>
|
1377
|
-
<p>
|
1378
|
-
(This is used to be called respond_with_value.)
|
1379
|
-
</p>
|
1380
|
-
</div>
|
1381
|
-
<div class="sourcecode">
|
1382
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000463_source')" id="l_M000463_source">show source</a> ]</p>
|
1383
|
-
<div id="M000463_source" class="dyn-source">
|
1384
|
-
<pre>
|
1385
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/respond.rb, line 9</span>
|
1386
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">respond</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
1387
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">nil</span> <span class="ruby-keyword kw">if</span> <span class="ruby-keyword kw">not</span> <span class="ruby-identifier">respond_to?</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
1388
|
-
<span class="ruby-identifier">send</span>(<span class="ruby-identifier">sym</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
1389
|
-
<span class="ruby-keyword kw">end</span>
|
1390
|
-
</pre>
|
1391
|
-
</div>
|
1392
|
-
</div>
|
1393
|
-
</div>
|
1394
|
-
<div class="method">
|
1395
|
-
<div class="title">
|
1396
|
-
<a name="M000438"></a><b>returning</b>(value) {|| ...}
|
1397
|
-
</div>
|
1398
|
-
<div class="description">
|
1399
|
-
<p>
|
1400
|
-
A Ruby-ized realization of the K combinator.
|
1401
|
-
</p>
|
1402
|
-
<pre>
|
1403
|
-
def foo
|
1404
|
-
returning values = [] do
|
1405
|
-
values << 'bar'
|
1406
|
-
values << 'baz'
|
1407
|
-
end
|
1408
|
-
end
|
1409
|
-
|
1410
|
-
foo # => ['bar', 'baz']
|
1411
|
-
</pre>
|
1412
|
-
</div>
|
1413
|
-
<div class="sourcecode">
|
1414
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000438_source')" id="l_M000438_source">show source</a> ]</p>
|
1415
|
-
<div id="M000438_source" class="dyn-source">
|
1416
|
-
<pre>
|
1417
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/returning.rb, line 18</span>
|
1418
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">returning</span>(<span class="ruby-identifier">value</span>)
|
1419
|
-
<span class="ruby-keyword kw">yield</span>
|
1420
|
-
<span class="ruby-identifier">value</span>
|
1421
|
-
<span class="ruby-keyword kw">end</span>
|
1422
|
-
</pre>
|
1423
|
-
</div>
|
1424
|
-
</div>
|
1425
|
-
</div>
|
1426
|
-
<div class="method">
|
1427
|
-
<div class="title">
|
1428
|
-
<a name="M000426"></a><b>send_as</b>(klass, meth, *args, &blk)
|
1429
|
-
</div>
|
1430
|
-
<div class="description">
|
1431
|
-
<p>
|
1432
|
-
Call parent class/module methods once bound to self.
|
1433
|
-
</p>
|
1434
|
-
</div>
|
1435
|
-
<div class="sourcecode">
|
1436
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000426_source')" id="l_M000426_source">show source</a> ]</p>
|
1437
|
-
<div id="M000426_source" class="dyn-source">
|
1438
|
-
<pre>
|
1439
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/send_as.rb, line 6</span>
|
1440
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">send_as</span>(<span class="ruby-identifier">klass</span>, <span class="ruby-identifier">meth</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&</span><span class="ruby-identifier">blk</span>)
|
1441
|
-
<span class="ruby-identifier">selfclass</span> = <span class="ruby-constant">Kernel</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">:class</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>).<span class="ruby-identifier">call</span>
|
1442
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span> <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span> <span class="ruby-identifier">selfclass</span>.<span class="ruby-identifier">ancestors</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">klass</span>)
|
1443
|
-
<span class="ruby-identifier">klass</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">meth</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>).<span class="ruby-identifier">call</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>, <span class="ruby-operator">&</span><span class="ruby-identifier">blk</span>)
|
1444
|
-
<span class="ruby-keyword kw">end</span>
|
1445
|
-
</pre>
|
1446
|
-
</div>
|
1447
|
-
</div>
|
1448
|
-
</div>
|
1449
|
-
<div class="method">
|
1450
|
-
<div class="title">
|
1451
|
-
<a name="M000446"></a><b>set_from</b>(obj, *fields)
|
1452
|
-
</div>
|
1453
|
-
<div class="description">
|
1454
|
-
<p>
|
1455
|
-
Set setter methods using a another object.
|
1456
|
-
</p>
|
1457
|
-
<pre>
|
1458
|
-
class X
|
1459
|
-
attr_accessor :a, :b
|
1460
|
-
def initialize( a, b )
|
1461
|
-
@a,@b = a,b
|
1462
|
-
end
|
1463
|
-
end
|
1464
|
-
|
1465
|
-
obj1 = X.new( 1, 2 )
|
1466
|
-
obj2 = X.new
|
1467
|
-
|
1468
|
-
obj2.set_from(obj1)
|
1469
|
-
|
1470
|
-
obj2.a #=> 1
|
1471
|
-
obj2.b #=> 2
|
1472
|
-
</pre>
|
1473
|
-
</div>
|
1474
|
-
<div class="sourcecode">
|
1475
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000446_source')" id="l_M000446_source">show source</a> ]</p>
|
1476
|
-
<div id="M000446_source" class="dyn-source">
|
1477
|
-
<pre>
|
1478
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/set_from.rb, line 22</span>
|
1479
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set_from</span>(<span class="ruby-identifier">obj</span>, <span class="ruby-operator">*</span><span class="ruby-identifier">fields</span>)
|
1480
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">fields</span>.<span class="ruby-identifier">empty?</span>
|
1481
|
-
<span class="ruby-identifier">fields</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span><span class="ruby-operator">|</span>
|
1482
|
-
<span class="ruby-identifier">send</span>( <span class="ruby-node">"#{k}="</span>, <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">send</span>(<span class="ruby-node">"#{k}"</span>) ) <span class="ruby-comment cmt">#if self.respond_to?("#{k}=") && obj.respond_to?("#{k}")</span>
|
1483
|
-
<span class="ruby-keyword kw">end</span>
|
1484
|
-
<span class="ruby-keyword kw">else</span>
|
1485
|
-
<span class="ruby-identifier">setters</span> = <span class="ruby-identifier">methods</span>.<span class="ruby-identifier">collect</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">m</span><span class="ruby-operator">|</span> <span class="ruby-identifier">m</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/=$/</span> }
|
1486
|
-
<span class="ruby-identifier">setters</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">setter</span><span class="ruby-operator">|</span>
|
1487
|
-
<span class="ruby-identifier">getter</span> = <span class="ruby-identifier">setter</span>.<span class="ruby-identifier">chomp</span>(<span class="ruby-value str">'='</span>)
|
1488
|
-
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">respond_to?</span>(<span class="ruby-identifier">getter</span>)
|
1489
|
-
<span class="ruby-identifier">send</span>( <span class="ruby-identifier">setter</span>, <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">getter</span>) )
|
1490
|
-
<span class="ruby-identifier">fields</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">getter</span>
|
1491
|
-
<span class="ruby-keyword kw">end</span>
|
1492
|
-
<span class="ruby-keyword kw">end</span>
|
1493
|
-
<span class="ruby-keyword kw">end</span>
|
1494
|
-
<span class="ruby-identifier">fields</span>
|
1495
|
-
<span class="ruby-keyword kw">end</span>
|
1496
|
-
</pre>
|
1497
|
-
</div>
|
1498
|
-
</div>
|
1499
|
-
</div>
|
1500
|
-
<div class="method">
|
1501
|
-
<div class="title">
|
1502
|
-
<a name="M000410"></a><b>set_with</b>(*args)
|
1503
|
-
</div>
|
1504
|
-
<div class="description">
|
1505
|
-
<p>
|
1506
|
-
Assign via setter methods using a hash (or assoc array).
|
1507
|
-
</p>
|
1508
|
-
<pre>
|
1509
|
-
object.set_with( :a => 1, :b => 2 )
|
1510
|
-
object.set_with( :a, 1, :b, 2 )
|
1511
|
-
object.set_with( [:a, 1], [:b, 2] )
|
1512
|
-
object.set_with( *[[:a, 1], [:b, 2]] )
|
1513
|
-
</pre>
|
1514
|
-
<p>
|
1515
|
-
These are all the same as doing:
|
1516
|
-
</p>
|
1517
|
-
<pre>
|
1518
|
-
object.a = 1
|
1519
|
-
object.b = 2
|
1520
|
-
</pre>
|
1521
|
-
<p>
|
1522
|
-
The array forms gaurentees order of operation.
|
1523
|
-
</p>
|
1524
|
-
</div>
|
1525
|
-
<div class="sourcecode">
|
1526
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000410_source')" id="l_M000410_source">show source</a> ]</p>
|
1527
|
-
<div id="M000410_source" class="dyn-source">
|
1528
|
-
<pre>
|
1529
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/set_with.rb, line 19</span>
|
1530
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set_with</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
1531
|
-
<span class="ruby-identifier">harg</span> = <span class="ruby-identifier">args</span>.<span class="ruby-identifier">last</span>.<span class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Hash</span>) <span class="ruby-operator">?</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">pop</span> <span class="ruby-operator">:</span> {}
|
1532
|
-
|
1533
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">empty?</span>
|
1534
|
-
<span class="ruby-comment cmt"># if not assoc array, eg. [ [], [], ... ]</span>
|
1535
|
-
<span class="ruby-comment cmt"># preserves order of opertation</span>
|
1536
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">args</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Array</span>)
|
1537
|
-
<span class="ruby-identifier">i</span> = <span class="ruby-value">0</span>; <span class="ruby-identifier">a</span> = []
|
1538
|
-
<span class="ruby-keyword kw">while</span> <span class="ruby-identifier">i</span> <span class="ruby-operator"><</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">size</span>
|
1539
|
-
<span class="ruby-identifier">a</span> <span class="ruby-operator"><<</span> [ <span class="ruby-identifier">args</span>[<span class="ruby-identifier">i</span>], <span class="ruby-identifier">args</span>[<span class="ruby-identifier">i</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>] ]
|
1540
|
-
<span class="ruby-identifier">i</span> <span class="ruby-operator">+=</span> <span class="ruby-value">2</span>
|
1541
|
-
<span class="ruby-keyword kw">end</span>
|
1542
|
-
<span class="ruby-identifier">args</span> = <span class="ruby-identifier">a</span>
|
1543
|
-
<span class="ruby-keyword kw">end</span>
|
1544
|
-
<span class="ruby-keyword kw">end</span>
|
1545
|
-
|
1546
|
-
<span class="ruby-identifier">args</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>,<span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
1547
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">send</span>( <span class="ruby-node">"#{k}="</span>, <span class="ruby-identifier">v</span> ) <span class="ruby-comment cmt">#if respond_to?("#{k}=")</span>
|
1548
|
-
<span class="ruby-keyword kw">end</span>
|
1549
|
-
|
1550
|
-
<span class="ruby-identifier">harg</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">k</span>,<span class="ruby-identifier">v</span><span class="ruby-operator">|</span>
|
1551
|
-
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">send</span>( <span class="ruby-node">"#{k}="</span>, <span class="ruby-identifier">v</span> ) <span class="ruby-comment cmt">#if respond_to?("#{k}=")</span>
|
1552
|
-
<span class="ruby-keyword kw">end</span>
|
1553
|
-
|
1554
|
-
<span class="ruby-keyword kw">end</span>
|
1555
|
-
</pre>
|
1556
|
-
</div>
|
1557
|
-
</div>
|
1558
|
-
</div>
|
1559
|
-
<div class="method">
|
1560
|
-
<div class="title">
|
1561
|
-
<a name="M000457"></a><b>silence_warnings</b>(
|
1562
|
-
</div>
|
1563
|
-
<div class="description">
|
1564
|
-
<p>
|
1565
|
-
Alias for <a href="Kernel.html#M000456">silently</a>
|
1566
|
-
</p>
|
1567
|
-
</div>
|
1568
|
-
</div>
|
1569
|
-
<div class="method">
|
1570
|
-
<div class="title">
|
1571
|
-
<a name="M000456"></a><b>silently</b>( {|| ...}
|
1572
|
-
</div>
|
1573
|
-
<div class="description">
|
1574
|
-
<p>
|
1575
|
-
Temporarily turn-off verbose mode while yielding block.
|
1576
|
-
</p>
|
1577
|
-
</div>
|
1578
|
-
<div class="aka">
|
1579
|
-
This method is also aliased as
|
1580
|
-
<a href="Kernel.html#M000457">silence_warnings</a>
|
1581
|
-
</div>
|
1582
|
-
<div class="sourcecode">
|
1583
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000456_source')" id="l_M000456_source">show source</a> ]</p>
|
1584
|
-
<div id="M000456_source" class="dyn-source">
|
1585
|
-
<pre>
|
1586
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/silently.rb, line 6</span>
|
1587
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">silently</span> <span class="ruby-comment cmt">#:yield:</span>
|
1588
|
-
<span class="ruby-identifier">old_verbose</span>, <span class="ruby-identifier">$VERBOSE</span> = <span class="ruby-identifier">$VERBOSE</span>, <span class="ruby-keyword kw">nil</span>
|
1589
|
-
<span class="ruby-keyword kw">begin</span>
|
1590
|
-
<span class="ruby-keyword kw">yield</span>
|
1591
|
-
<span class="ruby-keyword kw">ensure</span>
|
1592
|
-
<span class="ruby-identifier">$VERBOSE</span> = <span class="ruby-identifier">old_verbose</span>
|
1593
|
-
<span class="ruby-keyword kw">end</span>
|
1594
|
-
<span class="ruby-keyword kw">end</span>
|
1595
|
-
</pre>
|
1596
|
-
</div>
|
1597
|
-
</div>
|
1598
|
-
</div>
|
1599
|
-
<div class="method">
|
1600
|
-
<div class="title">
|
1601
|
-
<a name="M000416"></a><b>singleton</b>()
|
1602
|
-
</div>
|
1603
|
-
<div class="description">
|
1604
|
-
<p>
|
1605
|
-
Access to an object’s "special" class, otherwise known as
|
1606
|
-
it’s eigenclass or metaclass or own, etc.
|
1607
|
-
</p>
|
1608
|
-
<p>
|
1609
|
-
One day these names must be reconciled!
|
1610
|
-
</p>
|
1611
|
-
</div>
|
1612
|
-
<div class="aka">
|
1613
|
-
This method is also aliased as
|
1614
|
-
<a href="Kernel.html#M000417">__singleton__</a>
|
1615
|
-
</div>
|
1616
|
-
<div class="sourcecode">
|
1617
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000416_source')" id="l_M000416_source">show source</a> ]</p>
|
1618
|
-
<div id="M000416_source" class="dyn-source">
|
1619
|
-
<pre>
|
1620
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/singleton.rb, line 9</span>
|
1621
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">singleton</span>
|
1622
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)
|
1623
|
-
<span class="ruby-keyword kw">end</span>
|
1624
|
-
</pre>
|
1625
|
-
</div>
|
1626
|
-
</div>
|
1627
|
-
</div>
|
1628
|
-
<div class="method">
|
1629
|
-
<div class="title">
|
1630
|
-
<a name="M000464"></a><b>singleton_class</b>()
|
1631
|
-
</div>
|
1632
|
-
<div class="description">
|
1633
|
-
<p>
|
1634
|
-
Access to an object’s "special" class, otherwise known as
|
1635
|
-
it’s eigenclass or metaclass or own, etc.
|
1636
|
-
</p>
|
1637
|
-
<p>
|
1638
|
-
One day these names must be reconciled!
|
1639
|
-
</p>
|
1640
|
-
</div>
|
1641
|
-
<div class="aka">
|
1642
|
-
This method is also aliased as
|
1643
|
-
<a href="Kernel.html#M000465">__singleton_class__</a>
|
1644
|
-
</div>
|
1645
|
-
<div class="sourcecode">
|
1646
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000464_source')" id="l_M000464_source">show source</a> ]</p>
|
1647
|
-
<div id="M000464_source" class="dyn-source">
|
1648
|
-
<pre>
|
1649
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/singleton_class.rb, line 9</span>
|
1650
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">singleton_class</span>
|
1651
|
-
(<span class="ruby-keyword kw">class</span> <span class="ruby-operator"><<</span> <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">self</span>; <span class="ruby-keyword kw">end</span>)
|
1652
|
-
<span class="ruby-keyword kw">end</span>
|
1653
|
-
</pre>
|
1654
|
-
</div>
|
1655
|
-
</div>
|
1656
|
-
</div>
|
1657
|
-
<div class="method">
|
1658
|
-
<div class="title">
|
1659
|
-
<a name="M000432"></a><b>super_method</b>(klass, meth)
|
1660
|
-
</div>
|
1661
|
-
<div class="description">
|
1662
|
-
<p>
|
1663
|
-
Alias for <a href="Kernel.html#M000431">supermethod</a>
|
1664
|
-
</p>
|
1665
|
-
</div>
|
1666
|
-
</div>
|
1667
|
-
<div class="method">
|
1668
|
-
<div class="title">
|
1669
|
-
<a name="M000431"></a><b>supermethod</b>(klass, meth)
|
1670
|
-
</div>
|
1671
|
-
<div class="description">
|
1672
|
-
<p>
|
1673
|
-
Returns method of a parent class bound to self.
|
1674
|
-
</p>
|
1675
|
-
</div>
|
1676
|
-
<div class="aka">
|
1677
|
-
This method is also aliased as
|
1678
|
-
<a href="Kernel.html#M000432">super_method</a>
|
1679
|
-
</div>
|
1680
|
-
<div class="sourcecode">
|
1681
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000431_source')" id="l_M000431_source">show source</a> ]</p>
|
1682
|
-
<div id="M000431_source" class="dyn-source">
|
1683
|
-
<pre>
|
1684
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/supermethod.rb, line 6</span>
|
1685
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">supermethod</span>(<span class="ruby-identifier">klass</span>, <span class="ruby-identifier">meth</span>)
|
1686
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">ancestors</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">klass</span>)
|
1687
|
-
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>
|
1688
|
-
<span class="ruby-keyword kw">end</span>
|
1689
|
-
<span class="ruby-identifier">klass</span>.<span class="ruby-identifier">instance_method</span>(<span class="ruby-identifier">meth</span>).<span class="ruby-identifier">bind</span>(<span class="ruby-keyword kw">self</span>)
|
1690
|
-
<span class="ruby-keyword kw">end</span>
|
1691
|
-
</pre>
|
1692
|
-
</div>
|
1693
|
-
</div>
|
1694
|
-
</div>
|
1695
|
-
<div class="method">
|
1696
|
-
<div class="title">
|
1697
|
-
<a name="M000452"></a><b>true?</b>()
|
1698
|
-
</div>
|
1699
|
-
<div class="description">
|
1700
|
-
<p>
|
1701
|
-
Returns true is an object is class <a href="TrueClass.html">TrueClass</a>,
|
1702
|
-
otherwise false.
|
1703
|
-
</p>
|
1704
|
-
<pre>
|
1705
|
-
true.true? #=> true
|
1706
|
-
false.true? #=> false
|
1707
|
-
nil.true? #=> false
|
1708
|
-
</pre>
|
1709
|
-
</div>
|
1710
|
-
<div class="sourcecode">
|
1711
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000452_source')" id="l_M000452_source">show source</a> ]</p>
|
1712
|
-
<div id="M000452_source" class="dyn-source">
|
1713
|
-
<pre>
|
1714
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/bool.rb, line 14</span>
|
1715
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">true?</span>
|
1716
|
-
(<span class="ruby-keyword kw">true</span> <span class="ruby-operator">==</span> <span class="ruby-keyword kw">self</span>)
|
1717
|
-
<span class="ruby-keyword kw">end</span>
|
1718
|
-
</pre>
|
1719
|
-
</div>
|
1720
|
-
</div>
|
1721
|
-
</div>
|
1722
|
-
<div class="method">
|
1723
|
-
<div class="title">
|
1724
|
-
<a name="M000445"></a><b>unuri</b>( s )
|
1725
|
-
</div>
|
1726
|
-
<div class="sourcecode">
|
1727
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000445_source')" id="l_M000445_source">show source</a> ]</p>
|
1728
|
-
<div id="M000445_source" class="dyn-source">
|
1729
|
-
<pre>
|
1730
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/uri.rb, line 9</span>
|
1731
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">unuri</span>( <span class="ruby-identifier">s</span> )
|
1732
|
-
<span class="ruby-constant">URI</span>.<span class="ruby-identifier">unescape</span>( <span class="ruby-identifier">s</span> )
|
1733
|
-
<span class="ruby-keyword kw">end</span>
|
1734
|
-
</pre>
|
1735
|
-
</div>
|
1736
|
-
</div>
|
1737
|
-
</div>
|
1738
|
-
<div class="method">
|
1739
|
-
<div class="title">
|
1740
|
-
<a name="M000444"></a><b>uri</b>( s, w=%r{[^a-zA-Z_0-9./-]} )
|
1741
|
-
</div>
|
1742
|
-
<div class="sourcecode">
|
1743
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000444_source')" id="l_M000444_source">show source</a> ]</p>
|
1744
|
-
<div id="M000444_source" class="dyn-source">
|
1745
|
-
<pre>
|
1746
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/uri.rb, line 5</span>
|
1747
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">uri</span>( <span class="ruby-identifier">s</span>, <span class="ruby-identifier">w</span>=<span class="ruby-regexp re">%r{[^a-zA-Z_0-9./-]}</span> )
|
1748
|
-
<span class="ruby-constant">URI</span>.<span class="ruby-identifier">escape</span>( <span class="ruby-identifier">s</span>, <span class="ruby-identifier">w</span> )
|
1749
|
-
<span class="ruby-keyword kw">end</span>
|
1750
|
-
</pre>
|
1751
|
-
</div>
|
1752
|
-
</div>
|
1753
|
-
</div>
|
1754
|
-
<div class="method">
|
1755
|
-
<div class="title">
|
1756
|
-
<a name="M000448"></a><b>warn_with_line</b>(msg="", fulltrace=nil)
|
1757
|
-
</div>
|
1758
|
-
<div class="description">
|
1759
|
-
<p>
|
1760
|
-
Like warn produces the current line number as well.
|
1761
|
-
</p>
|
1762
|
-
<pre>
|
1763
|
-
warn_with_line("You have been warned.")
|
1764
|
-
</pre>
|
1765
|
-
<p>
|
1766
|
-
<em>produces</em>
|
1767
|
-
</p>
|
1768
|
-
<pre>
|
1769
|
-
3: Warning: You have been warned.
|
1770
|
-
</pre>
|
1771
|
-
<p>
|
1772
|
-
Note that this method depends on the output of caller.
|
1773
|
-
</p>
|
1774
|
-
</div>
|
1775
|
-
<div class="sourcecode">
|
1776
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000448_source')" id="l_M000448_source">show source</a> ]</p>
|
1777
|
-
<div id="M000448_source" class="dyn-source">
|
1778
|
-
<pre>
|
1779
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/warn_with_line.rb, line 13</span>
|
1780
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">warn_with_line</span>(<span class="ruby-identifier">msg</span>=<span class="ruby-value str">""</span>, <span class="ruby-identifier">fulltrace</span>=<span class="ruby-keyword kw">nil</span>)
|
1781
|
-
<span class="ruby-identifier">trace</span> = <span class="ruby-identifier">caller</span>(<span class="ruby-value">1</span>)
|
1782
|
-
<span class="ruby-identifier">where</span> = <span class="ruby-identifier">trace</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">sub</span>(<span class="ruby-regexp re">/:in.*/</span>,<span class="ruby-value str">''</span>)
|
1783
|
-
<span class="ruby-constant">STDERR</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"#{where}: Warning: #{msg}"</span>
|
1784
|
-
<span class="ruby-constant">STDERR</span>.<span class="ruby-identifier">puts</span> <span class="ruby-identifier">trace</span>.<span class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">t</span><span class="ruby-operator">|</span> <span class="ruby-node">"\tfrom #{t}"</span> } <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">fulltrace</span>
|
1785
|
-
<span class="ruby-keyword kw">end</span>
|
1786
|
-
</pre>
|
1787
|
-
</div>
|
1788
|
-
</div>
|
1789
|
-
</div>
|
1790
|
-
<div class="sectiontitle">Private Instance methods</div>
|
1791
|
-
<div class="method">
|
1792
|
-
<div class="title">
|
1793
|
-
<a name="M000462"></a><b>__callee__</b>()
|
1794
|
-
</div>
|
1795
|
-
<div class="description">
|
1796
|
-
<p>
|
1797
|
-
Alias for #<em>method</em>
|
1798
|
-
</p>
|
1799
|
-
</div>
|
1800
|
-
</div>
|
1801
|
-
<div class="method">
|
1802
|
-
<div class="title">
|
1803
|
-
<a name="M000461"></a><b>__method__</b>()
|
1804
|
-
</div>
|
1805
|
-
<div class="description">
|
1806
|
-
<p>
|
1807
|
-
Retreive the current running method name.
|
1808
|
-
</p>
|
1809
|
-
<p>
|
1810
|
-
There is a lot of debate on what to call this. me returns a symbol, not a
|
1811
|
-
string.
|
1812
|
-
</p>
|
1813
|
-
<pre>
|
1814
|
-
def tester; __method__; end
|
1815
|
-
tester #=> :tester
|
1816
|
-
</pre>
|
1817
|
-
</div>
|
1818
|
-
<div class="aka">
|
1819
|
-
This method is also aliased as
|
1820
|
-
<a href="Kernel.html#M000462">__callee__</a>
|
1821
|
-
</div>
|
1822
|
-
<div class="sourcecode">
|
1823
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000461_source')" id="l_M000461_source">show source</a> ]</p>
|
1824
|
-
<div id="M000461_source" class="dyn-source">
|
1825
|
-
<pre>
|
1826
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/__method__.rb, line 14</span>
|
1827
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">__method__</span>
|
1828
|
-
<span class="ruby-regexp re">/\`([^\']+)\'/</span>.<span class="ruby-identifier">match</span>(<span class="ruby-identifier">caller</span>(<span class="ruby-value">1</span>).<span class="ruby-identifier">first</span>)[<span class="ruby-value">1</span>].<span class="ruby-identifier">to_sym</span>
|
1829
|
-
<span class="ruby-keyword kw">end</span>
|
1830
|
-
</pre>
|
1831
|
-
</div>
|
1832
|
-
</div>
|
1833
|
-
</div>
|
1834
|
-
<div class="method">
|
1835
|
-
<div class="title">
|
1836
|
-
<a name="M000442"></a><b>called</b>()
|
1837
|
-
</div>
|
1838
|
-
<div class="description">
|
1839
|
-
<p>
|
1840
|
-
Retreive the current running method name. There is a lot of debate on what
|
1841
|
-
to call this. <a href="Kernel.html#M000442">called</a> differs from
|
1842
|
-
method_name only by the fact that it returns a symbol, rather then a
|
1843
|
-
string.
|
1844
|
-
</p>
|
1845
|
-
<pre>
|
1846
|
-
def tester; called; end
|
1847
|
-
tester #=> :tester
|
1848
|
-
</pre>
|
1849
|
-
</div>
|
1850
|
-
<div class="sourcecode">
|
1851
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000442_source')" id="l_M000442_source">show source</a> ]</p>
|
1852
|
-
<div id="M000442_source" class="dyn-source">
|
1853
|
-
<pre>
|
1854
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/called.rb, line 14</span>
|
1855
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">called</span>
|
1856
|
-
<span class="ruby-regexp re">/\`([^\']+)\'/</span>.<span class="ruby-identifier">match</span>(<span class="ruby-identifier">caller</span>(<span class="ruby-value">1</span>).<span class="ruby-identifier">first</span>)[<span class="ruby-value">1</span>].<span class="ruby-identifier">to_sym</span>
|
1857
|
-
<span class="ruby-keyword kw">end</span>
|
1858
|
-
</pre>
|
1859
|
-
</div>
|
1860
|
-
</div>
|
1861
|
-
</div>
|
1862
|
-
<div class="method">
|
1863
|
-
<div class="title">
|
1864
|
-
<a name="M000411"></a><b>require_all</b>( pat )
|
1865
|
-
</div>
|
1866
|
-
<div class="description">
|
1867
|
-
<p>
|
1868
|
-
Require a pattern of files. This make is easy to require an entire
|
1869
|
-
directory, for instance.
|
1870
|
-
</p>
|
1871
|
-
<pre>
|
1872
|
-
require_all 'facet/time/*'
|
1873
|
-
</pre>
|
1874
|
-
</div>
|
1875
|
-
<div class="sourcecode">
|
1876
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000411_source')" id="l_M000411_source">show source</a> ]</p>
|
1877
|
-
<div id="M000411_source" class="dyn-source">
|
1878
|
-
<pre>
|
1879
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/require_all.rb, line 11</span>
|
1880
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">require_all</span>( <span class="ruby-identifier">pat</span> )
|
1881
|
-
<span class="ruby-identifier">$LOAD_PATH</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">path</span><span class="ruby-operator">|</span>
|
1882
|
-
<span class="ruby-identifier">fs</span> = <span class="ruby-constant">Dir</span>[<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">path</span>,<span class="ruby-identifier">pat</span>)]
|
1883
|
-
<span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">fs</span>.<span class="ruby-identifier">empty?</span>
|
1884
|
-
<span class="ruby-identifier">fs</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
|
1885
|
-
<span class="ruby-constant">Kernel</span>.<span class="ruby-identifier">require</span>( <span class="ruby-identifier">f</span> ) <span class="ruby-keyword kw">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">directory?</span>( <span class="ruby-identifier">f</span> )
|
1886
|
-
}
|
1887
|
-
<span class="ruby-keyword kw">break</span>;
|
1888
|
-
<span class="ruby-keyword kw">end</span>
|
1889
|
-
<span class="ruby-keyword kw">end</span>
|
1890
|
-
<span class="ruby-keyword kw">end</span>
|
1891
|
-
</pre>
|
1892
|
-
</div>
|
1893
|
-
</div>
|
1894
|
-
</div>
|
1895
|
-
<div class="method">
|
1896
|
-
<div class="title">
|
1897
|
-
<a name="M000415"></a><b>require_esc</b>( fpath )
|
1898
|
-
</div>
|
1899
|
-
<div class="description">
|
1900
|
-
<p>
|
1901
|
-
Require a file with puncuation marks escaped using NANOESC table.
|
1902
|
-
</p>
|
1903
|
-
<pre>
|
1904
|
-
require_esc '[].rb'
|
1905
|
-
</pre>
|
1906
|
-
<p>
|
1907
|
-
in actuality requires the file ‘op_fetch.rb’.
|
1908
|
-
</p>
|
1909
|
-
</div>
|
1910
|
-
<div class="sourcecode">
|
1911
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000415_source')" id="l_M000415_source">show source</a> ]</p>
|
1912
|
-
<div id="M000415_source" class="dyn-source">
|
1913
|
-
<pre>
|
1914
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/require_esc.rb, line 13</span>
|
1915
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">require_esc</span>( <span class="ruby-identifier">fpath</span> )
|
1916
|
-
<span class="ruby-identifier">fdir</span>, <span class="ruby-identifier">fname</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">split</span>(<span class="ruby-identifier">fpath</span>)
|
1917
|
-
<span class="ruby-identifier">ename</span> = <span class="ruby-identifier">op_esc</span>( <span class="ruby-identifier">fname</span> )
|
1918
|
-
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">ename</span>[<span class="ruby-value">-1</span>,<span class="ruby-value">1</span>] ; <span class="ruby-keyword kw">when</span> <span class="ruby-value str">'!'</span>,<span class="ruby-value str">'='</span>,<span class="ruby-value str">'?'</span> <span class="ruby-keyword kw">then</span> <span class="ruby-identifier">ename</span> = <span class="ruby-identifier">ename</span>[<span class="ruby-value">0</span><span class="ruby-operator">...</span><span class="ruby-value">-1</span>] ; <span class="ruby-keyword kw">end</span>
|
1919
|
-
<span class="ruby-identifier">epath</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>( <span class="ruby-identifier">fdir</span>, <span class="ruby-identifier">ename</span> )
|
1920
|
-
<span class="ruby-identifier">require</span>( <span class="ruby-identifier">epath</span> )
|
1921
|
-
<span class="ruby-keyword kw">end</span>
|
1922
|
-
</pre>
|
1923
|
-
</div>
|
1924
|
-
</div>
|
1925
|
-
</div>
|
1926
|
-
<div class="method">
|
1927
|
-
<div class="title">
|
1928
|
-
<a name="M000455"></a><b>require_facet</b>( fpath )
|
1929
|
-
</div>
|
1930
|
-
<div class="description">
|
1931
|
-
<p>
|
1932
|
-
Just like <a href="Kernel.html#M000415">require_esc</a> excapt that it
|
1933
|
-
provides the initial ‘facet/’ path.
|
1934
|
-
</p>
|
1935
|
-
<pre>
|
1936
|
-
require_facet 'string/capitalized?'
|
1937
|
-
</pre>
|
1938
|
-
<p>
|
1939
|
-
_is the same as_
|
1940
|
-
</p>
|
1941
|
-
<pre>
|
1942
|
-
require_esc 'facet/string/capitalized?'
|
1943
|
-
</pre>
|
1944
|
-
</div>
|
1945
|
-
<div class="sourcecode">
|
1946
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000455_source')" id="l_M000455_source">show source</a> ]</p>
|
1947
|
-
<div id="M000455_source" class="dyn-source">
|
1948
|
-
<pre>
|
1949
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/require_facet.rb, line 16</span>
|
1950
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">require_facet</span>( <span class="ruby-identifier">fpath</span> )
|
1951
|
-
<span class="ruby-identifier">require_esc</span>( <span class="ruby-node">"facet/#{fpath}"</span> )
|
1952
|
-
<span class="ruby-keyword kw">end</span>
|
1953
|
-
</pre>
|
1954
|
-
</div>
|
1955
|
-
</div>
|
1956
|
-
</div>
|
1957
|
-
<div class="method">
|
1958
|
-
<div class="title">
|
1959
|
-
<a name="M000435"></a><b>require_local</b>( fname )
|
1960
|
-
</div>
|
1961
|
-
<div class="description">
|
1962
|
-
<p>
|
1963
|
-
Require file from same dir as calling script.
|
1964
|
-
</p>
|
1965
|
-
<pre>
|
1966
|
-
require_local 'templib'
|
1967
|
-
</pre>
|
1968
|
-
</div>
|
1969
|
-
<div class="sourcecode">
|
1970
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000435_source')" id="l_M000435_source">show source</a> ]</p>
|
1971
|
-
<div id="M000435_source" class="dyn-source">
|
1972
|
-
<pre>
|
1973
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/require_local.rb, line 10</span>
|
1974
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">require_local</span>( <span class="ruby-identifier">fname</span> )
|
1975
|
-
<span class="ruby-comment cmt">#fdir = File.expand_path( File.dirname( caller[0] ) )</span>
|
1976
|
-
<span class="ruby-identifier">fdir</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">dirname</span>( <span class="ruby-identifier">caller</span>[<span class="ruby-value">0</span>] )
|
1977
|
-
<span class="ruby-identifier">require</span>( <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>( <span class="ruby-identifier">fdir</span>, <span class="ruby-identifier">fname</span> ) )
|
1978
|
-
<span class="ruby-keyword kw">end</span>
|
1979
|
-
</pre>
|
1980
|
-
</div>
|
1981
|
-
</div>
|
1982
|
-
</div>
|
1983
|
-
<div class="method">
|
1984
|
-
<div class="title">
|
1985
|
-
<a name="M000427"></a><b>this</b>()
|
1986
|
-
</div>
|
1987
|
-
<div class="description">
|
1988
|
-
<p>
|
1989
|
-
Returns the method object of the current method.
|
1990
|
-
</p>
|
1991
|
-
</div>
|
1992
|
-
<div class="sourcecode">
|
1993
|
-
<p class="source-link">[ <a href="javascript:toggleSource('M000427_source')" id="l_M000427_source">show source</a> ]</p>
|
1994
|
-
<div id="M000427_source" class="dyn-source">
|
1995
|
-
<pre>
|
1996
|
-
<span class="ruby-comment cmt"># File lib/facets/core/kernel/this.rb, line 7</span>
|
1997
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">this</span>
|
1998
|
-
<span class="ruby-identifier">name</span> = <span class="ruby-regexp re">/\`([^\']+)\'/</span>.<span class="ruby-identifier">match</span>(<span class="ruby-identifier">caller</span>(<span class="ruby-value">1</span>).<span class="ruby-identifier">first</span>)[<span class="ruby-value">1</span>]
|
1999
|
-
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">method</span>(<span class="ruby-identifier">name</span>)
|
2000
|
-
<span class="ruby-keyword kw">end</span>
|
2001
|
-
</pre>
|
2002
|
-
</div>
|
2003
|
-
</div>
|
2004
|
-
</div>
|
2005
|
-
</div>
|
2006
|
-
|
2007
|
-
</div>
|
2008
|
-
|
2009
|
-
</body>
|
2010
|
-
</html>
|