carats 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +2 -0
- data/LICENSE +5 -0
- data/README +67 -0
- data/Reapfile +72 -0
- data/ToDo +24 -0
- data/bench/b_harray.rb +49 -0
- data/bench/b_range.rb +64 -0
- data/demo/ansicolor/cdiff.rb +20 -0
- data/demo/ansicolor/example.rb +82 -0
- data/demo/io-reactor/chatserver.rb +347 -0
- data/doc/classes/Array.html +172 -0
- data/doc/classes/BBCode.html +638 -0
- data/doc/classes/BinaryReader.html +675 -0
- data/doc/classes/Binding.html +223 -0
- data/doc/classes/ByteOrder.html +284 -0
- data/doc/classes/Class.html +189 -0
- data/doc/classes/Constant.html +785 -0
- data/doc/classes/Constant/CGS.html +609 -0
- data/doc/classes/Continuation.html +113 -0
- data/doc/classes/Coroutine.html +387 -0
- data/doc/classes/CountingSemaphore.html +337 -0
- data/doc/classes/CrossCase.html +561 -0
- data/doc/classes/DynamicMixin.html +185 -0
- data/doc/classes/EnumerableWithArgs.html +550 -0
- data/doc/classes/Expect.html +428 -0
- data/doc/classes/Expect/DefaultChain.html +113 -0
- data/doc/classes/Expect/SeparatedPattern.html +223 -0
- data/doc/classes/Expect/Timeout.html +167 -0
- data/doc/classes/Expect/UnmatchedMessage.html +160 -0
- data/doc/classes/FileList.html +833 -0
- data/doc/classes/FloatString.html +534 -0
- data/doc/classes/Functor.html +211 -0
- data/doc/classes/HArray.html +1872 -0
- data/doc/classes/HTML.html +328 -0
- data/doc/classes/Heap.html +683 -0
- data/doc/classes/Heap/EmptyHeapException.html +111 -0
- data/doc/classes/Heap/Max.html +176 -0
- data/doc/classes/Heap/Min.html +176 -0
- data/doc/classes/IO.html +108 -0
- data/doc/classes/IO/Reactor.html +790 -0
- data/doc/classes/IO/Redirect.html +289 -0
- data/doc/classes/Infinity.html +320 -0
- data/doc/classes/Interval.html +1014 -0
- data/doc/classes/InvalidNackError.html +161 -0
- data/doc/classes/Kernel.html +204 -0
- data/doc/classes/Lisp.html +1132 -0
- data/doc/classes/Lisp/DottedPair.html +379 -0
- data/doc/classes/Lisp/Format.html +178 -0
- data/doc/classes/Lisp/Format/ArgumentError.html +126 -0
- data/doc/classes/Lisp/Format/Directives.html +155 -0
- data/doc/classes/Lisp/Format/Directives/ArgJump.html +178 -0
- data/doc/classes/Lisp/Format/Directives/Ascii.html +119 -0
- data/doc/classes/Lisp/Format/Directives/BeginCaseConversion.html +185 -0
- data/doc/classes/Lisp/Format/Directives/BeginConditional.html +307 -0
- data/doc/classes/Lisp/Format/Directives/BeginIteration.html +338 -0
- data/doc/classes/Lisp/Format/Directives/Binary.html +157 -0
- data/doc/classes/Lisp/Format/Directives/Character.html +228 -0
- data/doc/classes/Lisp/Format/Directives/CharacterDirective.html +203 -0
- data/doc/classes/Lisp/Format/Directives/ClauseSeparator.html +166 -0
- data/doc/classes/Lisp/Format/Directives/Decimal.html +119 -0
- data/doc/classes/Lisp/Format/Directives/Directive.html +397 -0
- data/doc/classes/Lisp/Format/Directives/DollarFP.html +205 -0
- data/doc/classes/Lisp/Format/Directives/EndCaseConversion.html +174 -0
- data/doc/classes/Lisp/Format/Directives/EndConditional.html +159 -0
- data/doc/classes/Lisp/Format/Directives/EndIteration.html +163 -0
- data/doc/classes/Lisp/Format/Directives/ExpFP.html +252 -0
- data/doc/classes/Lisp/Format/Directives/FFFP.html +224 -0
- data/doc/classes/Lisp/Format/Directives/Factory.html +180 -0
- data/doc/classes/Lisp/Format/Directives/FreshLine.html +175 -0
- data/doc/classes/Lisp/Format/Directives/GeneralFP.html +265 -0
- data/doc/classes/Lisp/Format/Directives/Hexadecimal.html +157 -0
- data/doc/classes/Lisp/Format/Directives/Indirection.html +183 -0
- data/doc/classes/Lisp/Format/Directives/Literal.html +187 -0
- data/doc/classes/Lisp/Format/Directives/NewLine.html +158 -0
- data/doc/classes/Lisp/Format/Directives/NewPage.html +158 -0
- data/doc/classes/Lisp/Format/Directives/Number.html +243 -0
- data/doc/classes/Lisp/Format/Directives/Octal.html +157 -0
- data/doc/classes/Lisp/Format/Directives/Plural.html +177 -0
- data/doc/classes/Lisp/Format/Directives/Print.html +237 -0
- data/doc/classes/Lisp/Format/Directives/Radix.html +432 -0
- data/doc/classes/Lisp/Format/Directives/SExpression.html +157 -0
- data/doc/classes/Lisp/Format/Directives/SkipWhitespace.html +165 -0
- data/doc/classes/Lisp/Format/Directives/Tabulate.html +198 -0
- data/doc/classes/Lisp/Format/Directives/Tilde.html +158 -0
- data/doc/classes/Lisp/Format/Directives/UnknownDirectiveError.html +117 -0
- data/doc/classes/Lisp/Format/Formatter.html +193 -0
- data/doc/classes/Lisp/Format/IncompleteParameterError.html +119 -0
- data/doc/classes/Lisp/Format/IndexError.html +126 -0
- data/doc/classes/Lisp/Format/Lexer.html +479 -0
- data/doc/classes/Lisp/Format/MalformedError.html +119 -0
- data/doc/classes/Lisp/Format/MissingParameterError.html +119 -0
- data/doc/classes/Lisp/Format/ModifierError.html +119 -0
- data/doc/classes/Lisp/Format/Output.html +239 -0
- data/doc/classes/Lisp/Format/ParameterError.html +126 -0
- data/doc/classes/Lisp/Format/Parameters.html +123 -0
- data/doc/classes/Lisp/Format/Parameters/Argument.html +172 -0
- data/doc/classes/Lisp/Format/Parameters/ArgumentCount.html +159 -0
- data/doc/classes/Lisp/Format/Parameters/Character.html +119 -0
- data/doc/classes/Lisp/Format/Parameters/Default.html +120 -0
- data/doc/classes/Lisp/Format/Parameters/Integer.html +119 -0
- data/doc/classes/Lisp/Format/Parameters/Parameter.html +206 -0
- data/doc/classes/Lisp/Format/Parser.html +212 -0
- data/doc/classes/Lisp/Format/Positioned.html +166 -0
- data/doc/classes/Lisp/Format/State.html +455 -0
- data/doc/classes/Lisp/Format/SyntaxError.html +126 -0
- data/doc/classes/Method.html +274 -0
- data/doc/classes/Method/DuckHunter.html +281 -0
- data/doc/classes/Module.html +709 -0
- data/doc/classes/Multiton.html +284 -0
- data/doc/classes/Multiton/New.html +164 -0
- data/doc/classes/Multiton/Semi.html +155 -0
- data/doc/classes/NackClass.html +322 -0
- data/doc/classes/NilClass.html +231 -0
- data/doc/classes/NilComparable.html +179 -0
- data/doc/classes/NotCopyable.html +273 -0
- data/doc/classes/Object.html +261 -0
- data/doc/classes/OpenStructable.html +346 -0
- data/doc/classes/OrderedHash.html +939 -0
- data/doc/classes/Parser.html +515 -0
- data/doc/classes/Parser/Main.html +178 -0
- data/doc/classes/Parser/Marker.html +475 -0
- data/doc/classes/Parser/Registry.html +354 -0
- data/doc/classes/Parser/Token.html +399 -0
- data/doc/classes/Parser/UnitToken.html +222 -0
- data/doc/classes/Ref.html +230 -0
- data/doc/classes/SimpleStringIO.html +183 -0
- data/doc/classes/StaticHash.html +202 -0
- data/doc/classes/String.html +172 -0
- data/doc/classes/Struct.html +181 -0
- data/doc/classes/SuperStruct.html +382 -0
- data/doc/classes/Term.html +156 -0
- data/doc/classes/Term/ANSIColor.html +185 -0
- data/doc/classes/Text.html +138 -0
- data/doc/classes/Text/Soundex.html +222 -0
- data/doc/classes/TextTagIterator.html +911 -0
- data/doc/classes/Time.html +119 -0
- data/doc/classes/Time/Limit.html +303 -0
- data/doc/classes/Time/Limit/Dummy.html +181 -0
- data/doc/classes/Timer.html +351 -0
- data/doc/classes/TracePoint.html +532 -0
- data/doc/classes/Tuple.html +178 -0
- data/doc/classes/Uninheritable.html +213 -0
- data/doc/classes/Version.html +783 -0
- data/doc/created.rid +1 -0
- data/doc/files/LICENSE.html +113 -0
- data/doc/files/README.html +201 -0
- data/doc/files/lib/carat/1st_rb.html +107 -0
- data/doc/files/lib/carat/ansicolor_rb.html +146 -0
- data/doc/files/lib/carat/attr_rb.html +101 -0
- data/doc/files/lib/carat/bbcode_rb.html +152 -0
- data/doc/files/lib/carat/binaryreader_rb.html +114 -0
- data/doc/files/lib/carat/binding-of-caller_rb.html +108 -0
- data/doc/files/lib/carat/byteorder_rb.html +107 -0
- data/doc/files/lib/carat/constant_rb.html +167 -0
- data/doc/files/lib/carat/coroutine_rb.html +156 -0
- data/doc/files/lib/carat/crosscase_rb.html +224 -0
- data/doc/files/lib/carat/duckhunter_rb.html +165 -0
- data/doc/files/lib/carat/dynamic-mixin_rb.html +101 -0
- data/doc/files/lib/carat/enumerable-args_rb.html +140 -0
- data/doc/files/lib/carat/expect_rb.html +137 -0
- data/doc/files/lib/carat/filelist_rb.html +130 -0
- data/doc/files/lib/carat/floatstring_rb.html +126 -0
- data/doc/files/lib/carat/functor_rb.html +140 -0
- data/doc/files/lib/carat/harray_rb.html +128 -0
- data/doc/files/lib/carat/heap_rb.html +154 -0
- data/doc/files/lib/carat/html-helpers_rb.html +116 -0
- data/doc/files/lib/carat/infinity_rb.html +142 -0
- data/doc/files/lib/carat/init_rb.html +127 -0
- data/doc/files/lib/carat/interval_rb.html +162 -0
- data/doc/files/lib/carat/io-reactor_rb.html +211 -0
- data/doc/files/lib/carat/io-redirect_rb.html +132 -0
- data/doc/files/lib/carat/lisp-format_rb.html +187 -0
- data/doc/files/lib/carat/lisp_rb.html +152 -0
- data/doc/files/lib/carat/macro_rb.html +129 -0
- data/doc/files/lib/carat/multiton_rb.html +178 -0
- data/doc/files/lib/carat/nack_rb.html +193 -0
- data/doc/files/lib/carat/nil-comparable_rb.html +126 -0
- data/doc/files/lib/carat/nil-missing_rb.html +101 -0
- data/doc/files/lib/carat/notcopyable_rb.html +166 -0
- data/doc/files/lib/carat/orderedhash_rb.html +107 -0
- data/doc/files/lib/carat/ostructable_rb.html +157 -0
- data/doc/files/lib/carat/parser-old_rb.html +239 -0
- data/doc/files/lib/carat/parser_rb.html +244 -0
- data/doc/files/lib/carat/ref_rb.html +107 -0
- data/doc/files/lib/carat/semaphore_rb.html +132 -0
- data/doc/files/lib/carat/snapshot_rb.html +152 -0
- data/doc/files/lib/carat/soundex_rb.html +128 -0
- data/doc/files/lib/carat/sstruct_rb.html +142 -0
- data/doc/files/lib/carat/statichash_rb.html +150 -0
- data/doc/files/lib/carat/tagiter_rb.html +236 -0
- data/doc/files/lib/carat/timelimit_rb.html +136 -0
- data/doc/files/lib/carat/timer_rb.html +153 -0
- data/doc/files/lib/carat/tracepoint_rb.html +160 -0
- data/doc/files/lib/carat/tuple_rb.html +123 -0
- data/doc/files/lib/carat/uninheritable_rb.html +101 -0
- data/doc/files/lib/carat/version_rb.html +141 -0
- data/doc/fr_class_index.html +159 -0
- data/doc/fr_file_index.html +78 -0
- data/doc/fr_method_index.html +663 -0
- data/doc/index.html +24 -0
- data/doc/rdoc-style.css +208 -0
- data/lib/carat-dev/README +11 -0
- data/lib/carat-dev/access-blocks/access_blocks.rb +42 -0
- data/lib/carat-dev/association/association.rb +70 -0
- data/lib/carat-dev/blankslate/blankslate.rb +51 -0
- data/lib/carat-dev/breakpoint.rb +518 -0
- data/lib/carat-dev/class-constructor/constructor_methods.rb +78 -0
- data/lib/carat-dev/class-constructor/tc_constructor.rb +35 -0
- data/lib/carat-dev/closecall/closecall-test.rb +39 -0
- data/lib/carat-dev/closecall/closecall.rb +101 -0
- data/lib/carat-dev/commandrunner/commandrunner.rb +100 -0
- data/lib/carat-dev/conditional/conditionals.rb +106 -0
- data/lib/carat-dev/daemon/daemon.rb +70 -0
- data/lib/carat-dev/detach/detach.rb +363 -0
- data/lib/carat-dev/detach/tc_detach.rb +57 -0
- data/lib/carat-dev/import-module/import-module-0.81.tar.gz +0 -0
- data/lib/carat-dev/import-module/import-module-0.81/LICENSE +1 -0
- data/lib/carat-dev/import-module/import-module-0.81/Makefile +11 -0
- data/lib/carat-dev/import-module/import-module-0.81/README +4 -0
- data/lib/carat-dev/import-module/import-module-0.81/dev-lib/import-module-hash.rb +49 -0
- data/lib/carat-dev/import-module/import-module-0.81/dev-lib/import-module-pip.rb +71 -0
- data/lib/carat-dev/import-module/import-module-0.81/dev-lib/import-module-unbound-method.rb +36 -0
- data/lib/carat-dev/import-module/import-module-0.81/doc/README-ja.html +293 -0
- data/lib/carat-dev/import-module/import-module-0.81/doc/README-ja.rd +306 -0
- data/lib/carat-dev/import-module/import-module-0.81/doc/README.html +290 -0
- data/lib/carat-dev/import-module/import-module-0.81/doc/README.rd +303 -0
- data/lib/carat-dev/import-module/import-module-0.81/doc/style.css +85 -0
- data/lib/carat-dev/import-module/import-module-0.81/install.rb +99 -0
- data/lib/carat-dev/import-module/import-module-0.81/lib/import-module-single-thread.rb +84 -0
- data/lib/carat-dev/import-module/import-module-0.81/lib/import-module.rb +493 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/Makefile +2 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test +91 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test-import-module.rb +936 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test-import_scope.rb +33 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test-scope_import.rb +33 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test-time.rb +184 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/test.sh +91 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/time.rb +135 -0
- data/lib/carat-dev/import-module/import-module-0.81/test/times-do.sh +10 -0
- data/lib/carat-dev/interface_work/SCRAP/i-contracts.rb +37 -0
- data/lib/carat-dev/interface_work/SCRAP/interface.rb +105 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0.zip +0 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/CHANGES +3 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/MANIFEST +15 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/README +32 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/doc/interface.rd +73 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/doc/interface.txt +94 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/install.rb +16 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/lib/interface.rb +50 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/test/tc_interface.rb +51 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/test/test.rb +29 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/test/test_instance.rb +24 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/test/test_sub.rb +29 -0
- data/lib/carat-dev/interface_work/SCRAP/j-interface/interface-0.1.0/test/test_unrequire.rb +28 -0
- data/lib/carat-dev/interface_work/contracts/contract.zip +0 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.html +376 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000001.html +23 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000002.html +18 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000003.html +19 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000004.html +29 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000005.html +18 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract.src/M000006.html +18 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract/ContractError.html +142 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract/ContractException.html +153 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Contract/ContractMismatch.html +125 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Module.html +157 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/classes/Module.src/M000007.html +112 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/created.rid +1 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/files/lib/contract/assertions_rb.html +109 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/files/lib/contract/exception_rb.html +108 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/files/lib/contract/integration_rb.html +108 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/files/lib/contract/overrides_rb.html +109 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/files/lib/contract_rb.html +114 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/fr_class_index.html +31 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/fr_file_index.html +31 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/fr_method_index.html +33 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/index.html +24 -0
- data/lib/carat-dev/interface_work/contracts/contract/doc/rdoc-style.css +208 -0
- data/lib/carat-dev/interface_work/contracts/contract/lib/contract.rb +88 -0
- data/lib/carat-dev/interface_work/contracts/contract/lib/contract/assertions.rb +37 -0
- data/lib/carat-dev/interface_work/contracts/contract/lib/contract/exception.rb +92 -0
- data/lib/carat-dev/interface_work/contracts/contract/lib/contract/integration.rb +132 -0
- data/lib/carat-dev/interface_work/contracts/contract/lib/contract/overrides.rb +32 -0
- data/lib/carat-dev/interface_work/must.rb +37 -0
- data/lib/carat-dev/interface_work/type.rb +232 -0
- data/lib/carat-dev/main/tc_toplevel.rb +23 -0
- data/lib/carat-dev/main/toplevel.rb +33 -0
- data/lib/carat-dev/main/toplevel_test.rb +24 -0
- data/lib/carat-dev/misc/1.rb +40 -0
- data/lib/carat-dev/misc/misc.rb +44 -0
- data/lib/carat-dev/misc/sys.rb +186 -0
- data/lib/carat-dev/misc/temp.rb +1 -0
- data/lib/carat-dev/misc/utils.rb +518 -0
- data/lib/carat-dev/predicate/predicate.rb +109 -0
- data/lib/carat-dev/predicate/predicate_test.rb +67 -0
- data/lib/carat-dev/premshree.rb +40 -0
- data/lib/carat-dev/priority-queue/pqueue.rb +183 -0
- data/lib/carat-dev/priority-queue/priorityqueue.rb +84 -0
- data/lib/carat-dev/quaternion/quaternion.rb +529 -0
- data/lib/carat-dev/range.rb +259 -0
- data/lib/carat-dev/system/rubyinfo.rb +75 -0
- data/lib/carat-dev/system/system.rb +105 -0
- data/lib/carat-dev/tc_range.rb +118 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.html +291 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000001.html +26 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000002.html +19 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000003.html +18 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000004.html +18 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000005.html +21 -0
- data/lib/carat-dev/timer/timer-doc/classes/Timer.src/M000006.html +23 -0
- data/lib/carat-dev/timer/timer-doc/created.rid +1 -0
- data/lib/carat-dev/timer/timer-doc/files/timer_rb.html +144 -0
- data/lib/carat-dev/timer/timer-doc/fr_class_index.html +27 -0
- data/lib/carat-dev/timer/timer-doc/fr_file_index.html +27 -0
- data/lib/carat-dev/timer/timer-doc/fr_method_index.html +32 -0
- data/lib/carat-dev/timer/timer-doc/index.html +24 -0
- data/lib/carat-dev/timer/timer-doc/rdoc-style.css +208 -0
- data/lib/carat-dev/timer/timer.rb +160 -0
- data/lib/carat-dev/vars/vars.rb +62 -0
- data/lib/carat/1st.rb +58 -0
- data/lib/carat/ansicolor.rb +122 -0
- data/lib/carat/attr.rb +342 -0
- data/lib/carat/bbcode.rb +352 -0
- data/lib/carat/binaryreader.rb +170 -0
- data/lib/carat/binding-of-caller.rb +83 -0
- data/lib/carat/byteorder.rb +34 -0
- data/lib/carat/constant.rb +287 -0
- data/lib/carat/coroutine.rb +102 -0
- data/lib/carat/crosscase.rb +309 -0
- data/lib/carat/duckhunter.rb +158 -0
- data/lib/carat/dynamic-mixin.rb +71 -0
- data/lib/carat/enumerable-args.rb +125 -0
- data/lib/carat/expect.rb +192 -0
- data/lib/carat/filelist.rb +277 -0
- data/lib/carat/floatstring.rb +153 -0
- data/lib/carat/functor.rb +41 -0
- data/lib/carat/harray.rb +507 -0
- data/lib/carat/heap.rb +193 -0
- data/lib/carat/html-helpers.rb +82 -0
- data/lib/carat/infinity.rb +61 -0
- data/lib/carat/init.rb +33 -0
- data/lib/carat/interval.rb +248 -0
- data/lib/carat/io-reactor.rb +657 -0
- data/lib/carat/io-redirect.rb +99 -0
- data/lib/carat/lisp-format.rb +1832 -0
- data/lib/carat/lisp.rb +336 -0
- data/lib/carat/macro.rb +68 -0
- data/lib/carat/multiton.rb +153 -0
- data/lib/carat/nack.rb +115 -0
- data/lib/carat/nil-comparable.rb +67 -0
- data/lib/carat/nil-missing.rb +12 -0
- data/lib/carat/notcopyable.rb +68 -0
- data/lib/carat/orderedhash.rb +249 -0
- data/lib/carat/ostructable.rb +138 -0
- data/lib/carat/parser-old.rb +350 -0
- data/lib/carat/parser.rb +393 -0
- data/lib/carat/ref.rb +31 -0
- data/lib/carat/semaphore.rb +69 -0
- data/lib/carat/snapshot.rb +94 -0
- data/lib/carat/soundex.rb +104 -0
- data/lib/carat/sstruct.rb +223 -0
- data/lib/carat/statichash.rb +49 -0
- data/lib/carat/tagiter.rb +345 -0
- data/lib/carat/timelimit.rb +114 -0
- data/lib/carat/timer.rb +99 -0
- data/lib/carat/tracepoint.rb +154 -0
- data/lib/carat/tuple.rb +31 -0
- data/lib/carat/uninheritable.rb +68 -0
- data/lib/carat/version.rb +147 -0
- data/pub/doc/sstruct.txt +204 -0
- data/pub/doc/tagiter.html +145 -0
- data/setup.rb +1361 -0
- data/test/fixtures/filelist/testfile.txt +1 -0
- data/test/fixtures/filelist/testfile2.txt +1 -0
- data/test/tc_1st.rb +16 -0
- data/test/tc_ansicolor.rb +23 -0
- data/test/tc_attr.rb +46 -0
- data/test/tc_bbcode.rb +20 -0
- data/test/tc_binaryreader.rb +14 -0
- data/test/tc_binding_of_caller.rb +2 -0
- data/test/tc_byteorder.rb +41 -0
- data/test/tc_constant.rb +12 -0
- data/test/tc_coroutine.rb +50 -0
- data/test/tc_crosscase.rb +33 -0
- data/test/tc_duckhunter.rb +37 -0
- data/test/tc_dynamic-mixin.rb +66 -0
- data/test/tc_enumerable-args.rb +66 -0
- data/test/tc_expect.rb +83 -0
- data/test/tc_filelist.rb +17 -0
- data/test/tc_floatstring.rb +22 -0
- data/test/tc_functor.rb +18 -0
- data/test/tc_harray.rb +280 -0
- data/test/tc_heap.rb +6 -0
- data/test/tc_infinity.rb +23 -0
- data/test/tc_init.rb +29 -0
- data/test/tc_interval.rb +153 -0
- data/test/tc_io-reactor.rb +5 -0
- data/test/tc_io-redirect.rb +5 -0
- data/test/tc_lisp-format.rb +24 -0
- data/test/tc_lisp.rb +32 -0
- data/test/tc_macro.rb +48 -0
- data/test/tc_multiton.rb +188 -0
- data/test/tc_nack.rb +31 -0
- data/test/tc_nil-as-emptiness.rb +19 -0
- data/test/tc_nil-comparable.rb +29 -0
- data/test/tc_nil-missing.rb +0 -0
- data/test/tc_notcopyable.rb +64 -0
- data/test/tc_orderedhash.rb +36 -0
- data/test/tc_ostructable.rb +31 -0
- data/test/tc_semaphore.rb +5 -0
- data/test/tc_snapshot.rb +20 -0
- data/test/tc_soundex.rb +19 -0
- data/test/tc_sstruct.rb +313 -0
- data/test/tc_statichash.rb +24 -0
- data/test/tc_tagiter.rb +80 -0
- data/test/tc_timelimit.rb +47 -0
- data/test/tc_timer.rb +35 -0
- data/test/tc_tracepoint.rb +10 -0
- data/test/tc_tuple.rb +25 -0
- data/test/tc_uninheritable.rb +33 -0
- data/test/tc_version.rb +90 -0
- metadata +531 -0
@@ -0,0 +1,833 @@
|
|
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
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: FileList</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">FileList</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/carat/filelist_rb.html">
|
59
|
+
lib/carat/filelist.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
<a href="Array.html">
|
69
|
+
Array
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
<div id="description">
|
84
|
+
<h1><a href="FileList.html">FileList</a></h1>
|
85
|
+
<p>
|
86
|
+
A <a href="FileList.html">FileList</a> is essentially an array with a few
|
87
|
+
helper methods defined to make file manipulation a bit easier. It works in
|
88
|
+
a fashion similar to Dir.glob.
|
89
|
+
</p>
|
90
|
+
<h2>Synopsis</h2>
|
91
|
+
<pre>
|
92
|
+
require 'trix/filelist'
|
93
|
+
|
94
|
+
fl = FileList.new
|
95
|
+
fl.include('./**/*')
|
96
|
+
fl.exclude('./*~')
|
97
|
+
</pre>
|
98
|
+
<h2>Legal</h2>
|
99
|
+
<p>
|
100
|
+
Ported from Rake Copyright (C) 2002 Jim Welch
|
101
|
+
</p>
|
102
|
+
<p>
|
103
|
+
You may distribute this software under the same terms as Ruby (see the file
|
104
|
+
COPYING that was distributed with this library).
|
105
|
+
</p>
|
106
|
+
<h2>History</h2>
|
107
|
+
<pre>
|
108
|
+
$id: filelist.rb 2004/11/27 10:00:01 transami Exp $
|
109
|
+
</pre>
|
110
|
+
|
111
|
+
</div>
|
112
|
+
|
113
|
+
|
114
|
+
</div>
|
115
|
+
|
116
|
+
<div id="method-list">
|
117
|
+
<h3 class="section-bar">Methods</h3>
|
118
|
+
|
119
|
+
<div class="name-list">
|
120
|
+
<a href="#M000345">[]</a>
|
121
|
+
<a href="#M000330">add</a>
|
122
|
+
<a href="#M000343">add_matching</a>
|
123
|
+
<a href="#M000334">calculate_exclude_regexp</a>
|
124
|
+
<a href="#M000332">clear_exclude</a>
|
125
|
+
<a href="#M000347">clear_ignore_patterns</a>
|
126
|
+
<a href="#M000331">exclude</a>
|
127
|
+
<a href="#M000344">exclude?</a>
|
128
|
+
<a href="#M000338">gsub</a>
|
129
|
+
<a href="#M000340">gsub!</a>
|
130
|
+
<a href="#M000329">include</a>
|
131
|
+
<a href="#M000328">new</a>
|
132
|
+
<a href="#M000333">resolve</a>
|
133
|
+
<a href="#M000335">resolve_add</a>
|
134
|
+
<a href="#M000336">resolve_exclude</a>
|
135
|
+
<a href="#M000346">select_default_ignore_patterns</a>
|
136
|
+
<a href="#M000337">sub</a>
|
137
|
+
<a href="#M000339">sub!</a>
|
138
|
+
<a href="#M000341">to_s</a>
|
139
|
+
<a href="#M000342">to_str</a>
|
140
|
+
</div>
|
141
|
+
</div>
|
142
|
+
|
143
|
+
</div>
|
144
|
+
|
145
|
+
|
146
|
+
<!-- if includes -->
|
147
|
+
|
148
|
+
<div id="section">
|
149
|
+
|
150
|
+
|
151
|
+
<div id="constants-list">
|
152
|
+
<h3 class="section-bar">Constants</h3>
|
153
|
+
|
154
|
+
<div class="name-list">
|
155
|
+
<table summary="Constants">
|
156
|
+
<tr class="top-aligned-row context-row">
|
157
|
+
<td class="context-item-name">DEFAULT_IGNORE_PATTERNS</td>
|
158
|
+
<td>=</td>
|
159
|
+
<td class="context-item-value">[ /(^|[\/\\])CVS([\/\\]|$)/, /\.bak$/, /~$/, /(^|[\/\\])core$/</td>
|
160
|
+
</tr>
|
161
|
+
</table>
|
162
|
+
</div>
|
163
|
+
</div>
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
|
168
|
+
|
169
|
+
|
170
|
+
<!-- if method_list -->
|
171
|
+
<div id="methods">
|
172
|
+
<h3 class="section-bar">Public Class methods</h3>
|
173
|
+
|
174
|
+
<div id="method-M000345" class="method-detail">
|
175
|
+
<a name="M000345"></a>
|
176
|
+
|
177
|
+
<div class="method-heading">
|
178
|
+
<a href="#M000345" class="method-signature">
|
179
|
+
<span class="method-name">[]</span><span class="method-args">(*args)</span>
|
180
|
+
</a>
|
181
|
+
</div>
|
182
|
+
|
183
|
+
<div class="method-description">
|
184
|
+
<p>
|
185
|
+
Create a new file list including the files listed. Similar to:
|
186
|
+
</p>
|
187
|
+
<pre>
|
188
|
+
FileList.new(*args)
|
189
|
+
</pre>
|
190
|
+
<p><a class="source-toggle" href="#"
|
191
|
+
onclick="toggleCode('M000345-source');return false;">[Source]</a></p>
|
192
|
+
<div class="method-source-code" id="M000345-source">
|
193
|
+
<pre>
|
194
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 253</span>
|
195
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-operator">[]</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
196
|
+
<span class="ruby-identifier">new</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
197
|
+
<span class="ruby-keyword kw">end</span>
|
198
|
+
</pre>
|
199
|
+
</div>
|
200
|
+
</div>
|
201
|
+
</div>
|
202
|
+
|
203
|
+
<div id="method-M000347" class="method-detail">
|
204
|
+
<a name="M000347"></a>
|
205
|
+
|
206
|
+
<div class="method-heading">
|
207
|
+
<a href="#M000347" class="method-signature">
|
208
|
+
<span class="method-name">clear_ignore_patterns</span><span class="method-args">()</span>
|
209
|
+
</a>
|
210
|
+
</div>
|
211
|
+
|
212
|
+
<div class="method-description">
|
213
|
+
<p>
|
214
|
+
Clear the ignore patterns.
|
215
|
+
</p>
|
216
|
+
<p><a class="source-toggle" href="#"
|
217
|
+
onclick="toggleCode('M000347-source');return false;">[Source]</a></p>
|
218
|
+
<div class="method-source-code" id="M000347-source">
|
219
|
+
<pre>
|
220
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 272</span>
|
221
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">clear_ignore_patterns</span>
|
222
|
+
<span class="ruby-ivar">@exclude_patterns</span> = [ <span class="ruby-regexp re">/^$/</span> ]
|
223
|
+
<span class="ruby-keyword kw">end</span>
|
224
|
+
</pre>
|
225
|
+
</div>
|
226
|
+
</div>
|
227
|
+
</div>
|
228
|
+
|
229
|
+
<div id="method-M000328" class="method-detail">
|
230
|
+
<a name="M000328"></a>
|
231
|
+
|
232
|
+
<div class="method-heading">
|
233
|
+
<a href="#M000328" class="method-signature">
|
234
|
+
<span class="method-name">new</span><span class="method-args">(*patterns) {|self if block_given?| ...}</span>
|
235
|
+
</a>
|
236
|
+
</div>
|
237
|
+
|
238
|
+
<div class="method-description">
|
239
|
+
<p>
|
240
|
+
Create a file list from the globbable patterns given. If you wish to
|
241
|
+
perform multiple includes or excludes at object build time, use the
|
242
|
+
"yield self" pattern.
|
243
|
+
</p>
|
244
|
+
<p>
|
245
|
+
Example:
|
246
|
+
</p>
|
247
|
+
<pre>
|
248
|
+
file_list = FileList.new['lib/**/*.rb', 'test/test*.rb']
|
249
|
+
|
250
|
+
pkg_files = FileList.new['lib/**/*'] do |fl|
|
251
|
+
fl.exclude(/\bCVS\b/)
|
252
|
+
end
|
253
|
+
</pre>
|
254
|
+
<p><a class="source-toggle" href="#"
|
255
|
+
onclick="toggleCode('M000328-source');return false;">[Source]</a></p>
|
256
|
+
<div class="method-source-code" id="M000328-source">
|
257
|
+
<pre>
|
258
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 58</span>
|
259
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">patterns</span>)
|
260
|
+
<span class="ruby-ivar">@pending_add</span> = []
|
261
|
+
<span class="ruby-ivar">@pending</span> = <span class="ruby-keyword kw">false</span>
|
262
|
+
<span class="ruby-ivar">@exclude_patterns</span> = <span class="ruby-constant">DEFAULT_IGNORE_PATTERNS</span>.<span class="ruby-identifier">dup</span>
|
263
|
+
<span class="ruby-ivar">@exclude_re</span> = <span class="ruby-keyword kw">nil</span>
|
264
|
+
<span class="ruby-comment cmt"># @extent_only = false</span>
|
265
|
+
<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">pattern</span><span class="ruby-operator">|</span> <span class="ruby-identifier">include</span>(<span class="ruby-identifier">pattern</span>) }
|
266
|
+
<span class="ruby-keyword kw">yield</span> <span class="ruby-keyword kw">self</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block_given?</span>
|
267
|
+
<span class="ruby-keyword kw">end</span>
|
268
|
+
</pre>
|
269
|
+
</div>
|
270
|
+
</div>
|
271
|
+
</div>
|
272
|
+
|
273
|
+
<div id="method-M000346" class="method-detail">
|
274
|
+
<a name="M000346"></a>
|
275
|
+
|
276
|
+
<div class="method-heading">
|
277
|
+
<a href="#M000346" class="method-signature">
|
278
|
+
<span class="method-name">select_default_ignore_patterns</span><span class="method-args">()</span>
|
279
|
+
</a>
|
280
|
+
</div>
|
281
|
+
|
282
|
+
<div class="method-description">
|
283
|
+
<p>
|
284
|
+
Set the ignore patterns back to the default value. The default patterns
|
285
|
+
will ignore files
|
286
|
+
</p>
|
287
|
+
<ul>
|
288
|
+
<li>containing "CVS" in the file path
|
289
|
+
|
290
|
+
</li>
|
291
|
+
<li>ending with ".bak"
|
292
|
+
|
293
|
+
</li>
|
294
|
+
<li>ending with "~"
|
295
|
+
|
296
|
+
</li>
|
297
|
+
<li>named "core"
|
298
|
+
|
299
|
+
</li>
|
300
|
+
</ul>
|
301
|
+
<p>
|
302
|
+
Note that file names beginning with "." are automatically ignored
|
303
|
+
by Ruby’s glob patterns and are not specifically listed in the ignore
|
304
|
+
patterns.
|
305
|
+
</p>
|
306
|
+
<p><a class="source-toggle" href="#"
|
307
|
+
onclick="toggleCode('M000346-source');return false;">[Source]</a></p>
|
308
|
+
<div class="method-source-code" id="M000346-source">
|
309
|
+
<pre>
|
310
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 267</span>
|
311
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">select_default_ignore_patterns</span>
|
312
|
+
<span class="ruby-ivar">@exclude_patterns</span> = <span class="ruby-constant">DEFAULT_IGNORE_PATTERNS</span>.<span class="ruby-identifier">dup</span>
|
313
|
+
<span class="ruby-keyword kw">end</span>
|
314
|
+
</pre>
|
315
|
+
</div>
|
316
|
+
</div>
|
317
|
+
</div>
|
318
|
+
|
319
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
320
|
+
|
321
|
+
<div id="method-M000330" class="method-detail">
|
322
|
+
<a name="M000330"></a>
|
323
|
+
|
324
|
+
<div class="method-heading">
|
325
|
+
<span class="method-name">add</span><span class="method-args">(*filenames)</span>
|
326
|
+
</div>
|
327
|
+
|
328
|
+
<div class="method-description">
|
329
|
+
<p>
|
330
|
+
Alias for <a href="FileList.html#M000329">include</a>
|
331
|
+
</p>
|
332
|
+
</div>
|
333
|
+
</div>
|
334
|
+
|
335
|
+
<div id="method-M000334" class="method-detail">
|
336
|
+
<a name="M000334"></a>
|
337
|
+
|
338
|
+
<div class="method-heading">
|
339
|
+
<a href="#M000334" class="method-signature">
|
340
|
+
<span class="method-name">calculate_exclude_regexp</span><span class="method-args">()</span>
|
341
|
+
</a>
|
342
|
+
</div>
|
343
|
+
|
344
|
+
<div class="method-description">
|
345
|
+
<p><a class="source-toggle" href="#"
|
346
|
+
onclick="toggleCode('M000334-source');return false;">[Source]</a></p>
|
347
|
+
<div class="method-source-code" id="M000334-source">
|
348
|
+
<pre>
|
349
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 135</span>
|
350
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">calculate_exclude_regexp</span>
|
351
|
+
<span class="ruby-identifier">ignores</span> = []
|
352
|
+
<span class="ruby-ivar">@exclude_patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pat</span><span class="ruby-operator">|</span>
|
353
|
+
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">pat</span>
|
354
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">Regexp</span>
|
355
|
+
<span class="ruby-identifier">ignores</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">pat</span>
|
356
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-regexp re">/[*.]/</span>
|
357
|
+
<span class="ruby-constant">Dir</span>[<span class="ruby-identifier">pat</span>].<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">p</span><span class="ruby-operator">|</span> <span class="ruby-identifier">ignores</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">p</span> <span class="ruby-keyword kw">end</span>
|
358
|
+
<span class="ruby-keyword kw">else</span>
|
359
|
+
<span class="ruby-identifier">ignores</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">Regexp</span>.<span class="ruby-identifier">quote</span>(<span class="ruby-identifier">pat</span>)
|
360
|
+
<span class="ruby-keyword kw">end</span>
|
361
|
+
<span class="ruby-keyword kw">end</span>
|
362
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">ignores</span>.<span class="ruby-identifier">empty?</span>
|
363
|
+
<span class="ruby-ivar">@exclude_re</span> = <span class="ruby-regexp re">/^$/</span>
|
364
|
+
<span class="ruby-keyword kw">else</span>
|
365
|
+
<span class="ruby-identifier">re_str</span> = <span class="ruby-identifier">ignores</span>.<span class="ruby-identifier">collect</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">p</span><span class="ruby-operator">|</span> <span class="ruby-value str">"("</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">p</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-operator">+</span> <span class="ruby-value str">")"</span> }.<span class="ruby-identifier">join</span>(<span class="ruby-value str">"|"</span>)
|
366
|
+
<span class="ruby-ivar">@exclude_re</span> = <span class="ruby-constant">Regexp</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">re_str</span>)
|
367
|
+
<span class="ruby-keyword kw">end</span>
|
368
|
+
<span class="ruby-keyword kw">end</span>
|
369
|
+
</pre>
|
370
|
+
</div>
|
371
|
+
</div>
|
372
|
+
</div>
|
373
|
+
|
374
|
+
<div id="method-M000332" class="method-detail">
|
375
|
+
<a name="M000332"></a>
|
376
|
+
|
377
|
+
<div class="method-heading">
|
378
|
+
<a href="#M000332" class="method-signature">
|
379
|
+
<span class="method-name">clear_exclude</span><span class="method-args">()</span>
|
380
|
+
</a>
|
381
|
+
</div>
|
382
|
+
|
383
|
+
<div class="method-description">
|
384
|
+
<p><a class="source-toggle" href="#"
|
385
|
+
onclick="toggleCode('M000332-source');return false;">[Source]</a></p>
|
386
|
+
<div class="method-source-code" id="M000332-source">
|
387
|
+
<pre>
|
388
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 121</span>
|
389
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">clear_exclude</span>
|
390
|
+
<span class="ruby-ivar">@exclude_patterns</span> = []
|
391
|
+
<span class="ruby-identifier">calculate_exclude_regexp</span> <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span> <span class="ruby-ivar">@pending</span>
|
392
|
+
<span class="ruby-keyword kw">end</span>
|
393
|
+
</pre>
|
394
|
+
</div>
|
395
|
+
</div>
|
396
|
+
</div>
|
397
|
+
|
398
|
+
<div id="method-M000331" class="method-detail">
|
399
|
+
<a name="M000331"></a>
|
400
|
+
|
401
|
+
<div class="method-heading">
|
402
|
+
<a href="#M000331" class="method-signature">
|
403
|
+
<span class="method-name">exclude</span><span class="method-args">(*patterns)</span>
|
404
|
+
</a>
|
405
|
+
</div>
|
406
|
+
|
407
|
+
<div class="method-description">
|
408
|
+
<p>
|
409
|
+
Register a list of file name patterns that should be excluded from the
|
410
|
+
list. Patterns may be regular expressions, glob patterns or regular
|
411
|
+
strings.
|
412
|
+
</p>
|
413
|
+
<p>
|
414
|
+
Note that glob patterns are expanded against the file system. If a file is
|
415
|
+
explicitly added to a file list, but does not exist in the file system,
|
416
|
+
then an glob pattern in the exclude list will not exclude the file.
|
417
|
+
</p>
|
418
|
+
<p>
|
419
|
+
Examples:
|
420
|
+
</p>
|
421
|
+
<pre>
|
422
|
+
FileList['a.c', 'b.c'].exclude("a.c") => ['b.c']
|
423
|
+
FileList['a.c', 'b.c'].exclude(/^a/) => ['b.c']
|
424
|
+
</pre>
|
425
|
+
<p>
|
426
|
+
If "a.c" is a file, then …
|
427
|
+
</p>
|
428
|
+
<pre>
|
429
|
+
FileList['a.c', 'b.c'].exclude("a.*") => ['b.c']
|
430
|
+
</pre>
|
431
|
+
<p>
|
432
|
+
If "a.c" is not a file, then …
|
433
|
+
</p>
|
434
|
+
<pre>
|
435
|
+
FileList['a.c', 'b.c'].exclude("a.*") => ['a.c', 'b.c']
|
436
|
+
</pre>
|
437
|
+
<p><a class="source-toggle" href="#"
|
438
|
+
onclick="toggleCode('M000331-source');return false;">[Source]</a></p>
|
439
|
+
<div class="method-source-code" id="M000331-source">
|
440
|
+
<pre>
|
441
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 111</span>
|
442
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">exclude</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">patterns</span>)
|
443
|
+
<span class="ruby-comment cmt"># TODO: check for pending</span>
|
444
|
+
<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pat</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@exclude_patterns</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">pat</span> <span class="ruby-keyword kw">end</span>
|
445
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span> <span class="ruby-ivar">@pending</span>
|
446
|
+
<span class="ruby-identifier">calculate_exclude_regexp</span>
|
447
|
+
<span class="ruby-identifier">reject!</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">fn</span> <span class="ruby-operator">=~</span> <span class="ruby-ivar">@exclude_re</span> }
|
448
|
+
<span class="ruby-keyword kw">end</span>
|
449
|
+
<span class="ruby-keyword kw">end</span>
|
450
|
+
</pre>
|
451
|
+
</div>
|
452
|
+
</div>
|
453
|
+
</div>
|
454
|
+
|
455
|
+
<div id="method-M000344" class="method-detail">
|
456
|
+
<a name="M000344"></a>
|
457
|
+
|
458
|
+
<div class="method-heading">
|
459
|
+
<a href="#M000344" class="method-signature">
|
460
|
+
<span class="method-name">exclude?</span><span class="method-args">(fn)</span>
|
461
|
+
</a>
|
462
|
+
</div>
|
463
|
+
|
464
|
+
<div class="method-description">
|
465
|
+
<p>
|
466
|
+
Should the given file name be excluded?
|
467
|
+
</p>
|
468
|
+
<p><a class="source-toggle" href="#"
|
469
|
+
onclick="toggleCode('M000344-source');return false;">[Source]</a></p>
|
470
|
+
<div class="method-source-code" id="M000344-source">
|
471
|
+
<pre>
|
472
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 236</span>
|
473
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">exclude?</span>(<span class="ruby-identifier">fn</span>)
|
474
|
+
<span class="ruby-identifier">calculate_exclude_regexp</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-ivar">@exclude_re</span>
|
475
|
+
<span class="ruby-identifier">fn</span> <span class="ruby-operator">=~</span> <span class="ruby-ivar">@exclude_re</span>
|
476
|
+
<span class="ruby-keyword kw">end</span>
|
477
|
+
</pre>
|
478
|
+
</div>
|
479
|
+
</div>
|
480
|
+
</div>
|
481
|
+
|
482
|
+
<div id="method-M000338" class="method-detail">
|
483
|
+
<a name="M000338"></a>
|
484
|
+
|
485
|
+
<div class="method-heading">
|
486
|
+
<a href="#M000338" class="method-signature">
|
487
|
+
<span class="method-name">gsub</span><span class="method-args">(pat, rep)</span>
|
488
|
+
</a>
|
489
|
+
</div>
|
490
|
+
|
491
|
+
<div class="method-description">
|
492
|
+
<p>
|
493
|
+
Return a new <a href="FileList.html">FileList</a> with the results of
|
494
|
+
running <tt>gsub</tt> against each element of the original list.
|
495
|
+
</p>
|
496
|
+
<p>
|
497
|
+
Example:
|
498
|
+
</p>
|
499
|
+
<pre>
|
500
|
+
FileList['lib/test/file', 'x/y'].gsub(/\//, "\\")
|
501
|
+
=> ['lib\\test\\file', 'x\\y']
|
502
|
+
</pre>
|
503
|
+
<p><a class="source-toggle" href="#"
|
504
|
+
onclick="toggleCode('M000338-source');return false;">[Source]</a></p>
|
505
|
+
<div class="method-source-code" id="M000338-source">
|
506
|
+
<pre>
|
507
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 200</span>
|
508
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">gsub</span>(<span class="ruby-identifier">pat</span>, <span class="ruby-identifier">rep</span>)
|
509
|
+
<span class="ruby-identifier">inject</span>(<span class="ruby-constant">FileList</span>.<span class="ruby-identifier">new</span>) { <span class="ruby-operator">|</span><span class="ruby-identifier">res</span>, <span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">res</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">fn</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-identifier">pat</span>,<span class="ruby-identifier">rep</span>) }
|
510
|
+
<span class="ruby-keyword kw">end</span>
|
511
|
+
</pre>
|
512
|
+
</div>
|
513
|
+
</div>
|
514
|
+
</div>
|
515
|
+
|
516
|
+
<div id="method-M000340" class="method-detail">
|
517
|
+
<a name="M000340"></a>
|
518
|
+
|
519
|
+
<div class="method-heading">
|
520
|
+
<a href="#M000340" class="method-signature">
|
521
|
+
<span class="method-name">gsub!</span><span class="method-args">(pat, rep)</span>
|
522
|
+
</a>
|
523
|
+
</div>
|
524
|
+
|
525
|
+
<div class="method-description">
|
526
|
+
<p>
|
527
|
+
Same as <tt>gsub</tt> except that the original file list is modified.
|
528
|
+
</p>
|
529
|
+
<p><a class="source-toggle" href="#"
|
530
|
+
onclick="toggleCode('M000340-source');return false;">[Source]</a></p>
|
531
|
+
<div class="method-source-code" id="M000340-source">
|
532
|
+
<pre>
|
533
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 211</span>
|
534
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">gsub!</span>(<span class="ruby-identifier">pat</span>, <span class="ruby-identifier">rep</span>)
|
535
|
+
<span class="ruby-identifier">each_with_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span>, <span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-keyword kw">self</span>[<span class="ruby-identifier">i</span>] = <span class="ruby-identifier">fn</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-identifier">pat</span>,<span class="ruby-identifier">rep</span>) }
|
536
|
+
<span class="ruby-keyword kw">self</span>
|
537
|
+
<span class="ruby-keyword kw">end</span>
|
538
|
+
</pre>
|
539
|
+
</div>
|
540
|
+
</div>
|
541
|
+
</div>
|
542
|
+
|
543
|
+
<div id="method-M000329" class="method-detail">
|
544
|
+
<a name="M000329"></a>
|
545
|
+
|
546
|
+
<div class="method-heading">
|
547
|
+
<a href="#M000329" class="method-signature">
|
548
|
+
<span class="method-name">include</span><span class="method-args">(*filenames)</span>
|
549
|
+
</a>
|
550
|
+
</div>
|
551
|
+
|
552
|
+
<div class="method-description">
|
553
|
+
<p>
|
554
|
+
Add file names defined by glob patterns to the file list. If an array is
|
555
|
+
given, add each element of the array.
|
556
|
+
</p>
|
557
|
+
<p>
|
558
|
+
Example:
|
559
|
+
</p>
|
560
|
+
<pre>
|
561
|
+
file_list.include("*.java", "*.cfg")
|
562
|
+
file_list.include %w( math.c lib.h *.o )
|
563
|
+
</pre>
|
564
|
+
<p><a class="source-toggle" href="#"
|
565
|
+
onclick="toggleCode('M000329-source');return false;">[Source]</a></p>
|
566
|
+
<div class="method-source-code" id="M000329-source">
|
567
|
+
<pre>
|
568
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 75</span>
|
569
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">include</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">filenames</span>)
|
570
|
+
<span class="ruby-comment cmt"># TODO: check for pending</span>
|
571
|
+
<span class="ruby-identifier">filenames</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@pending_add</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">fn</span> <span class="ruby-keyword kw">end</span>
|
572
|
+
<span class="ruby-ivar">@pending</span> = <span class="ruby-keyword kw">true</span>
|
573
|
+
<span class="ruby-keyword kw">self</span>
|
574
|
+
<span class="ruby-keyword kw">end</span>
|
575
|
+
</pre>
|
576
|
+
</div>
|
577
|
+
</div>
|
578
|
+
</div>
|
579
|
+
|
580
|
+
<div id="method-M000333" class="method-detail">
|
581
|
+
<a name="M000333"></a>
|
582
|
+
|
583
|
+
<div class="method-heading">
|
584
|
+
<a href="#M000333" class="method-signature">
|
585
|
+
<span class="method-name">resolve</span><span class="method-args">()</span>
|
586
|
+
</a>
|
587
|
+
</div>
|
588
|
+
|
589
|
+
<div class="method-description">
|
590
|
+
<p>
|
591
|
+
Resolve all the pending adds now.
|
592
|
+
</p>
|
593
|
+
<p><a class="source-toggle" href="#"
|
594
|
+
onclick="toggleCode('M000333-source');return false;">[Source]</a></p>
|
595
|
+
<div class="method-source-code" id="M000333-source">
|
596
|
+
<pre>
|
597
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 127</span>
|
598
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">resolve</span>
|
599
|
+
<span class="ruby-ivar">@pending</span> = <span class="ruby-keyword kw">false</span>
|
600
|
+
<span class="ruby-ivar">@pending_add</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">resolve_add</span>(<span class="ruby-identifier">fn</span>) <span class="ruby-keyword kw">end</span>
|
601
|
+
<span class="ruby-ivar">@pending_add</span> = []
|
602
|
+
<span class="ruby-identifier">resolve_exclude</span>
|
603
|
+
<span class="ruby-keyword kw">self</span>
|
604
|
+
<span class="ruby-keyword kw">end</span>
|
605
|
+
</pre>
|
606
|
+
</div>
|
607
|
+
</div>
|
608
|
+
</div>
|
609
|
+
|
610
|
+
<div id="method-M000335" class="method-detail">
|
611
|
+
<a name="M000335"></a>
|
612
|
+
|
613
|
+
<div class="method-heading">
|
614
|
+
<a href="#M000335" class="method-signature">
|
615
|
+
<span class="method-name">resolve_add</span><span class="method-args">(fn)</span>
|
616
|
+
</a>
|
617
|
+
</div>
|
618
|
+
|
619
|
+
<div class="method-description">
|
620
|
+
<p><a class="source-toggle" href="#"
|
621
|
+
onclick="toggleCode('M000335-source');return false;">[Source]</a></p>
|
622
|
+
<div class="method-source-code" id="M000335-source">
|
623
|
+
<pre>
|
624
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 155</span>
|
625
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">resolve_add</span>(<span class="ruby-identifier">fn</span>)
|
626
|
+
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">fn</span>
|
627
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">NilClass</span>
|
628
|
+
<span class="ruby-comment cmt"># ignore</span>
|
629
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">Array</span>
|
630
|
+
<span class="ruby-identifier">fn</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">resolve_add</span>(<span class="ruby-identifier">f</span>) }
|
631
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-regexp re">%r{[*?]}</span>
|
632
|
+
<span class="ruby-identifier">add_matching</span>(<span class="ruby-identifier">fn</span>)
|
633
|
+
<span class="ruby-keyword kw">else</span>
|
634
|
+
<span class="ruby-keyword kw">self</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">fn</span> <span class="ruby-keyword kw">if</span> <span class="ruby-constant">FileTest</span>.<span class="ruby-identifier">exists?</span>( <span class="ruby-identifier">fn</span> )
|
635
|
+
<span class="ruby-keyword kw">end</span>
|
636
|
+
<span class="ruby-keyword kw">end</span>
|
637
|
+
</pre>
|
638
|
+
</div>
|
639
|
+
</div>
|
640
|
+
</div>
|
641
|
+
|
642
|
+
<div id="method-M000336" class="method-detail">
|
643
|
+
<a name="M000336"></a>
|
644
|
+
|
645
|
+
<div class="method-heading">
|
646
|
+
<a href="#M000336" class="method-signature">
|
647
|
+
<span class="method-name">resolve_exclude</span><span class="method-args">()</span>
|
648
|
+
</a>
|
649
|
+
</div>
|
650
|
+
|
651
|
+
<div class="method-description">
|
652
|
+
<p><a class="source-toggle" href="#"
|
653
|
+
onclick="toggleCode('M000336-source');return false;">[Source]</a></p>
|
654
|
+
<div class="method-source-code" id="M000336-source">
|
655
|
+
<pre>
|
656
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 168</span>
|
657
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">resolve_exclude</span>
|
658
|
+
<span class="ruby-ivar">@exclude_patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pat</span><span class="ruby-operator">|</span>
|
659
|
+
<span class="ruby-keyword kw">case</span> <span class="ruby-identifier">pat</span>
|
660
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-constant">Regexp</span>
|
661
|
+
<span class="ruby-identifier">reject!</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">fn</span> <span class="ruby-operator">=~</span> <span class="ruby-identifier">pat</span> }
|
662
|
+
<span class="ruby-keyword kw">when</span> <span class="ruby-regexp re">/[*.]/</span>
|
663
|
+
<span class="ruby-identifier">reject_list</span> = <span class="ruby-constant">Dir</span>[<span class="ruby-identifier">pat</span>]
|
664
|
+
<span class="ruby-identifier">reject!</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">reject_list</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">fn</span>) }
|
665
|
+
<span class="ruby-keyword kw">else</span>
|
666
|
+
<span class="ruby-identifier">reject!</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">fn</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">pat</span> }
|
667
|
+
<span class="ruby-keyword kw">end</span>
|
668
|
+
<span class="ruby-keyword kw">end</span>
|
669
|
+
<span class="ruby-keyword kw">self</span>
|
670
|
+
<span class="ruby-keyword kw">end</span>
|
671
|
+
</pre>
|
672
|
+
</div>
|
673
|
+
</div>
|
674
|
+
</div>
|
675
|
+
|
676
|
+
<div id="method-M000337" class="method-detail">
|
677
|
+
<a name="M000337"></a>
|
678
|
+
|
679
|
+
<div class="method-heading">
|
680
|
+
<a href="#M000337" class="method-signature">
|
681
|
+
<span class="method-name">sub</span><span class="method-args">(pat, rep)</span>
|
682
|
+
</a>
|
683
|
+
</div>
|
684
|
+
|
685
|
+
<div class="method-description">
|
686
|
+
<p>
|
687
|
+
Return a new <a href="FileList.html">FileList</a> with the results of
|
688
|
+
running <tt>sub</tt> against each element of the oringal list.
|
689
|
+
</p>
|
690
|
+
<p>
|
691
|
+
Example:
|
692
|
+
</p>
|
693
|
+
<pre>
|
694
|
+
FileList['a.c', 'b.c'].sub(/\.c$/, '.o') => ['a.o', 'b.o']
|
695
|
+
</pre>
|
696
|
+
<p><a class="source-toggle" href="#"
|
697
|
+
onclick="toggleCode('M000337-source');return false;">[Source]</a></p>
|
698
|
+
<div class="method-source-code" id="M000337-source">
|
699
|
+
<pre>
|
700
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 189</span>
|
701
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">sub</span>(<span class="ruby-identifier">pat</span>, <span class="ruby-identifier">rep</span>)
|
702
|
+
<span class="ruby-identifier">inject</span>(<span class="ruby-constant">FileList</span>.<span class="ruby-identifier">new</span>) { <span class="ruby-operator">|</span><span class="ruby-identifier">res</span>, <span class="ruby-identifier">fn</span><span class="ruby-operator">|</span> <span class="ruby-identifier">res</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">fn</span>.<span class="ruby-identifier">sub</span>(<span class="ruby-identifier">pat</span>,<span class="ruby-identifier">rep</span>) }
|
703
|
+
<span class="ruby-keyword kw">end</span>
|
704
|
+
</pre>
|
705
|
+
</div>
|
706
|
+
</div>
|
707
|
+
</div>
|
708
|
+
|
709
|
+
<div id="method-M000339" class="method-detail">
|
710
|
+
<a name="M000339"></a>
|
711
|
+
|
712
|
+
<div class="method-heading">
|
713
|
+
<a href="#M000339" class="method-signature">
|
714
|
+
<span class="method-name">sub!</span><span class="method-args">(pat, rep)</span>
|
715
|
+
</a>
|
716
|
+
</div>
|
717
|
+
|
718
|
+
<div class="method-description">
|
719
|
+
<p>
|
720
|
+
Same as <tt>sub</tt> except that the oringal file list is modified.
|
721
|
+
</p>
|
722
|
+
<p><a class="source-toggle" href="#"
|
723
|
+
onclick="toggleCode('M000339-source');return false;">[Source]</a></p>
|
724
|
+
<div class="method-source-code" id="M000339-source">
|
725
|
+
<pre>
|
726
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 205</span>
|
727
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">sub!</span>(<span class="ruby-identifier">pat</span>, <span class="ruby-identifier">rep</span>)
|
728
|
+
<span class="ruby-identifier">each_with_index</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span>, <span class="ruby-identifier">i</span><span class="ruby-operator">|</span> <span class="ruby-keyword kw">self</span>[<span class="ruby-identifier">i</span>] = <span class="ruby-identifier">fn</span>.<span class="ruby-identifier">sub</span>(<span class="ruby-identifier">pat</span>,<span class="ruby-identifier">rep</span>) }
|
729
|
+
<span class="ruby-keyword kw">self</span>
|
730
|
+
<span class="ruby-keyword kw">end</span>
|
731
|
+
</pre>
|
732
|
+
</div>
|
733
|
+
</div>
|
734
|
+
</div>
|
735
|
+
|
736
|
+
<div id="method-M000341" class="method-detail">
|
737
|
+
<a name="M000341"></a>
|
738
|
+
|
739
|
+
<div class="method-heading">
|
740
|
+
<a href="#M000341" class="method-signature">
|
741
|
+
<span class="method-name">to_s</span><span class="method-args">()</span>
|
742
|
+
</a>
|
743
|
+
</div>
|
744
|
+
|
745
|
+
<div class="method-description">
|
746
|
+
<p>
|
747
|
+
Convert a <a href="FileList.html">FileList</a> to a string by joining all
|
748
|
+
elements with a space.
|
749
|
+
</p>
|
750
|
+
<p><a class="source-toggle" href="#"
|
751
|
+
onclick="toggleCode('M000341-source');return false;">[Source]</a></p>
|
752
|
+
<div class="method-source-code" id="M000341-source">
|
753
|
+
<pre>
|
754
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 217</span>
|
755
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_s</span>
|
756
|
+
<span class="ruby-identifier">resolve</span>
|
757
|
+
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">' '</span>)
|
758
|
+
<span class="ruby-keyword kw">end</span>
|
759
|
+
</pre>
|
760
|
+
</div>
|
761
|
+
</div>
|
762
|
+
</div>
|
763
|
+
|
764
|
+
<div id="method-M000342" class="method-detail">
|
765
|
+
<a name="M000342"></a>
|
766
|
+
|
767
|
+
<div class="method-heading">
|
768
|
+
<a href="#M000342" class="method-signature">
|
769
|
+
<span class="method-name">to_str</span><span class="method-args">()</span>
|
770
|
+
</a>
|
771
|
+
</div>
|
772
|
+
|
773
|
+
<div class="method-description">
|
774
|
+
<p>
|
775
|
+
Convert a <a href="FileList.html">FileList</a> to a string prior to
|
776
|
+
resolving.
|
777
|
+
</p>
|
778
|
+
<p><a class="source-toggle" href="#"
|
779
|
+
onclick="toggleCode('M000342-source');return false;">[Source]</a></p>
|
780
|
+
<div class="method-source-code" id="M000342-source">
|
781
|
+
<pre>
|
782
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 223</span>
|
783
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_str</span>
|
784
|
+
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">' '</span>)
|
785
|
+
<span class="ruby-keyword kw">end</span>
|
786
|
+
</pre>
|
787
|
+
</div>
|
788
|
+
</div>
|
789
|
+
</div>
|
790
|
+
|
791
|
+
<h3 class="section-bar">Private Instance methods</h3>
|
792
|
+
|
793
|
+
<div id="method-M000343" class="method-detail">
|
794
|
+
<a name="M000343"></a>
|
795
|
+
|
796
|
+
<div class="method-heading">
|
797
|
+
<a href="#M000343" class="method-signature">
|
798
|
+
<span class="method-name">add_matching</span><span class="method-args">(pattern)</span>
|
799
|
+
</a>
|
800
|
+
</div>
|
801
|
+
|
802
|
+
<div class="method-description">
|
803
|
+
<p>
|
804
|
+
Add matching glob patterns.
|
805
|
+
</p>
|
806
|
+
<p><a class="source-toggle" href="#"
|
807
|
+
onclick="toggleCode('M000343-source');return false;">[Source]</a></p>
|
808
|
+
<div class="method-source-code" id="M000343-source">
|
809
|
+
<pre>
|
810
|
+
<span class="ruby-comment cmt"># File lib/carat/filelist.rb, line 228</span>
|
811
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_matching</span>(<span class="ruby-identifier">pattern</span>)
|
812
|
+
<span class="ruby-constant">Dir</span>[<span class="ruby-identifier">pattern</span>].<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">fn</span><span class="ruby-operator">|</span>
|
813
|
+
<span class="ruby-keyword kw">self</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">fn</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">exclude?</span>(<span class="ruby-identifier">fn</span>)
|
814
|
+
<span class="ruby-keyword kw">end</span>
|
815
|
+
<span class="ruby-keyword kw">end</span>
|
816
|
+
</pre>
|
817
|
+
</div>
|
818
|
+
</div>
|
819
|
+
</div>
|
820
|
+
|
821
|
+
|
822
|
+
</div>
|
823
|
+
|
824
|
+
|
825
|
+
</div>
|
826
|
+
|
827
|
+
|
828
|
+
<div id="validator-badges">
|
829
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
830
|
+
</div>
|
831
|
+
|
832
|
+
</body>
|
833
|
+
</html>
|