From 494dc53ebd515b1e3e9b91bbebf43059899ca4ce Mon Sep 17 00:00:00 2001 From: martinahansen Date: Fri, 13 May 2011 19:46:09 +0000 Subject: [PATCH] changed layout of ruby source git-svn-id: http://biopieces.googlecode.com/svn/trunk@1405 74ccb610-7750-0410-82ae-013aeee3265d --- bp_bin/analyze_assembly | 6 +- bp_bin/analyze_seq | 4 +- bp_bin/assemble_seq_idba | 4 +- bp_bin/assemble_seq_velvet | 4 +- bp_bin/bin_vals | 2 +- bp_bin/calc_N50 | 2 +- bp_bin/clip_adaptor | 2 +- bp_bin/clip_seq | 2 +- bp_bin/digest_seq | 6 +- bp_bin/find_adaptor | 4 +- bp_bin/find_genes | 6 +- bp_bin/find_homopolymers | 4 +- bp_bin/find_mids | 2 +- bp_bin/join_seq | 6 +- bp_bin/kmer_freq | 4 +- bp_bin/length_seq | 2 +- bp_bin/mask_seq | 2 +- bp_bin/pcr_seq | 6 +- bp_bin/plot_scores | 2 +- bp_bin/progress_meter | 2 +- bp_bin/read_fasta | 4 +- bp_bin/read_fastq | 4 +- bp_bin/read_genbank | 4 +- bp_bin/read_sff | 4 +- bp_bin/remove_mids | 2 +- bp_bin/scores_to_dec | 2 +- bp_bin/shred_seq | 4 +- bp_bin/shuffle_records | 2 +- bp_bin/swapcase_seq | 2 +- bp_bin/uclust_seq | 4 +- bp_conf/bashrc | 2 +- code_ruby/Maasha/Rakefile | 6 - code_ruby/Maasha/lib/doc/Base36.html | 316 --- code_ruby/Maasha/lib/doc/Base36Error.html | 200 -- code_ruby/Maasha/lib/doc/Biopieces.html | 562 ----- code_ruby/Maasha/lib/doc/BitArray.html | 869 -------- code_ruby/Maasha/lib/doc/BitArrayError.html | 201 -- code_ruby/Maasha/lib/doc/Boulder.html | 361 ---- code_ruby/Maasha/lib/doc/BoulderError.html | 201 -- code_ruby/Maasha/lib/doc/CastError.html | 200 -- code_ruby/Maasha/lib/doc/Casts.html | 823 -------- code_ruby/Maasha/lib/doc/Digest.html | 416 ---- code_ruby/Maasha/lib/doc/DigestError.html | 200 -- code_ruby/Maasha/lib/doc/Fasta.html | 308 --- code_ruby/Maasha/lib/doc/FastaError.html | 200 -- code_ruby/Maasha/lib/doc/Fastq.html | 306 --- code_ruby/Maasha/lib/doc/FastqError.html | 200 -- code_ruby/Maasha/lib/doc/Filesys.html | 452 ---- code_ruby/Maasha/lib/doc/FilesysError.html | 201 -- code_ruby/Maasha/lib/doc/Genbank.html | 521 ----- code_ruby/Maasha/lib/doc/GenbankError.html | 201 -- code_ruby/Maasha/lib/doc/GenbankFeatures.html | 473 ----- code_ruby/Maasha/lib/doc/Locator.html | 586 ------ code_ruby/Maasha/lib/doc/LocatorError.html | 201 -- code_ruby/Maasha/lib/doc/OptionHandler.html | 1028 ---------- code_ruby/Maasha/lib/doc/Read.html | 646 ------ code_ruby/Maasha/lib/doc/SFF.html | 712 ------- code_ruby/Maasha/lib/doc/SFFError.html | 200 -- code_ruby/Maasha/lib/doc/Seq.html | 1825 ----------------- code_ruby/Maasha/lib/doc/SeqError.html | 200 -- code_ruby/Maasha/lib/doc/Status.html | 524 ----- code_ruby/Maasha/lib/doc/Stream.html | 557 ----- code_ruby/Maasha/lib/doc/String.html | 408 ---- code_ruby/Maasha/lib/doc/StringError.html | 200 -- code_ruby/Maasha/lib/doc/base36_rb.html | 55 - code_ruby/Maasha/lib/doc/biopieces_rb.html | 62 - code_ruby/Maasha/lib/doc/bitarray_rb.html | 55 - code_ruby/Maasha/lib/doc/bits_rb.html | 55 - code_ruby/Maasha/lib/doc/boulder_rb.html | 57 - .../Maasha/lib/doc/classes/Biopieces.html | 301 --- .../doc/classes/Biopieces.src/M000001.html | 19 - .../doc/classes/Biopieces.src/M000002.html | 17 - .../doc/classes/Biopieces.src/M000003.html | 34 - .../doc/classes/Biopieces.src/M000005.html | 21 - .../doc/classes/Biopieces.src/M000006.html | 21 - .../Maasha/lib/doc/classes/CastError.html | 117 -- code_ruby/Maasha/lib/doc/classes/Casts.html | 187 -- .../lib/doc/classes/Casts.src/M000007.html | 18 - code_ruby/Maasha/lib/doc/classes/Fasta.html | 266 --- .../lib/doc/classes/Fasta.src/M000031.html | 28 - .../lib/doc/classes/Fasta.src/M000032.html | 16 - .../lib/doc/classes/Fasta.src/M000033.html | 17 - .../lib/doc/classes/Fasta.src/M000034.html | 32 - .../Maasha/lib/doc/classes/FastaError.html | 117 -- .../Maasha/lib/doc/classes/OptionHandler.html | 615 ------ .../classes/OptionHandler.src/M000008.html | 18 - .../classes/OptionHandler.src/M000009.html | 58 - .../classes/OptionHandler.src/M000010.html | 17 - .../classes/OptionHandler.src/M000011.html | 15 - .../classes/OptionHandler.src/M000012.html | 25 - .../classes/OptionHandler.src/M000013.html | 27 - .../classes/OptionHandler.src/M000014.html | 19 - .../classes/OptionHandler.src/M000015.html | 33 - .../classes/OptionHandler.src/M000016.html | 24 - .../classes/OptionHandler.src/M000017.html | 17 - .../classes/OptionHandler.src/M000018.html | 19 - .../classes/OptionHandler.src/M000019.html | 19 - .../classes/OptionHandler.src/M000020.html | 17 - .../classes/OptionHandler.src/M000021.html | 19 - .../classes/OptionHandler.src/M000022.html | 17 - .../classes/OptionHandler.src/M000023.html | 20 - .../classes/OptionHandler.src/M000024.html | 19 - code_ruby/Maasha/lib/doc/classes/Seq.html | 412 ---- .../lib/doc/classes/Seq.src/M000001.html | 15 - .../lib/doc/classes/Seq.src/M000003.html | 15 - .../lib/doc/classes/Seq.src/M000004.html | 15 - .../lib/doc/classes/Seq.src/M000005.html | 15 - .../lib/doc/classes/Seq.src/M000006.html | 18 - .../lib/doc/classes/Seq.src/M000007.html | 18 - .../lib/doc/classes/Seq.src/M000008.html | 23 - .../lib/doc/classes/Seq.src/M000009.html | 32 - .../lib/doc/classes/Seq.src/M000031.html | 25 - .../lib/doc/classes/Seq.src/M000032.html | 18 - .../lib/doc/classes/Seq.src/M000033.html | 15 - .../lib/doc/classes/Seq.src/M000034.html | 18 - .../lib/doc/classes/Seq.src/M000035.html | 15 - .../lib/doc/classes/Seq.src/M000037.html | 15 - .../lib/doc/classes/Seq.src/M000038.html | 15 - .../lib/doc/classes/Seq.src/M000039.html | 15 - .../lib/doc/classes/Seq.src/M000040.html | 18 - .../lib/doc/classes/Seq.src/M000041.html | 18 - .../lib/doc/classes/Seq.src/M000042.html | 21 - .../lib/doc/classes/Seq.src/M000043.html | 23 - .../lib/doc/classes/Seq.src/M000044.html | 31 - code_ruby/Maasha/lib/doc/classes/Seq/AA.html | 193 -- .../lib/doc/classes/Seq/AA.src/M000036.html | 15 - .../lib/doc/classes/Seq/AA.src/M000037.html | 44 - code_ruby/Maasha/lib/doc/classes/Seq/NA.html | 130 -- .../Maasha/lib/doc/classes/Seq/NA/DNA.html | 217 -- .../doc/classes/Seq/NA/DNA.src/M000038.html | 15 - .../doc/classes/Seq/NA/DNA.src/M000039.html | 15 - .../doc/classes/Seq/NA/DNA.src/M000040.html | 15 - .../Maasha/lib/doc/classes/Seq/NA/RNA.html | 217 -- .../doc/classes/Seq/NA/RNA.src/M000041.html | 15 - .../doc/classes/Seq/NA/RNA.src/M000042.html | 15 - .../doc/classes/Seq/NA/RNA.src/M000043.html | 15 - .../Maasha/lib/doc/classes/SeqError.html | 117 -- code_ruby/Maasha/lib/doc/classes/Status.html | 268 --- .../lib/doc/classes/Status.src/M000025.html | 19 - .../lib/doc/classes/Status.src/M000026.html | 21 - .../lib/doc/classes/Status.src/M000027.html | 20 - .../lib/doc/classes/Status.src/M000028.html | 27 - .../lib/doc/classes/Status.src/M000029.html | 15 - code_ruby/Maasha/lib/doc/classes/Stream.html | 154 -- .../lib/doc/classes/Stream.src/M000030.html | 21 - code_ruby/Maasha/lib/doc/created.rid | 13 - code_ruby/Maasha/lib/doc/digest_rb.html | 57 - code_ruby/Maasha/lib/doc/fasta_rb.html | 59 - code_ruby/Maasha/lib/doc/fastq_rb.html | 59 - .../Maasha/lib/doc/files/biopieces_rb.html | 115 -- code_ruby/Maasha/lib/doc/files/fasta_rb.html | 112 - code_ruby/Maasha/lib/doc/files/seq_rb.html | 121 -- code_ruby/Maasha/lib/doc/filesys_rb.html | 57 - code_ruby/Maasha/lib/doc/fr_class_index.html | 27 - code_ruby/Maasha/lib/doc/fr_file_index.html | 25 - code_ruby/Maasha/lib/doc/fr_method_index.html | 33 - code_ruby/Maasha/lib/doc/genbank_rb.html | 59 - code_ruby/Maasha/lib/doc/images/brick.png | Bin 452 -> 0 bytes .../Maasha/lib/doc/images/brick_link.png | Bin 764 -> 0 bytes code_ruby/Maasha/lib/doc/images/bug.png | Bin 774 -> 0 bytes .../Maasha/lib/doc/images/bullet_black.png | Bin 211 -> 0 bytes .../lib/doc/images/bullet_toggle_minus.png | Bin 207 -> 0 bytes .../lib/doc/images/bullet_toggle_plus.png | Bin 209 -> 0 bytes code_ruby/Maasha/lib/doc/images/date.png | Bin 626 -> 0 bytes code_ruby/Maasha/lib/doc/images/find.png | Bin 659 -> 0 bytes .../lib/doc/images/loadingAnimation.gif | Bin 5886 -> 0 bytes .../Maasha/lib/doc/images/macFFBgHack.png | Bin 207 -> 0 bytes code_ruby/Maasha/lib/doc/images/package.png | Bin 853 -> 0 bytes .../Maasha/lib/doc/images/page_green.png | Bin 621 -> 0 bytes .../Maasha/lib/doc/images/page_white_text.png | Bin 342 -> 0 bytes .../lib/doc/images/page_white_width.png | Bin 309 -> 0 bytes code_ruby/Maasha/lib/doc/images/plugin.png | Bin 591 -> 0 bytes code_ruby/Maasha/lib/doc/images/ruby.png | Bin 592 -> 0 bytes code_ruby/Maasha/lib/doc/images/tag_green.png | Bin 613 -> 0 bytes code_ruby/Maasha/lib/doc/images/wrench.png | Bin 610 -> 0 bytes .../Maasha/lib/doc/images/wrench_orange.png | Bin 584 -> 0 bytes code_ruby/Maasha/lib/doc/images/zoom.png | Bin 692 -> 0 bytes code_ruby/Maasha/lib/doc/index.html | 417 ---- code_ruby/Maasha/lib/doc/js/darkfish.js | 116 -- code_ruby/Maasha/lib/doc/js/jquery.js | 32 - code_ruby/Maasha/lib/doc/js/quicksearch.js | 114 - .../Maasha/lib/doc/js/thickbox-compressed.js | 10 - code_ruby/Maasha/lib/doc/rdoc-style.css | 299 --- code_ruby/Maasha/lib/doc/rdoc.css | 706 ------- code_ruby/Maasha/lib/doc/seq_rb.html | 59 - code_ruby/Maasha/lib/doc/sff_rb.html | 57 - code_ruby/Sfern/test_module.rb | 7 - .../{Maasha/lib => lib/maasha}/base36.rb | 0 .../{Maasha/lib => lib/maasha}/biopieces.rb | 0 .../{Maasha/lib => lib/maasha}/bitarray.rb | 0 code_ruby/{Maasha/lib => lib/maasha}/bits.rb | 0 code_ruby/lib/maasha/boulder.rb | 78 + .../{Maasha/lib => lib/maasha}/digest.rb | 0 code_ruby/{Maasha/lib => lib/maasha}/fasta.rb | 4 +- code_ruby/{Maasha/lib => lib/maasha}/fastq.rb | 4 +- .../{Maasha/lib => lib/maasha}/filesys.rb | 0 .../{Maasha/lib => lib/maasha}/genbank.rb | 4 +- .../{Maasha/lib => lib/maasha}/patscan.rb | 2 +- .../lib => lib/maasha}/patternmatcher.rb | 0 .../{Maasha/lib => lib/maasha}/prodigal.rb | 2 +- code_ruby/{Maasha/lib => lib/maasha}/seq.rb | 6 +- code_ruby/{Maasha/lib => lib/maasha}/sff.rb | 2 +- .../test => test/maasha}/test_base36.rb | 2 +- .../test => test/maasha}/test_biopieces.rb | 3 +- .../test => test/maasha}/test_bitarray.rb | 2 +- .../{Maasha/test => test/maasha}/test_bits.rb | 2 +- code_ruby/test/maasha/test_boulder.rb | 75 + .../test => test/maasha}/test_digest.rb | 2 +- .../test => test/maasha}/test_fasta.rb | 2 +- .../test => test/maasha}/test_fastq.rb | 2 +- .../test => test/maasha}/test_genbank.rb | 4 +- .../maasha}/test_patternmatcher.rb | 2 +- .../{Maasha/test => test/maasha}/test_seq.rb | 2 +- 213 files changed, 230 insertions(+), 21805 deletions(-) delete mode 100644 code_ruby/Maasha/Rakefile delete mode 100644 code_ruby/Maasha/lib/doc/Base36.html delete mode 100644 code_ruby/Maasha/lib/doc/Base36Error.html delete mode 100644 code_ruby/Maasha/lib/doc/Biopieces.html delete mode 100644 code_ruby/Maasha/lib/doc/BitArray.html delete mode 100644 code_ruby/Maasha/lib/doc/BitArrayError.html delete mode 100644 code_ruby/Maasha/lib/doc/Boulder.html delete mode 100644 code_ruby/Maasha/lib/doc/BoulderError.html delete mode 100644 code_ruby/Maasha/lib/doc/CastError.html delete mode 100644 code_ruby/Maasha/lib/doc/Casts.html delete mode 100644 code_ruby/Maasha/lib/doc/Digest.html delete mode 100644 code_ruby/Maasha/lib/doc/DigestError.html delete mode 100644 code_ruby/Maasha/lib/doc/Fasta.html delete mode 100644 code_ruby/Maasha/lib/doc/FastaError.html delete mode 100644 code_ruby/Maasha/lib/doc/Fastq.html delete mode 100644 code_ruby/Maasha/lib/doc/FastqError.html delete mode 100644 code_ruby/Maasha/lib/doc/Filesys.html delete mode 100644 code_ruby/Maasha/lib/doc/FilesysError.html delete mode 100644 code_ruby/Maasha/lib/doc/Genbank.html delete mode 100644 code_ruby/Maasha/lib/doc/GenbankError.html delete mode 100644 code_ruby/Maasha/lib/doc/GenbankFeatures.html delete mode 100644 code_ruby/Maasha/lib/doc/Locator.html delete mode 100644 code_ruby/Maasha/lib/doc/LocatorError.html delete mode 100644 code_ruby/Maasha/lib/doc/OptionHandler.html delete mode 100644 code_ruby/Maasha/lib/doc/Read.html delete mode 100644 code_ruby/Maasha/lib/doc/SFF.html delete mode 100644 code_ruby/Maasha/lib/doc/SFFError.html delete mode 100644 code_ruby/Maasha/lib/doc/Seq.html delete mode 100644 code_ruby/Maasha/lib/doc/SeqError.html delete mode 100644 code_ruby/Maasha/lib/doc/Status.html delete mode 100644 code_ruby/Maasha/lib/doc/Stream.html delete mode 100644 code_ruby/Maasha/lib/doc/String.html delete mode 100644 code_ruby/Maasha/lib/doc/StringError.html delete mode 100644 code_ruby/Maasha/lib/doc/base36_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/biopieces_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/bitarray_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/bits_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/boulder_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000001.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000002.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000003.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000005.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000006.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/CastError.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Casts.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Casts.src/M000007.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Fasta.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Fasta.src/M000031.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Fasta.src/M000032.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Fasta.src/M000033.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Fasta.src/M000034.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/FastaError.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000008.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000009.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000010.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000011.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000012.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000013.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000014.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000015.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000016.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000017.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000018.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000019.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000020.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000021.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000022.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000023.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000024.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000001.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000003.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000004.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000005.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000006.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000007.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000008.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000009.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000031.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000032.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000033.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000034.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000035.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000037.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000038.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000039.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000040.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000041.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000042.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000043.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq.src/M000044.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/AA.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000036.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000037.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000038.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000039.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000040.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000041.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000042.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000043.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/SeqError.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.src/M000025.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.src/M000026.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.src/M000027.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.src/M000028.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Status.src/M000029.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Stream.html delete mode 100644 code_ruby/Maasha/lib/doc/classes/Stream.src/M000030.html delete mode 100644 code_ruby/Maasha/lib/doc/created.rid delete mode 100644 code_ruby/Maasha/lib/doc/digest_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/fasta_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/fastq_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/files/biopieces_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/files/fasta_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/files/seq_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/filesys_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/fr_class_index.html delete mode 100644 code_ruby/Maasha/lib/doc/fr_file_index.html delete mode 100644 code_ruby/Maasha/lib/doc/fr_method_index.html delete mode 100644 code_ruby/Maasha/lib/doc/genbank_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/images/brick.png delete mode 100644 code_ruby/Maasha/lib/doc/images/brick_link.png delete mode 100644 code_ruby/Maasha/lib/doc/images/bug.png delete mode 100644 code_ruby/Maasha/lib/doc/images/bullet_black.png delete mode 100644 code_ruby/Maasha/lib/doc/images/bullet_toggle_minus.png delete mode 100644 code_ruby/Maasha/lib/doc/images/bullet_toggle_plus.png delete mode 100644 code_ruby/Maasha/lib/doc/images/date.png delete mode 100644 code_ruby/Maasha/lib/doc/images/find.png delete mode 100644 code_ruby/Maasha/lib/doc/images/loadingAnimation.gif delete mode 100644 code_ruby/Maasha/lib/doc/images/macFFBgHack.png delete mode 100644 code_ruby/Maasha/lib/doc/images/package.png delete mode 100644 code_ruby/Maasha/lib/doc/images/page_green.png delete mode 100644 code_ruby/Maasha/lib/doc/images/page_white_text.png delete mode 100644 code_ruby/Maasha/lib/doc/images/page_white_width.png delete mode 100644 code_ruby/Maasha/lib/doc/images/plugin.png delete mode 100644 code_ruby/Maasha/lib/doc/images/ruby.png delete mode 100644 code_ruby/Maasha/lib/doc/images/tag_green.png delete mode 100644 code_ruby/Maasha/lib/doc/images/wrench.png delete mode 100644 code_ruby/Maasha/lib/doc/images/wrench_orange.png delete mode 100644 code_ruby/Maasha/lib/doc/images/zoom.png delete mode 100644 code_ruby/Maasha/lib/doc/index.html delete mode 100644 code_ruby/Maasha/lib/doc/js/darkfish.js delete mode 100644 code_ruby/Maasha/lib/doc/js/jquery.js delete mode 100644 code_ruby/Maasha/lib/doc/js/quicksearch.js delete mode 100644 code_ruby/Maasha/lib/doc/js/thickbox-compressed.js delete mode 100644 code_ruby/Maasha/lib/doc/rdoc-style.css delete mode 100644 code_ruby/Maasha/lib/doc/rdoc.css delete mode 100644 code_ruby/Maasha/lib/doc/seq_rb.html delete mode 100644 code_ruby/Maasha/lib/doc/sff_rb.html delete mode 100755 code_ruby/Sfern/test_module.rb rename code_ruby/{Maasha/lib => lib/maasha}/base36.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/biopieces.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/bitarray.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/bits.rb (100%) create mode 100644 code_ruby/lib/maasha/boulder.rb rename code_ruby/{Maasha/lib => lib/maasha}/digest.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/fasta.rb (97%) rename code_ruby/{Maasha/lib => lib/maasha}/fastq.rb (97%) rename code_ruby/{Maasha/lib => lib/maasha}/filesys.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/genbank.rb (99%) rename code_ruby/{Maasha/lib => lib/maasha}/patscan.rb (99%) rename code_ruby/{Maasha/lib => lib/maasha}/patternmatcher.rb (100%) rename code_ruby/{Maasha/lib => lib/maasha}/prodigal.rb (99%) rename code_ruby/{Maasha/lib => lib/maasha}/seq.rb (99%) rename code_ruby/{Maasha/lib => lib/maasha}/sff.rb (99%) rename code_ruby/{Maasha/test => test/maasha}/test_base36.rb (98%) rename code_ruby/{Maasha/test => test/maasha}/test_biopieces.rb (99%) rename code_ruby/{Maasha/test => test/maasha}/test_bitarray.rb (99%) rename code_ruby/{Maasha/test => test/maasha}/test_bits.rb (99%) create mode 100755 code_ruby/test/maasha/test_boulder.rb rename code_ruby/{Maasha/test => test/maasha}/test_digest.rb (96%) rename code_ruby/{Maasha/test => test/maasha}/test_fasta.rb (99%) rename code_ruby/{Maasha/test => test/maasha}/test_fastq.rb (98%) rename code_ruby/{Maasha/test => test/maasha}/test_genbank.rb (97%) rename code_ruby/{Maasha/test => test/maasha}/test_patternmatcher.rb (99%) rename code_ruby/{Maasha/test => test/maasha}/test_seq.rb (99%) diff --git a/bp_bin/analyze_assembly b/bp_bin/analyze_assembly index a946d2c..bcc727c 100755 --- a/bp_bin/analyze_assembly +++ b/bp_bin/analyze_assembly @@ -29,9 +29,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' -require 'prodigal' +require 'maasha/biopieces' +require 'maasha/fasta' +require 'maasha/prodigal' require 'pp' casts = [] diff --git a/bp_bin/analyze_seq b/bp_bin/analyze_seq index f79d94a..303d5e4 100755 --- a/bp_bin/analyze_seq +++ b/bp_bin/analyze_seq @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'seq' +require 'maasha/biopieces' +require 'maasha/seq' require 'pp' casts = [] diff --git a/bp_bin/assemble_seq_idba b/bp_bin/assemble_seq_idba index 43434e3..da2f4da 100755 --- a/bp_bin/assemble_seq_idba +++ b/bp_bin/assemble_seq_idba @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' +require 'maasha/biopieces' +require 'maasha/fasta' casts = [] casts << {:long=>'directory', :short=>'d', :type=>'dir', :mandatory=>true, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/assemble_seq_velvet b/bp_bin/assemble_seq_velvet index 85c5fa8..c3e25f3 100755 --- a/bp_bin/assemble_seq_velvet +++ b/bp_bin/assemble_seq_velvet @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' +require 'maasha/biopieces' +require 'maasha/fasta' class Velvet def initialize(directory, sequence_file, verbose) diff --git a/bp_bin/bin_vals b/bp_bin/bin_vals index 42fb7d6..5f1fd05 100755 --- a/bp_bin/bin_vals +++ b/bp_bin/bin_vals @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] casts << {:long=>'key', :short=>'k', :type=>'string', :mandatory=>true, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/calc_N50 b/bp_bin/calc_N50 index a97fe08..38de308 100755 --- a/bp_bin/calc_N50 +++ b/bp_bin/calc_N50 @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' require 'pp' casts = [] diff --git a/bp_bin/clip_adaptor b/bp_bin/clip_adaptor index 4399743..2056f2d 100755 --- a/bp_bin/clip_adaptor +++ b/bp_bin/clip_adaptor @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] diff --git a/bp_bin/clip_seq b/bp_bin/clip_seq index c2f9d8e..f26e10b 100755 --- a/bp_bin/clip_seq +++ b/bp_bin/clip_seq @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] diff --git a/bp_bin/digest_seq b/bp_bin/digest_seq index 9fe81e9..03e8ec9 100755 --- a/bp_bin/digest_seq +++ b/bp_bin/digest_seq @@ -29,9 +29,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' -require 'seq' +require 'maasha/biopieces' +require 'maasha/fasta' +require 'maasha/seq' casts = [] casts << {:long=>'pattern', :short=>'p', :type=>'string', :mandatory=>true, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/find_adaptor b/bp_bin/find_adaptor index e1ac8f3..aa1a014 100755 --- a/bp_bin/find_adaptor +++ b/bp_bin/find_adaptor @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'seq' +require 'maasha/biopieces' +require 'maasha/seq' def disambiguate(adaptor) adaptor_disamb = adaptor.dup diff --git a/bp_bin/find_genes b/bp_bin/find_genes index 367b976..b365ab2 100755 --- a/bp_bin/find_genes +++ b/bp_bin/find_genes @@ -29,9 +29,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' -require 'prodigal' +require 'maasha/biopieces' +require 'maasha/fasta' +require 'maasha/prodigal' casts = [] casts << {:long=>'full', :short=>'f', :type=>'flag', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/find_homopolymers b/bp_bin/find_homopolymers index ba9d639..5c9cd24 100755 --- a/bp_bin/find_homopolymers +++ b/bp_bin/find_homopolymers @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'seq' +require 'maasha/biopieces' +require 'maasha/seq' require 'pp' casts = [] diff --git a/bp_bin/find_mids b/bp_bin/find_mids index 73bbfb6..81015f6 100755 --- a/bp_bin/find_mids +++ b/bp_bin/find_mids @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' require 'pp' MID_LEN = 10 diff --git a/bp_bin/join_seq b/bp_bin/join_seq index 6abc8c8..de80ad2 100755 --- a/bp_bin/join_seq +++ b/bp_bin/join_seq @@ -28,9 +28,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' -require 'seq' +require 'maasha/biopieces' +require 'maasha/fasta' +require 'maasha/seq' casts = [] diff --git a/bp_bin/kmer_freq b/bp_bin/kmer_freq index 733eed3..7e412d8 100755 --- a/bp_bin/kmer_freq +++ b/bp_bin/kmer_freq @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'seq' +require 'maasha/biopieces' +require 'maasha/seq' require 'pp' casts = [] diff --git a/bp_bin/length_seq b/bp_bin/length_seq index e3e6b09..0152ef4 100755 --- a/bp_bin/length_seq +++ b/bp_bin/length_seq @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] diff --git a/bp_bin/mask_seq b/bp_bin/mask_seq index 20395c4..f29b68f 100755 --- a/bp_bin/mask_seq +++ b/bp_bin/mask_seq @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' ILLUMINA_BASE = 64 diff --git a/bp_bin/pcr_seq b/bp_bin/pcr_seq index d3ce39a..df97f20 100755 --- a/bp_bin/pcr_seq +++ b/bp_bin/pcr_seq @@ -29,9 +29,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' -require 'seq' +require 'maasha/biopieces' +require 'maasha/fasta' +require 'maasha/seq' require 'pp' class Pcr diff --git a/bp_bin/plot_scores b/bp_bin/plot_scores index 4ddd7b3..fd44149 100755 --- a/bp_bin/plot_scores +++ b/bp_bin/plot_scores @@ -25,7 +25,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' require 'gnuplot' require 'pp' diff --git a/bp_bin/progress_meter b/bp_bin/progress_meter index b5e0c1c..7678d37 100755 --- a/bp_bin/progress_meter +++ b/bp_bin/progress_meter @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] casts << {:long=>'no_stream', :short => 'x', :type => 'flag', :mandatory => false, :default => nil, :allowed => nil, :disallowed => nil} diff --git a/bp_bin/read_fasta b/bp_bin/read_fasta index c0f9426..9b77008 100755 --- a/bp_bin/read_fasta +++ b/bp_bin/read_fasta @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' +require 'maasha/biopieces' +require 'maasha/fasta' casts = [] casts << {:long=>'data_in', :short=>'i', :type=>'files!', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/read_fastq b/bp_bin/read_fastq index fd88bf0..063edd6 100755 --- a/bp_bin/read_fastq +++ b/bp_bin/read_fastq @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fastq' +require 'maasha/biopieces' +require 'maasha/fastq' casts = [] casts << {:long=>'data_in', :short=>'i', :type=>'files!', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/read_genbank b/bp_bin/read_genbank index 6e471bb..1ab92e4 100755 --- a/bp_bin/read_genbank +++ b/bp_bin/read_genbank @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'genbank' +require 'maasha/biopieces' +require 'maasha/genbank' casts = [] casts << {:long=>'data_in', :short=>'i', :type=>'files!', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/read_sff b/bp_bin/read_sff index a14048e..6e5febd 100755 --- a/bp_bin/read_sff +++ b/bp_bin/read_sff @@ -28,8 +28,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'sff' +require 'maasha/biopieces' +require 'maasha/sff' casts = [] casts << {:long=>'data_in', :short=>'i', :type=>'files!', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil} diff --git a/bp_bin/remove_mids b/bp_bin/remove_mids index c42a6c0..a2d1fd8 100755 --- a/bp_bin/remove_mids +++ b/bp_bin/remove_mids @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' require 'pp' MID_LEN = 10 diff --git a/bp_bin/scores_to_dec b/bp_bin/scores_to_dec index ecf2148..c5e7c1e 100755 --- a/bp_bin/scores_to_dec +++ b/bp_bin/scores_to_dec @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' ILLUMINA_BASE = 64 diff --git a/bp_bin/shred_seq b/bp_bin/shred_seq index f9e1a42..86bf321 100755 --- a/bp_bin/shred_seq +++ b/bp_bin/shred_seq @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'seq' +require 'maasha/biopieces' +require 'maasha/seq' require 'pp' class Seq diff --git a/bp_bin/shuffle_records b/bp_bin/shuffle_records index b132229..194cab0 100755 --- a/bp_bin/shuffle_records +++ b/bp_bin/shuffle_records @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] diff --git a/bp_bin/swapcase_seq b/bp_bin/swapcase_seq index cb1989c..60725f5 100755 --- a/bp_bin/swapcase_seq +++ b/bp_bin/swapcase_seq @@ -29,7 +29,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' +require 'maasha/biopieces' casts = [] diff --git a/bp_bin/uclust_seq b/bp_bin/uclust_seq index cbc0bc6..76c5668 100755 --- a/bp_bin/uclust_seq +++ b/bp_bin/uclust_seq @@ -29,8 +29,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'biopieces' -require 'fasta' +require 'maasha/biopieces' +require 'maasha/fasta' class Uclust include Enumerable diff --git a/bp_conf/bashrc b/bp_conf/bashrc index b5eb789..782195e 100644 --- a/bp_conf/bashrc +++ b/bp_conf/bashrc @@ -32,7 +32,7 @@ export PERL5LIB="$PERL5LIB:$BP_PERL" ### Here we add the Biopieces Ruby libraries to RUBYLIB. -export RUBYLIB="$RUBYLIB:$BP_RUBY/Maasha/lib" +export RUBYLIB="$RUBYLIB:$BP_RUBY/lib" ### Some useful aliases. diff --git a/code_ruby/Maasha/Rakefile b/code_ruby/Maasha/Rakefile deleted file mode 100644 index 8f5b25f..0000000 --- a/code_ruby/Maasha/Rakefile +++ /dev/null @@ -1,6 +0,0 @@ -require 'rake/testtask' - -Rake::TestTask.new("test") do |t| - t.pattern = "test/test_*.rb" - t.warning = true -end diff --git a/code_ruby/Maasha/lib/doc/Base36.html b/code_ruby/Maasha/lib/doc/Base36.html deleted file mode 100644 index c1078ec..0000000 --- a/code_ruby/Maasha/lib/doc/Base36.html +++ /dev/null @@ -1,316 +0,0 @@ - - - - - - - Class: Base36 - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Base36

- -
-

-Class containing methods to encode and decode Base 36. Note that the ALPH -is [alph + num] and not [num + alph] which prevents us from simply using -.to_i(36) and .to_s(36). -

-

-en.wikipedia.org/wiki/Base_36 -

- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - decode(base36) - click to toggle source - -
- -
- -

-Method that decodes a base36 string and returns an integer. -

- - - -
-
-    # File base36.rb, line 55
-55:   def self.decode(base36)
-56:     raise Base36Error if base36.empty?
-57: 
-58:     result = 0
-59:     pos    = 0
-60: 
-61:     base36.upcase.reverse.each_char do |char|
-62:       result += ALPH.index(char) * (BASE36 ** pos)
-63:       pos    += 1
-64:     end
-65: 
-66:     return result;
-67:   end
-
- -
- - - - -
- - -
- - -
- - encode(num) - click to toggle source - -
- -
- -

-Method that encodes an integer into a base36 string that is returned. -

- - - -
-
-    # File base36.rb, line 39
-39:   def self.encode(num)
-40:     raise Base36Error unless num.is_a? Fixnum
-41: 
-42:     base36 = ""
-43: 
-44:     while num > 0
-45:       base36 << ALPH[(num % BASE36)]
-46:       num /= BASE36
-47:     end
-48: 
-49:     base36 << ALPH[0] if num == 0
-50: 
-51:     base36.reverse
-52:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Base36Error.html b/code_ruby/Maasha/lib/doc/Base36Error.html deleted file mode 100644 index 2e2be76..0000000 --- a/code_ruby/Maasha/lib/doc/Base36Error.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: Base36Error - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Base36Error

- -
-

-Error class for all exceptions to do with Base36. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Biopieces.html b/code_ruby/Maasha/lib/doc/Biopieces.html deleted file mode 100644 index 3cacc08..0000000 --- a/code_ruby/Maasha/lib/doc/Biopieces.html +++ /dev/null @@ -1,562 +0,0 @@ - - - - - - - Class: Biopieces - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
-

Included Modules

- -
- -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Biopieces

- -
-

-Biopieces are command line scripts and uses -OptionParser to parse command line options according to a list of casts. -Each cast prescribes the long and short name of the option, the type, if it -is mandatory, the default value, and allowed and disallowed values. An -optional list of extra casts can be supplied, and the integrity of the -casts are checked. Following the command line parsing, the options are -checked according to the casts. Methods are also included for handling the -parsing and emitting of Biopiece records, which are ASCII text records -consisting of lines with a key/value pair separated by a colon and a white -space ’: ’. Each record is separated by a line with three -dashes ’—’. -

- -
- - - - - - -
-

Attributes

- - -
- - - - -
- out[RW] -
- -
- - - -
-
- -
- - - - -
-

Public Class Methods

- - -
- - -
- - new(test=nil, input=STDIN, output=STDOUT) - click to toggle source - -
- -
- -

-Initialize a Biopiece and write the status to file. Options are for testing -purposes only. -

- - - -
-
-    # File biopieces.rb, line 49
-49:   def initialize(test=nil, input=STDIN, output=STDOUT)
-50:     @test   = test
-51:     @input  = input
-52:     @output = output
-53:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - each() - click to toggle source - -
- -
- - - - - -
- - - - -
- Alias for: each_record -
- -
- - -
- - -
- - each_record() - click to toggle source - -
- -
- -

-Open Biopiece input stream if not open and iterate over all Biopiece -records in the stream. -

- - - -
-
-    # File biopieces.rb, line 66
-66:   def each_record
-67:     @in = Stream::open(@options, mode="r", @input) unless @in.is_a? IO
-68:     return if @in.nil?
-69: 
-70:     record = {}
-71: 
-72:     @in.each_line do |line|
-73:       case line
-74:       when /^([^:]+): (.*)$/
-75:         record[$1.to_sym] = $2
-76:       when /^---$/
-77:         yield record unless record.empty?
-78:         record = {}
-79:       else
-80:         raise "Bad record format: #{line}"
-81:       end
-82:     end
-83: 
-84:     yield record unless record.empty?
-85: 
-86:     self # conventionally
-87:   end
-
- -
- - -
- Also aliased as: each -
- - - -
- - -
- - -
- - mktmpdir() - click to toggle source - -
- -
- -

-Create a temporary directory inside the ENV[“BP_TMP“] dir. -

- - - -
-
-     # File biopieces.rb, line 106
-106:   def mktmpdir
-107:     time = Time.now.to_i
-108:     user = ENV["USER"]
-109:     pid  = $$
-110:     path = ENV["BP_TMP"] + "/" + [user, time + pid, pid, "bp_tmp"].join("_")
-111:     Dir.mkdir(path)
-112:     Status.new.set_tmpdir(path)
-113:     path
-114:   end
-
- -
- - - - -
- - -
- - -
- - parse(argv, cast_list=[], script_path=$0) - click to toggle source - -
- -
- -

-Check the integrity of a list of casts, followed by parsion options from -argv and finally checking the options according to the casts. Returns nil -if argv is empty, otherwise an options hash. -

- - - -
-
-    # File biopieces.rb, line 58
-58:   def parse(argv, cast_list=[], script_path=$0)
-59:     casts          = Casts.new(cast_list)
-60:     option_handler = OptionHandler.new(argv, casts, script_path, @test)
-61:     @options       = option_handler.options_parse
-62:   end
-
- -
- - - - -
- - -
- - -
- - puts(record) - click to toggle source - -
- -
- -

-Open Biopiece output stream if not open and puts record to the stream. -

- - - -
-
-     # File biopieces.rb, line 92
- 92:   def puts(record)
- 93:     @out = Stream::open(@options, mode="w", @output) unless @out.is_a? IO
- 94: 
- 95:     record.each do |key,value|
- 96:       @out.print "#{key.to_s}: #{value}\n"
- 97:     end
- 98: 
- 99:     @out.print "---\n"
-100:   end
-
- -
- - - - -
- - -
- - -
- - to_s() - click to toggle source - -
- -
- - - - - -
-
-     # File biopieces.rb, line 102
-102:   def to_s
-103:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/BitArray.html b/code_ruby/Maasha/lib/doc/BitArray.html deleted file mode 100644 index 44a12d4..0000000 --- a/code_ruby/Maasha/lib/doc/BitArray.html +++ /dev/null @@ -1,869 +0,0 @@ - - - - - - - Class: BitArray - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

BitArray

- -
-

-Class containing methods for creating and manipulating a bit array. -

- -
- - - - - - -
-

Attributes

- - -
- - -
- size[R] -
- -
- - - -
-
- -
- - -
- byte_array[R] -
- -
- - - -
-
- -
- - - - -
-

Public Class Methods

- - -
- - -
- - new(size) - click to toggle source - -
- -
- -

-Method to initialize a new bit array of a given size. -

- - - -
-
-    # File bitarray.rb, line 35
-35:   def initialize(size)
-36:     @size        = size
-37:     @byte_array  = init_byte_array
-38:     @count_array = init_count_array
-39:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - &(ba) - click to toggle source - -
- -
- -

-Method to run bitwise AND (&) on two bit arrays and return the result -in a new bit array. Bits are copied if they exists in BOTH operands. -00111100 & 00001101 = 00001100 -

- - - -
-
-    # File bitarray.rb, line 76
-76:   def &(ba)
-77:     raise BitArrayError, "uneven size of bit arrays: #{self.size} != #{ba.size}" if self.size != ba.size
-78: 
-79:     result = BitArray.new(ba.size)
-80: 
-81:     (0 ... ba.byte_array.size).each do |byte|
-82:       result.byte_array[byte] = (self.byte_array[byte].ord & ba.byte_array[byte].ord).chr
-83:     end
-84: 
-85:     result
-86:   end
-
- -
- - - - -
- - -
- - -
- - ^(ba) - click to toggle source - -
- -
- -

-Method to run bitwise XOR (^) on two bit arrays and return the result in a -new bit array. Bits are copied if they exists in ONE BUT NOT BOTH operands. -00111100 ^ 00001101 = 00110001 -

- - - -
-
-     # File bitarray.rb, line 106
-106:   def ^(ba)
-107:     raise BitArrayError, "uneven size of bit arrays: #{self.size} != #{ba.size}" if self.size != ba.size
-108: 
-109:     result = BitArray.new(ba.size)
-110: 
-111:     (0 ... ba.byte_array.size).each do |byte|
-112:       result.byte_array[byte] = (self.byte_array[byte].ord ^ ba.byte_array[byte].ord).chr
-113:     end
-114: 
-115:     result
-116:   end
-
- -
- - - - -
- - -
- - -
- - bit_set(pos) - click to toggle source - -
- -
- -

-Method to set a bit to 1 at a given position in the bit array. -

- - - -
-
-    # File bitarray.rb, line 42
-42:   def bit_set(pos)
-43:     raise BitArrayError, "Position #{pos} must be an integer."              unless pos.is_a? Fixnum
-44:     raise BitArrayError, "Position #{pos} outside of range: 0 ... #{@size}" unless (0 ... @size ).include? pos
-45: 
-46:     @byte_array[byte_pos(pos)] = (@byte_array[byte_pos(pos)].ord | bit_pos(pos)).chr
-47:   end
-
- -
- - - - -
- - -
- - -
- - bit_set?(pos) - click to toggle source - -
- -
- -

-Method to check if a bit at a given position in the bit array is set. -

- - - -
-
-    # File bitarray.rb, line 50
-50:   def bit_set?(pos)
-51:     raise BitArrayError, "Position #{pos} must be an integer."              unless pos.is_a? Fixnum
-52:     raise BitArrayError, "Position #{pos} outside of range: 0 ... #{@size}" unless (0 ... @size ).include? pos
-53: 
-54:     (@byte_array[byte_pos(pos)].ord & bit_pos(pos)) != 0
-55:   end
-
- -
- - - - -
- - -
- - -
- - bits_off() - click to toggle source - -
- -
- -

-Method that returns the number of bits set “off” in a bit -array. -

- - - -
-
-    # File bitarray.rb, line 69
-69:   def bits_off
-70:     @size - bits_on
-71:   end
-
- -
- - - - -
- - -
- - -
- - bits_on() - click to toggle source - -
- -
- -

-Method that returns the number of bits set “on” in a bit array. -

- - - -
-
-    # File bitarray.rb, line 58
-58:   def bits_on 
-59:     bits_on = 0
-60: 
-61:     (0 ... self.byte_array.size).each do |byte|
-62:       bits_on += @count_array[self.byte_array[byte].ord]
-63:     end
-64: 
-65:     bits_on
-66:   end
-
- -
- - - - -
- - -
- - -
- - to_s() - click to toggle source - -
- -
- -

-Method to convert a bit array to a string. -

- - - -
-
-     # File bitarray.rb, line 119
-119:   def to_s
-120:     string = ""
-121: 
-122:     (0 ... @size).each do |pos|
-123:       if self.bit_set? pos 
-124:         string << "1"
-125:       else
-126:         string << "0"
-127:       end
-128:     end
-129: 
-130:     string
-131:   end
-
- -
- - - - -
- - -
- - -
- - |(ba) - click to toggle source - -
- -
- -

-Method to run bitwise OR (|) on two bit arrays and return the result in a -new bit array. Bits are copied if they exists in EITHER operands. 00111100 -| 00001101 = 00111101 -

- - - -
-
-     # File bitarray.rb, line 91
- 91:   def |(ba)
- 92:     raise BitArrayError, "uneven size of bit arrays: #{self.size} != #{ba.size}" if self.size != ba.size
- 93: 
- 94:     result = BitArray.new(ba.size)
- 95: 
- 96:     (0 ... ba.byte_array.size).each do |byte|
- 97:       result.byte_array[byte] = (self.byte_array[byte].ord | ba.byte_array[byte].ord).chr
- 98:     end
- 99: 
-100:     result
-101:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - bit_pos(pos) - click to toggle source - -
- -
- -

-Method that returns the bit position in a byte. -

- - - -
-
-     # File bitarray.rb, line 177
-177:   def bit_pos(pos)
-178:     1 << (BitsInChar - 1 - (pos % BitsInChar))
-179:   end
-
- -
- - - - -
- - -
- - -
- - bits_in_char(char) - click to toggle source - -
- -
- -

-Method that returns the number of set bits in a char. -

- - - -
-
-     # File bitarray.rb, line 161
-161:   def bits_in_char(char)
-162:     bits = 0
-163: 
-164:     (0 ... BitsInChar).each do |pos|
-165:       bits += 1 if ((char & bit_pos(pos)) != 0)
-166:     end
-167: 
-168:     bits
-169:   end
-
- -
- - - - -
- - -
- - -
- - byte_pos(pos) - click to toggle source - -
- -
- -

-Method that returns the byte position in the byte array for a given bit -position. -

- - - -
-
-     # File bitarray.rb, line 172
-172:   def byte_pos(pos)
-173:     pos / BitsInChar
-174:   end
-
- -
- - - - -
- - -
- - -
- - init_byte_array() - click to toggle source - -
- -
- -

-Method to initialize the byte array (string) that constitutes the bit -array. -

- - - -
-
-     # File bitarray.rb, line 138
-138:   def init_byte_array
-139:     raise BitArrayError, "Size must be an integer, not #{@size}" unless @size.is_a? Fixnum
-140:     raise BitArrayError, "Size must be positive, not #{@size}"   unless @size > 0
-141: 
-142:     byte_array = ""
-143:     byte_array << 0.chr * (((@size - 1) / BitsInChar) + 1)
-144: 
-145:     byte_array
-146:   end
-
- -
- - - - -
- - -
- - -
- - init_count_array() - click to toggle source - -
- -
- -

-Method that returns an array where the element index value is the number of -bits set for that index value. -

- - - -
-
-     # File bitarray.rb, line 150
-150:   def init_count_array
-151:     count_array = []
-152: 
-153:     (0 ... (2 ** BitsInChar)).each do |i|
-154:       count_array << bits_in_char(i)
-155:     end
-156: 
-157:     count_array
-158:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/BitArrayError.html b/code_ruby/Maasha/lib/doc/BitArrayError.html deleted file mode 100644 index 6b352ae..0000000 --- a/code_ruby/Maasha/lib/doc/BitArrayError.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - - Class: BitArrayError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

BitArrayError

- -
-

-Error class for all exceptions to do with BitArray. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Boulder.html b/code_ruby/Maasha/lib/doc/Boulder.html deleted file mode 100644 index b1af1ca..0000000 --- a/code_ruby/Maasha/lib/doc/Boulder.html +++ /dev/null @@ -1,361 +0,0 @@ - - - - - - - Class: Boulder - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Boulder

- -
-

-Class to manipulate boulder records - Lincoln Steins own YAML like format: -stein.cshl.org/boulder/docs/Boulder.html -

- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(input=STDIN, output=STDOUT) - click to toggle source - -
- -
- -

-Initialize a Boulder object. Options are for -testing purposes only. -

- - - -
-
-    # File boulder.rb, line 39
-39:   def initialize(input=STDIN, output=STDOUT)
-40:     @input  = input
-41:     @output = output
-42:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - each() - click to toggle source - -
- -
- - - - - -
-
-    # File boulder.rb, line 44
-44:   def each
-45:     while not @input.eof? do
-46:       block = @input.gets(SEP)
-47:       raise BoulderError, "Missing record seperator" unless block =~ /#{SEP}$/
-48: 
-49:       record = {}
-50: 
-51:       block.chomp(SEP).each_line do |line|
-52:         key, val = line.chomp.split('=', 2)
-53: 
-54:         raise BoulderError, "Missing key/value seperator" if val.nil?
-55:         raise BoulderError, "Missing key"                 if key.empty?
-56:         raise BoulderError, "Missing value"               if val.empty?
-57: 
-58:         record[key.to_sym] = val
-59:       end
-60: 
-61:       yield record
-62:     end
-63:   end
-
- -
- - - - -
- - -
- - -
- - to_boulder(record) - click to toggle source - -
- -
- -

-Method that converts and returns a hash record as a Boulder string. -

- - - -
-
-    # File boulder.rb, line 67
-67:   def to_boulder(record)
-68:     str = ""
-69: 
-70:     record.each_pair do |key, val|
-71:       str << "#{key}=#{val}\n"
-72:     end
-73: 
-74:     str << "=\n"
-75: 
-76:     str
-77:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/BoulderError.html b/code_ruby/Maasha/lib/doc/BoulderError.html deleted file mode 100644 index ded84e1..0000000 --- a/code_ruby/Maasha/lib/doc/BoulderError.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - - Class: BoulderError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

BoulderError

- -
-

-Error class for all exceptions to do with Boulder. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/CastError.html b/code_ruby/Maasha/lib/doc/CastError.html deleted file mode 100644 index 3689d7c..0000000 --- a/code_ruby/Maasha/lib/doc/CastError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: CastError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

CastError

- -
-

-Error class for all exceptions to do with option casts. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Casts.html b/code_ruby/Maasha/lib/doc/Casts.html deleted file mode 100644 index 8892aa8..0000000 --- a/code_ruby/Maasha/lib/doc/Casts.html +++ /dev/null @@ -1,823 +0,0 @@ - - - - - - - Class: Casts - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Casts

- -
-

-Class to handle casts of command line options. Each cast prescribes the -long and short name of the option, the type, if it is mandatory, the -default value, and allowed and disallowed values. An optional list of extra -casts can be supplied, and the integrity of the casts are checked. -

- -
- - - -
-

Constants

-
- -
TYPES
- -
- - -
MANDATORY
- -
- - -
-
- - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(cast_list=[]) - click to toggle source - -
- -
- -

-Initialize cast object with an optional options cast list to which -ubiquitous casts are added after which all casts are checked. -

- - - -
-
-     # File biopieces.rb, line 132
-132:   def initialize(cast_list=[])
-133:     @cast_list = cast_list
-134:     ubiquitous
-135:     check
-136:     long_to_sym
-137:     self.push *@cast_list
-138:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - check() - click to toggle source - -
- -
- -

-Check integrity of the casts. -

- - - -
-
-     # File biopieces.rb, line 151
-151:   def check
-152:     check_keys
-153:     check_values
-154:     check_duplicates
-155:   end
-
- -
- - - - -
- - -
- - -
- - check_duplicates() - click to toggle source - -
- -
- -

-Check cast for duplicate long or short options names. -

- - - -
-
-     # File biopieces.rb, line 237
-237:   def check_duplicates
-238:     check_hash = {}
-239:     @cast_list.each do |cast|
-240:       raise CastError, "Duplicate argument: '--#{cast[:long]}'" if check_hash.has_key? cast[:long]
-241:       raise CastError, "Duplicate argument: '-#{cast[:short]}'" if check_hash.has_key? cast[:short]
-242:       check_hash[cast[:long]]  = true
-243:       check_hash[cast[:short]] = true
-244:     end
-245:   end
-
- -
- - - - -
- - -
- - -
- - check_keys() - click to toggle source - -
- -
- -

-Check if all mandatory keys are present in casts and raise if not. -

- - - -
-
-     # File biopieces.rb, line 158
-158:   def check_keys
-159:     @cast_list.each do |cast|
-160:       MANDATORY.each do |mandatory|
-161:         raise CastError, "Missing symbol in cast: '#{mandatory.to_sym}'" unless cast.has_key? mandatory.to_sym
-162:       end
-163:     end
-164:   end
-
- -
- - - - -
- - -
- - -
- - check_val_allowed(cast) - click to toggle source - -
- -
- -

-Check if values to allowed are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 223
-223:   def check_val_allowed(cast)
-224:     unless cast[:allowed].is_a? String or cast[:allowed].nil?
-225:       raise CastError, "Illegal cast of allowed: '#{cast[:allowed]}'"
-226:     end
-227:   end
-
- -
- - - - -
- - -
- - -
- - check_val_default(cast) - click to toggle source - -
- -
- -

-Check if values to default are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 213
-213:   def check_val_default(cast)
-214:     unless cast[:default].nil?          or
-215:            cast[:default].is_a? String  or
-216:            cast[:default].is_a? Integer or
-217:            cast[:default].is_a? Float
-218:       raise CastError, "Illegal cast of default: '#{cast[:default]}'"
-219:     end
-220:   end
-
- -
- - - - -
- - -
- - -
- - check_val_disallowed(cast) - click to toggle source - -
- -
- -

-Check if values to disallowed are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 230
-230:   def check_val_disallowed(cast)
-231:     unless cast[:disallowed].is_a? String or cast[:disallowed].nil?
-232:       raise CastError, "Illegal cast of disallowed: '#{cast[:disallowed]}'"
-233:     end
-234:   end
-
- -
- - - - -
- - -
- - -
- - check_val_long(cast) - click to toggle source - -
- -
- -

-Check if the values to long are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 180
-180:   def check_val_long(cast)
-181:     unless cast[:long].is_a? String and cast[:long].length > 1
-182:       raise CastError, "Illegal cast of long: '#{cast[:long]}'"
-183:     end
-184:   end
-
- -
- - - - -
- - -
- - -
- - check_val_mandatory(cast) - click to toggle source - -
- -
- -

-Check if values to mandatory are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 206
-206:   def check_val_mandatory(cast)
-207:     unless cast[:mandatory] == true or cast[:mandatory] == false
-208:       raise CastError, "Illegal cast of mandatory: '#{cast[:mandatory]}'"
-209:     end
-210:   end
-
- -
- - - - -
- - -
- - -
- - check_val_short(cast) - click to toggle source - -
- -
- -

-Check if the values to short are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 187
-187:   def check_val_short(cast)
-188:     unless cast[:short].is_a? String and cast[:short].length == 1
-189:       raise CastError, "Illegal cast of short: '#{cast[:short]}'"
-190:     end
-191:   end
-
- -
- - - - -
- - -
- - -
- - check_val_type(cast) - click to toggle source - -
- -
- -

-Check if values to type are legal and raise if not. -

- - - -
-
-     # File biopieces.rb, line 194
-194:   def check_val_type(cast)
-195:     type_hash = {}
-196:     TYPES.each do |type|
-197:       type_hash[type] = true
-198:     end
-199: 
-200:     unless type_hash.has_key? cast[:type]
-201:       raise CastError, "Illegal cast of type: '#{cast[:type]}'"
-202:     end
-203:   end
-
- -
- - - - -
- - -
- - -
- - check_values() - click to toggle source - -
- -
- -

-Check if all values in casts are valid. -

- - - -
-
-     # File biopieces.rb, line 167
-167:   def check_values
-168:     @cast_list.each do |cast|
-169:       check_val_long(cast)
-170:       check_val_short(cast)
-171:       check_val_type(cast)
-172:       check_val_mandatory(cast)
-173:       check_val_default(cast)
-174:       check_val_allowed(cast)
-175:       check_val_disallowed(cast)
-176:     end
-177:   end
-
- -
- - - - -
- - -
- - -
- - long_to_sym() - click to toggle source - -
- -
- -

-Convert values to :long keys to symbols for all casts. -

- - - -
-
-     # File biopieces.rb, line 248
-248:   def long_to_sym
-249:     @cast_list.each do |cast|
-250:       cast[:long] = cast[:long].to_sym
-251:     end
-252:   end
-
- -
- - - - -
- - -
- - -
- - ubiquitous() - click to toggle source - -
- -
- -

-Add ubiquitous options casts. -

- - - -
-
-     # File biopieces.rb, line 143
-143:   def ubiquitous
-144:     @cast_list << {:long=>'help',       :short=>'?', :type=>'flag',   :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
-145:     @cast_list << {:long=>'stream_in',  :short=>'I', :type=>'files!', :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
-146:     @cast_list << {:long=>'stream_out', :short=>'O', :type=>'file',   :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
-147:     @cast_list << {:long=>'verbose',    :short=>'v', :type=>'flag',   :mandatory=>false, :default=>nil, :allowed=>nil, :disallowed=>nil}
-148:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Digest.html b/code_ruby/Maasha/lib/doc/Digest.html deleted file mode 100644 index b25354f..0000000 --- a/code_ruby/Maasha/lib/doc/Digest.html +++ /dev/null @@ -1,416 +0,0 @@ - - - - - - - Class: Digest - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
-

Included Modules

- -
- -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Digest

- -
- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(seq, pattern, cut_pos) - click to toggle source - -
- -
- -

-Initialize a digest object with the following arguments: -

-
    -
  • -seq: A sequence object. -

    -
  • -
  • -pattern: A restriction enzyme recognition pattern. -

    -
  • -
  • -cut_pos: Offset from match position where the enzyme cuts. -

    -
  • -
- - - -
-
-    # File digest.rb, line 37
-37:   def initialize(seq, pattern, cut_pos)
-38:     @seq     = seq
-39:     @pattern = disambiguate(pattern)
-40:     @cut_pos = cut_pos
-41:     @offset  = 0
-42:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - each() - click to toggle source - -
- -
- -

-Method to get the next digestion product from a sequence. -

- - - -
-
-    # File digest.rb, line 45
-45:   def each
-46:     @seq.seq.upcase.scan @pattern do
-47:       pos = $`.length + @cut_pos - 1
-48:      
-49:       if pos >= 0 and pos < @seq.length - 2
-50:         seq = Seq.new("#{@seq.seq_name}[#{@offset}-#{pos}]", @seq.seq[@offset .. pos], @seq.type)
-51: 
-52:         yield seq
-53:       end
-54: 
-55:       @offset = pos + 1
-56:     end
-57: 
-58:     if @offset < 0
-59:       @offset = 0
-60:     elsif @offset > @seq.length
-61:       @offset = 0
-62:     end
-63: 
-64:     seq = Seq.new("#{@seq.seq_name}[#{@offset}-#{@seq.length - 1}]", @seq.seq[@offset .. @seq.length], @seq.type)
-65: 
-66:     yield seq
-67: 
-68:     self # conventionally
-69:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - disambiguate(pattern) - click to toggle source - -
- -
- -

-Method that returns a regexp object with a restriction enzyme pattern with -ambiguity codes substituted to the appropriate regexp. -

- - - -
-
-     # File digest.rb, line 76
- 76:   def disambiguate(pattern)
- 77:     ambiguity = {
- 78:       'A' => "A",
- 79:       'T' => "T",
- 80:       'U' => "T",
- 81:       'C' => "C",
- 82:       'G' => "G",
- 83:       'M' => "[AC]",
- 84:       'R' => "[AG]",
- 85:       'W' => "[AT]",
- 86:       'S' => "[CG]",
- 87:       'Y' => "[CT]",
- 88:       'K' => "[GT]",
- 89:       'V' => "[ACG]",
- 90:       'H' => "[ACT]",
- 91:       'D' => "[AGT]",
- 92:       'B' => "[CGT]",
- 93:       'N' => "[GATC]"
- 94:     }
- 95: 
- 96:     new_pattern = ""
- 97: 
- 98:     pattern.upcase.each_char do |char|
- 99:       if ambiguity.has_key? char
-100:         new_pattern << ambiguity[char]
-101:       else
-102:         raise DigestError, "Could not disambiguate residue: #{char}"
-103:       end
-104:     end
-105: 
-106:     Regexp.new(new_pattern)
-107:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/DigestError.html b/code_ruby/Maasha/lib/doc/DigestError.html deleted file mode 100644 index 6176583..0000000 --- a/code_ruby/Maasha/lib/doc/DigestError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: DigestError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

DigestError

- -
-

-Error class for all exceptions to do with Digest. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Fasta.html b/code_ruby/Maasha/lib/doc/Fasta.html deleted file mode 100644 index 65ce1bb..0000000 --- a/code_ruby/Maasha/lib/doc/Fasta.html +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - - Class: Fasta - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Fasta

- -
- -
- - - - - - - - - -
-

Public Instance Methods

- - -
- - -
- - get_entry() - click to toggle source - -
- -
- -

-Method to get the next FASTA entry form an ios and return this as a Seq object. If no entry is found or eof then nil is -returned. -

- - - -
-
-    # File fasta.rb, line 34
-34:   def get_entry
-35:     block = @io.gets($/ + '>')
-36:     return nil if block.nil?
-37: 
-38:     block.chomp!($/ + '>')
-39: 
-40:     (seq_name, seq) = block.split($/, 2)
-41: 
-42:     raise FastaError, "Bad FASTA format" if seq_name.nil? or seq.nil?
-43: 
-44:     entry          = Seq.new
-45:     entry.type     = @type.nil? ? nil : @type.downcase
-46:     entry.seq      = seq.gsub(/\s/, '')
-47:     entry.seq_name = seq_name.sub(/^>/, '').rstrip
-48: 
-49:     raise FastaError, "Bad FASTA format" if entry.seq_name.empty?
-50:     raise FastaError, "Bad FASTA format" if entry.seq.empty?
-51: 
-52:     entry
-53:   end
-
- -
- - - - -
- - -
- - -
- - puts(record) - click to toggle source - -
- -
- -

-TODO - this should be some custom to_s method instead. -

- - - -
-
-    # File fasta.rb, line 56
-56:   def puts(record)
-57:     if record.has_key? :SEQ_NAME and record.has_key? :SEQ
-58:       @io.print ">#{record[:SEQ_NAME]}\n"
-59:       @io.print "#{record[:SEQ]}\n"
-60:     end
-61:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/FastaError.html b/code_ruby/Maasha/lib/doc/FastaError.html deleted file mode 100644 index a5ec5a1..0000000 --- a/code_ruby/Maasha/lib/doc/FastaError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: FastaError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

FastaError

- -
-

-Error class for all exceptions to do with FASTA. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Fastq.html b/code_ruby/Maasha/lib/doc/Fastq.html deleted file mode 100644 index 5152dcf..0000000 --- a/code_ruby/Maasha/lib/doc/Fastq.html +++ /dev/null @@ -1,306 +0,0 @@ - - - - - - - Class: Fastq - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Fastq

- -
- -
- - - - - - - - - -
-

Public Instance Methods

- - -
- - -
- - get_entry() - click to toggle source - -
- -
- -

-Method to get the next FASTQ entry form an ios and return this as a Seq object. If no entry is found or eof then nil is -returned. -

- - - -
-
-    # File fastq.rb, line 34
-34:   def get_entry
-35:     begin
-36:       seq_name       = @io.gets.chomp!
-37:       seq            = @io.gets.chomp!
-38:       qual_name      = @io.gets.chomp!
-39:       qual           = @io.gets.chomp!
-40: 
-41:       entry          = Seq.new
-42:       entry.type     = @type.nil? ? nil : @type.downcase
-43:       entry.seq      = seq
-44:       entry.seq_name = seq_name[1 .. seq_name.length]
-45:       entry.qual     = qual
-46: 
-47:       entry
-48:     rescue
-49:       nil
-50:     end
-51:   end
-
- -
- - - - -
- - -
- - -
- - puts(record) - click to toggle source - -
- -
- -

-TODO - this should be some custom to_s method instead. -

- - - -
-
-    # File fastq.rb, line 54
-54:   def puts(record)
-55:     if record.has_key? :SEQ_NAME and record.has_key? :SEQ
-56:       @io.print ">#{record[:SEQ_NAME]}\n"
-57:       @io.print "#{record[:SEQ]}\n"
-58:     end
-59:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/FastqError.html b/code_ruby/Maasha/lib/doc/FastqError.html deleted file mode 100644 index 0ec36b4..0000000 --- a/code_ruby/Maasha/lib/doc/FastqError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: FastqError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

FastqError

- -
-

-Error class for all exceptions to do with FASTQ. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Filesys.html b/code_ruby/Maasha/lib/doc/Filesys.html deleted file mode 100644 index 4c874ae..0000000 --- a/code_ruby/Maasha/lib/doc/Filesys.html +++ /dev/null @@ -1,452 +0,0 @@ - - - - - - - Class: Filesys - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
-

Included Modules

- -
- -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Filesys

- -
- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(io, type=nil) - click to toggle source - -
- -
- - - - - -
-
-    # File filesys.rb, line 58
-58:   def initialize(io, type=nil)
-59:     @io   = io
-60:     @type = type
-61:   end
-
- -
- - - - -
- - -
- - -
- - open(*args) - click to toggle source - -
- -
- -

-Class method allowing open to be used on (zipped) files. See File.open. -

- - - -
-
-    # File filesys.rb, line 35
-35:   def self.open(*args)
-36:     args = *args
-37:     file = args.first
-38: 
-39:     if file == "-"
-40:       ios = self.new(STDIN)
-41:     elsif File.pipe? file
-42:       ios = self.new(File.open(*args))
-43:     else
-44:       ios = self.zopen(*args)
-45:     end
-46: 
-47:     if block_given?
-48:       begin
-49:         yield ios
-50:       ensure
-51:         ios.close
-52:       end
-53:     else
-54:       return ios
-55:     end
-56:   end
-
- -
- - - - -
- - -
- -
-

Private Class Methods

- - -
- - -
- - zopen(*args) - click to toggle source - -
- -
- -

-Helper method to return an ios to a file that may be zipped in which case -the ios is unzipped on the fly. See File.open. -

- - - -
-
-    # File filesys.rb, line 79
-79:   def self.zopen(*args)
-80:     ios = File.open(*args)
-81: 
-82:     begin
-83:       ios = Zlib::GzipReader.new(ios)
-84:     rescue
-85:       ios.rewind
-86:     end
-87: 
-88:     self.new(ios)
-89:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - close() - click to toggle source - -
- -
- -

-Method to close ios. -

- - - -
-
-    # File filesys.rb, line 64
-64:   def close
-65:     @io.close
-66:   end
-
- -
- - - - -
- - -
- - -
- - each() - click to toggle source - -
- -
- -

-Iterator method for parsing entries. -

- - - -
-
-    # File filesys.rb, line 69
-69:   def each
-70:     while entry = get_entry do
-71:       yield entry
-72:     end
-73:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/FilesysError.html b/code_ruby/Maasha/lib/doc/FilesysError.html deleted file mode 100644 index 3a6624d..0000000 --- a/code_ruby/Maasha/lib/doc/FilesysError.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - - Class: FilesysError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

FilesysError

- -
-

-Error class for all exceptions to do with Filesys. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Genbank.html b/code_ruby/Maasha/lib/doc/Genbank.html deleted file mode 100644 index ed25065..0000000 --- a/code_ruby/Maasha/lib/doc/Genbank.html +++ /dev/null @@ -1,521 +0,0 @@ - - - - - - - Class: Genbank - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Genbank

- -
- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(io) - click to toggle source - -
- -
- - - - - -
-
-    # File genbank.rb, line 32
-32:   def initialize(io)
-33:     @io      = io
-34:     @entry   = []
-35:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - each(hash_keys, hash_feats, hash_quals) - click to toggle source - -
- -
- -

-Iterator method for parsing Genbank entries. -

- - - -
-
-    # File genbank.rb, line 38
-38:   def each(hash_keys, hash_feats, hash_quals)
-39:     while @entry = get_entry do
-40:       keys = get_keys(hash_keys)
-41:       seq  = get_seq
-42: 
-43:       features = GenbankFeatures.new(@entry, hash_feats, hash_quals)
-44: 
-45:       features.each do |record|
-46:         keys.each_pair { |key,val| record[key] = val }
-47: 
-48:                                 loc = Locator.new(record[:LOCATOR], seq)
-49:                                 record[:SEQ]     = loc.subseq.seq
-50:         record[:SEQ_LEN] = loc.subseq.length
-51:                                 record[:STRAND]  = loc.strand
-52:                                 record[:S_BEG]   = loc.s_beg
-53:                                 record[:S_END]   = loc.s_end
-54: 
-55:         yield record
-56:       end
-57:     end
-58:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - get_entry() - click to toggle source - -
- -
- -

-Method to get the next Genbank entry form an ios -and return this. -

- - - -
-
-    # File genbank.rb, line 63
-63:   def get_entry
-64:     block = @io.gets("//" + $/)
-65:     return nil if block.nil?
-66: 
-67:     block.chomp!("//" + $/ )
-68: 
-69:     entry = block.split $/
-70: 
-71:     return nil if entry.empty?
-72: 
-73:     entry
-74:   end
-
- -
- - - - -
- - -
- - -
- - get_keys(hash_keys) - click to toggle source - -
- -
- -

-Method to get the base keys from Genbank entry -and return these in a hash. -

- - - -
-
-     # File genbank.rb, line 93
- 93:   def get_keys(hash_keys)
- 94:     keys = {}
- 95:     i    = 0
- 96:     j    = 0
- 97: 
- 98:     while @entry[i] and @entry[i] !~ /^FEATURES/
- 99:       if @entry[i] =~ /^\s{0,3}([A-Z]{2})/
-100:         if want_key?(hash_keys, $1)
-101:           j = i + 1
-102: 
-103:           key, val = @entry[i].lstrip.split(/\s+/, 2)
-104: 
-105:           while @entry[j] and @entry[j] !~ /^\s{0,3}[A-Z]/
-106:             val << @entry[j].lstrip
-107:             j += 1
-108:           end
-109: 
-110:           if keys[key.to_sym]
-111:             keys[key.to_sym] << ";" + val
-112:           else
-113:             keys[key.to_sym] = val
-114:           end
-115:         end
-116:       end
-117: 
-118:       j > i ? i = j : i += 1
-119:     end
-120: 
-121:     keys
-122:   end
-
- -
- - - - -
- - -
- - -
- - get_seq() - click to toggle source - -
- -
- -

-Method to get the DNA sequence from a Genbank -entry and return this as a Seq object. -

- - - -
-
-    # File genbank.rb, line 78
-78:   def get_seq
-79:     i = @entry.size
-80:     j = i - 1
-81: 
-82:     while @entry[j] and @entry[j] !~ /^[A-Z]/
-83:       j -= 1
-84:     end
-85: 
-86:     seq = @entry[j + 1 .. i].join.delete(" 0123456789")
-87: 
-88:     Seq.new(nil, seq, "dna") if seq
-89:   end
-
- -
- - - - -
- - -
- - -
- - want_key?(hash_keys, key) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 124
-124:   def want_key?(hash_keys, key)
-125:     if hash_keys
-126:       if hash_keys[key.to_sym]
-127:         return true
-128:       else
-129:         return false
-130:       end
-131:     else
-132:       return true
-133:     end
-134:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/GenbankError.html b/code_ruby/Maasha/lib/doc/GenbankError.html deleted file mode 100644 index 5c0f160..0000000 --- a/code_ruby/Maasha/lib/doc/GenbankError.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - - Class: GenbankError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

GenbankError

- -
-

-Error class for all exceptions to do with Genbank. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/GenbankFeatures.html b/code_ruby/Maasha/lib/doc/GenbankFeatures.html deleted file mode 100644 index ac47161..0000000 --- a/code_ruby/Maasha/lib/doc/GenbankFeatures.html +++ /dev/null @@ -1,473 +0,0 @@ - - - - - - - Class: GenbankFeatures - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

GenbankFeatures

- -
- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(entry, hash_feats, hash_quals) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 141
-141:   def initialize(entry, hash_feats, hash_quals)
-142:     @entry      = entry
-143:     @hash_feats = hash_feats
-144:     @hash_quals = hash_quals
-145:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - each() - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 147
-147:   def each
-148:     while @entry[@@i] and @entry[@@i] !~ /^ORIGIN/
-149:       if @entry[@@i] =~ /^\s{5}([A-Za-z_-]+)/
-150:         if want_feat? $1
-151:           record = {}
-152: 
-153:           feat, loc = @entry[@@i].lstrip.split(/\s+/, 2)
-154: 
-155:           @@j = @@i + 1
-156: 
-157:           while @entry[@@j] and @entry[@@j] !~ /^(\s{21}\/|\s{5}[A-Za-z_-]|[A-Z])/
-158:             loc << @entry[@@j].lstrip
-159:             @@j += 1
-160:           end
-161: 
-162:           get_quals.each_pair { |k,v|
-163:             record[k.upcase.to_sym] = v
-164:           }
-165: 
-166:           record[:FEATURE] = feat
-167:           record[:LOCATOR] = loc
-168: 
-169:           yield record
-170:         end
-171:       end
-172: 
-173:       @@j > @@i ? @@i = @@j : @@i += 1
-174:     end
-175:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - get_quals() - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 179
-179:   def get_quals
-180:     quals = {}
-181:     k     = 0
-182: 
-183:     while @entry[@@j] and @entry[@@j] !~ /^\s{5}[A-Za-z_-]|^[A-Z]/
-184:       if @entry[@@j] =~ /^\s{21}\/([^=]+)="([^"]+)/
-185:         qual = $1
-186:         val  = $2
-187: 
-188:         if want_qual? qual
-189:           k = @@j + 1
-190: 
-191:           while @entry[k] and @entry[k] !~ /^(\s{21}\/|\s{5}[A-Za-z_-]|[A-Z])/
-192:             val << @entry[k].lstrip.chomp('"')
-193:             k += 1
-194:           end
-195: 
-196:           if quals[qual]
-197:             quals[qual] << ";" + val
-198:           else
-199:             quals[qual] = val
-200:           end
-201:         end
-202:       end
-203: 
-204:       k > @@j ? @@j = k : @@j += 1
-205:     end
-206: 
-207:     quals
-208:   end
-
- -
- - - - -
- - -
- - -
- - want_feat?(feat) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 210
-210:   def want_feat?(feat)
-211:     if @hash_feats
-212:       if @hash_feats[feat.upcase.to_sym]
-213:         return true
-214:       else
-215:         return false
-216:       end
-217:     else
-218:       return true
-219:     end
-220:   end
-
- -
- - - - -
- - -
- - -
- - want_qual?(qual) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 222
-222:   def want_qual?(qual)
-223:     if @hash_quals
-224:       if @hash_quals[qual.upcase.to_sym]
-225:         return true
-226:       else
-227:         return false
-228:       end
-229:     else
-230:       return true
-231:     end
-232:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Locator.html b/code_ruby/Maasha/lib/doc/Locator.html deleted file mode 100644 index 95dadba..0000000 --- a/code_ruby/Maasha/lib/doc/Locator.html +++ /dev/null @@ -1,586 +0,0 @@ - - - - - - - Class: Locator - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Locator

- -
- -
- - - - - - -
-

Attributes

- - -
- - - - -
- locator[RW] -
- -
- - - -
-
- -
- - - - -
- seq[RW] -
- -
- - - -
-
- -
- - - - -
- subseq[RW] -
- -
- - - -
-
- -
- - - - -
-

Public Class Methods

- - -
- - -
- - new(locator, seq) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 242
-242:   def initialize(locator, seq)
-243:     @locator = locator
-244:     @seq     = seq
-245:     @subseq  = Seq.new(nil, "", "dna")
-246:     parse_locator(locator)
-247:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - s_beg() - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 257
-257:   def s_beg
-258:     if @locator =~ /(\d+)/
-259:       return $1.to_i - 1
-260:     end
-261:   end
-
- -
- - - - -
- - -
- - -
- - s_end() - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 263
-263:   def s_end
-264:     if @locator.reverse =~ /(\d+)/
-265:       return $1.reverse.to_i - 1
-266:     end
-267:   end
-
- -
- - - - -
- - -
- - -
- - strand() - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 249
-249:   def strand
-250:     if @locator.match("complement")
-251:       return "-"
-252:     else
-253:       return "+"
-254:     end
-255:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - balance_parens?(locator) - click to toggle source - -
- -
- - - - - -
-
-     # File genbank.rb, line 342
-342:   def balance_parens?(locator)
-343:     parens = 0
-344: 
-345:     locator.each_char do |char|
-346:       case char
-347:       when '(' then parens += 1
-348:       when ')' then parens -= 1
-349:       end
-350:     end
-351: 
-352:     if parens == 0
-353:       return true
-354:     else
-355:       return false
-356:     end
-357:   end
-
- -
- - - - -
- - -
- - -
- - parse_locator(locator, join = nil, comp = nil, order = nil) - click to toggle source - -
- -
- -

-Method that uses recursion to parse a locator string from a feature table -and fetches the appropriate subsequence. the operators join(), -complement(), and order() are handled. the locator string is broken into a -comma separated lists, and modified if the parens donnot balance. otherwise -the comma separated list of ranges are stripped from operators, and the -subsequence are fetched and handled according to the operators. SNP -locators are also dealt with (single positions). -

- - - -
-
-     # File genbank.rb, line 279
-279:   def parse_locator(locator, join = nil, comp = nil, order = nil)
-280:     intervals = locator.split(",")
-281: 
-282:     unless balance_parens?(intervals.first)   # locator includes a join/comp/order of several ranges
-283:       case locator
-284:       when /^join\((.*)\)$/
-285:         locator = $1
-286:         join     = true
-287:       when /^complement\((.*)\)$/
-288:         locator = $1
-289:         comp     = true
-290:       when /^order\((.*)\)$/
-291:         locator = $1
-292:         order    = true
-293:       end
-294: 
-295:       parse_locator(locator, join, comp, order)
-296:     else
-297:       intervals.each do |interval|
-298:         case interval
-299:         when /^join\((.*)\)$/
-300:           locator = $1
-301:           join    = true
-302:           parse_locator(locator, join, comp, order)
-303:         when /^complement\((.*)\)$/
-304:           locator = $1
-305:           comp    = true
-306:           parse_locator(locator, join, comp, order)
-307:         when /^order\((.*)\)$/
-308:           locator = $1
-309:           order   = true
-310:           parse_locator(locator, join, comp, order)
-311:         when /^[<>]?(\d+)[^\d]+(\d+)$/
-312:           int_beg = $1.to_i - 1
-313:           int_end = $2.to_i - 1
-314: 
-315:           newseq = Seq.new(nil, @seq.seq[int_beg...int_end], "dna")
-316: 
-317:                                         unless newseq.seq.nil?
-318:                                                 newseq.revcomp if comp
-319: 
-320:                                                 @subseq.seq << (order ? " " + newseq.seq : newseq.seq)
-321:                                         end
-322:         when /^(\d+)$/
-323:           pos = $1.to_i - 1
-324: 
-325:           newseq = Seq.new(nil, @seq.seq[pos], "dna")
-326: 
-327:                                         unless newseq.seq.nil?
-328:                 newseq.revcomp if comp 
-329: 
-330:                 @subseq.seq << (order ? " " + newseq.seq : newseq.seq)
-331:                                         end
-332:         else
-333:           $stderr.puts "WARNING: Could not match locator -> #{locator}";
-334:           @subseq.seq << ""
-335:         end
-336:       end
-337:     end
-338: 
-339:     return @subseq
-340:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/LocatorError.html b/code_ruby/Maasha/lib/doc/LocatorError.html deleted file mode 100644 index 6cf4391..0000000 --- a/code_ruby/Maasha/lib/doc/LocatorError.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - - Class: LocatorError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

LocatorError

- -
-

-Error class for all exceptions to do with Genbank/EMBL/DDBJ feature table -locators. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/OptionHandler.html b/code_ruby/Maasha/lib/doc/OptionHandler.html deleted file mode 100644 index d9bc163..0000000 --- a/code_ruby/Maasha/lib/doc/OptionHandler.html +++ /dev/null @@ -1,1028 +0,0 @@ - - - - - - - Class: OptionHandler - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- - - -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

OptionHandler

- -
-

-Class for parsing argv using OptionParser according to given casts. Default -options are set, file glob expressions expanded, and options are checked -according to the casts. Usage information is printed and exit called if -required. -

- -
- - - -
-

Constants

-
- -
REGEX_LIST
- -
- - -
REGEX_INT
- -
- - -
REGEX_STRING
- -
- - -
-
- - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(argv, casts, script_path, test=nil) - click to toggle source - -
- -
- - - - - -
-
-     # File biopieces.rb, line 266
-266:   def initialize(argv, casts, script_path, test=nil)
-267:     @argv        = argv
-268:     @casts       = casts
-269:     @script_path = script_path
-270:     @test        = test
-271:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - options_check() - click to toggle source - -
- -
- -

-Check all options according to casts. -

- - - -
-
-     # File biopieces.rb, line 407
-407:   def options_check
-408:     @casts.each do |cast|
-409:       options_check_mandatory(cast)
-410:       options_check_int(cast)
-411:       options_check_uint(cast)
-412:       options_check_file(cast)
-413:       options_check_files(cast)
-414:       options_check_dir(cast)
-415:       options_check_allowed(cast)
-416:       options_check_disallowed(cast)
-417:     end
-418:   end
-
- -
- - - - -
- - -
- - -
- - options_check_allowed(cast) - click to toggle source - -
- -
- -

-Check options and raise unless allowed. -

- - - -
-
-     # File biopieces.rb, line 470
-470:   def options_check_allowed(cast)
-471:     if cast[:allowed] and @options.has_key? cast[:long]
-472:       allowed_hash = {}
-473:       cast[:allowed].split(',').each { |a| allowed_hash[a.to_s] = 1 }
-474:   
-475:       raise ArgumentError, "Argument '#{@options[cast[:long]]}' to --#{cast[:long]} not allowed" unless allowed_hash.has_key? @options[cast[:long]].to_s
-476:     end
-477:   end
-
- -
- - - - -
- - -
- - -
- - options_check_dir(cast) - click to toggle source - -
- -
- -

-Check dir! type argument and raise if directory don’t exist. -

- - - -
-
-     # File biopieces.rb, line 463
-463:   def options_check_dir(cast)
-464:     if cast[:type] == 'dir!' and @options.has_key? cast[:long]
-465:       raise ArgumentError, "No such directory: '#{@options[cast[:long]]}'" unless File.directory? @options[cast[:long]]
-466:     end
-467:   end
-
- -
- - - - -
- - -
- - -
- - options_check_disallowed(cast) - click to toggle source - -
- -
- -

-Check disallowed argument values and raise if disallowed. -

- - - -
-
-     # File biopieces.rb, line 480
-480:   def options_check_disallowed(cast)
-481:     if cast[:disallowed] and @options.has_key? cast[:long]
-482:       cast[:disallowed].split(',').each do |val|
-483:         raise ArgumentError, "Argument '#{@options[cast[:long]]}' to --#{cast[:long]} is disallowed" if val.to_s == @options[cast[:long]].to_s
-484:       end
-485:     end
-486:   end
-
- -
- - - - -
- - -
- - -
- - options_check_file(cast) - click to toggle source - -
- -
- -

-Check file! type argument and raise if file don’t exists. -

- - - -
-
-     # File biopieces.rb, line 446
-446:   def options_check_file(cast)
-447:     if cast[:type] == 'file!' and @options.has_key? cast[:long]
-448:       raise ArgumentError, "No such file: '#{@options[cast[:long]]}'" unless File.file? @options[cast[:long]]
-449:     end
-450:   end
-
- -
- - - - -
- - -
- - -
- - options_check_files(cast) - click to toggle source - -
- -
- -

-Check files! type argument and raise if files don’t exists. -

- - - -
-
-     # File biopieces.rb, line 453
-453:   def options_check_files(cast)
-454:     if cast[:type] == 'files!' and @options.has_key? cast[:long]
-455:       @options[cast[:long]].each do |path|
-456:         next if path == "-"
-457:         raise ArgumentError, "File not readable: '#{path}'" unless File.readable? path
-458:       end
-459:     end
-460:   end
-
- -
- - - - -
- - -
- - -
- - options_check_int(cast) - click to toggle source - -
- -
- -

-Check int type option and raise if not an integer. -

- - - -
-
-     # File biopieces.rb, line 428
-428:   def options_check_int(cast)
-429:     if cast[:type] == 'int' and @options.has_key? cast[:long]
-430:       unless @options[cast[:long]].is_a? Integer
-431:         raise ArgumentError, "Argument to --#{cast[:long]} must be an integer, not '#{@options[cast[:long]]}'"
-432:       end
-433:     end
-434:   end
-
- -
- - - - -
- - -
- - -
- - options_check_mandatory(cast) - click to toggle source - -
- -
- -

-Check if a mandatory option is set and raise if it isn’t. -

- - - -
-
-     # File biopieces.rb, line 421
-421:   def options_check_mandatory(cast)
-422:     if cast[:mandatory]
-423:       raise ArgumentError, "Mandatory argument: --#{cast[:long]}" unless @options.has_key? cast[:long]
-424:     end
-425:   end
-
- -
- - - - -
- - -
- - -
- - options_check_uint(cast) - click to toggle source - -
- -
- -

-Check uint type option and raise if not an unsinged integer. -

- - - -
-
-     # File biopieces.rb, line 437
-437:   def options_check_uint(cast)
-438:     if cast[:type] == 'uint' and @options.has_key? cast[:long]
-439:       unless @options[cast[:long]].is_a? Integer and @options[cast[:long]] >= 0
-440:         raise ArgumentError, "Argument to --#{cast[:long]} must be an unsigned integer, not '#{@options[cast[:long]]}'"
-441:       end
-442:     end
-443:   end
-
- -
- - - - -
- - -
- - -
- - options_default() - click to toggle source - -
- -
- -

-Set default options value from cast unless a value is set. -

- - - -
-
-     # File biopieces.rb, line 374
-374:   def options_default
-375:     @casts.each do |cast|
-376:       if cast[:default]
-377:         @options[cast[:long]] = cast[:default] unless @options.has_key? cast[:long]
-378:       end
-379:     end
-380:   end
-
- -
- - - - -
- - -
- - -
- - options_glob() - click to toggle source - -
- -
- -

-Expands glob expressions to a full list of paths. Examples: -“*.fna” or “foo.fna,*.fna” or -“foo.fna,/bar/*.fna“ -

- - - -
-
-     # File biopieces.rb, line 384
-384:   def options_glob
-385:     @casts.each do |cast|
-386:       if cast[:type] == 'files' or cast[:type] == 'files!'
-387:         if @options.has_key? cast[:long]
-388:           files = []
-389:         
-390:           @options[cast[:long]].each do |path|
-391:             if path.include? "*"
-392:               Dir.glob(path).each do |file|
-393:                 files << file if File.file? file
-394:               end
-395:             else
-396:               files << path
-397:             end
-398:           end
-399: 
-400:           @options[cast[:long]] = files
-401:         end
-402:       end
-403:     end
-404:   end
-
- -
- - - - -
- - -
- - -
- - options_parse() - click to toggle source - -
- -
- -

-Parse options from argv using OptionParser and casts denoting long and -short option names. Usage information is printed and exit called. A hash -with options is returned. -

- - - -
-
-     # File biopieces.rb, line 276
-276:   def options_parse
-277:     @options = {}
-278: 
-279:     option_parser = OptionParser.new do |option|
-280:       @casts.each do |cast|
-281:         case cast[:type]
-282:         when 'flag'
-283:           option.on("-#{cast[:short]}", "--#{cast[:long]}") do |o|
-284:             @options[cast[:long]] = o
-285:           end
-286:         when 'float'
-287:           option.on("-#{cast[:short]}", "--#{cast[:long]} F", Float) do |f|
-288:             @options[cast[:long]] = f
-289:           end
-290:         when 'string'
-291:           option.on("-#{cast[:short]}", "--#{cast[:long]} S", String) do |s|
-292:             @options[cast[:long]] = s.to_sym
-293:           end
-294:         when REGEX_LIST
-295:           option.on( "-#{cast[:short]}", "--#{cast[:long]} A", Array) do |a|
-296:             @options[cast[:long]] = a
-297:           end
-298:         when REGEX_INT
-299:           option.on("-#{cast[:short]}", "--#{cast[:long]} I", Integer) do |i|
-300:             @options[cast[:long]] = i
-301:           end
-302:         when REGEX_STRING
-303:           option.on("-#{cast[:short]}", "--#{cast[:long]} S", String) do |s|
-304:             @options[cast[:long]] = s
-305:           end
-306:         else
-307:           raise ArgumentError, "Unknown option type: '#{cast[:type]}'"
-308:         end
-309:       end
-310:     end
-311: 
-312:     option_parser.parse!(@argv)
-313: 
-314:     if print_usage_full?
-315:       print_usage_and_exit(true)
-316:     elsif print_usage_short?
-317:       print_usage_and_exit
-318:     end
-319: 
-320:     options_default
-321:     options_glob
-322:     options_check
-323: 
-324:     @options
-325:   end
-
- -
- - - - -
- - - - - - - - - - - -
- - -
- - wiki_path() - click to toggle source - -
- -
- -

-Given the script name determine the path of the wiki file with the usage -info. -

- - - -
-
-     # File biopieces.rb, line 328
-328:   def wiki_path
-329:     path = ENV["BP_DIR"] + "/bp_usage/" + File.basename(@script_path) + ".wiki"
-330:     raise "No such wiki file: #{path}" unless File.file? path
-331:     path
-332:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Read.html b/code_ruby/Maasha/lib/doc/Read.html deleted file mode 100644 index 32cd91e..0000000 --- a/code_ruby/Maasha/lib/doc/Read.html +++ /dev/null @@ -1,646 +0,0 @@ - - - - - - - Class: Read - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Read

- -
-

-Class containing data accessor methods for an SFF -entry and methods for manipulating this entry. -

- -
- - - - - - -
-

Attributes

- - -
- - - - -
- read_header_length[RW] -
- -
- - - -
-
- -
- - - - -
- name_length[RW] -
- -
- - - -
-
- -
- - - - -
- number_of_bases[RW] -
- -
- - - -
-
- -
- - - - -
- clip_qual_left[RW] -
- -
- - - -
-
- -
- - - - -
- clip_qual_right[RW] -
- -
- - - -
-
- -
- - - - -
- clip_adapter_left[RW] -
- -
- - - -
-
- -
- - - - -
- clip_adaptor_right[RW] -
- -
- - - -
-
- -
- - - - -
- name[RW] -
- -
- - - -
-
- -
- - - - -
- flowgram_values[RW] -
- -
- - - -
-
- -
- - - - -
- flow_index_per_base[RW] -
- -
- - - -
-
- -
- - - - -
- bases[RW] -
- -
- - - -
-
- -
- - - - -
- quality_scores[RW] -
- -
- - - -
-
- -
- - - - -
- x_pos[RW] -
- -
- - - -
-
- -
- - - - -
- y_pos[RW] -
- -
- - - -
-
- -
- - - - -
-

Public Instance Methods

- - -
- - -
- - clip() - click to toggle source - -
- -
- -

-Method that clips sequence (i.e. trims) according to clip_qual_left and clip_qual_right information. -

- - - -
-
-     # File sff.rb, line 228
-228:   def clip
-229:     self.bases          = self.bases[self.clip_qual_left - 1 ... self.clip_qual_right]
-230:     self.quality_scores = self.quality_scores[self.clip_qual_left - 1 ... self.clip_qual_right]
-231:   end
-
- -
- - - - -
- - -
- - -
- - mask() - click to toggle source - -
- -
- -

-Method that soft masks the sequence (i.e. lowercases sequence) according to -clip_qual_left and clip_qual_right information. -

- - - -
-
-     # File sff.rb, line 218
-218:   def mask
-219:     left   = self.bases[0 ... self.clip_qual_left - 1].downcase
-220:     middle = self.bases[self.clip_qual_left - 1 ... self.clip_qual_right]
-221:     right  = self.bases[self.clip_qual_right ... self.bases.length].downcase
-222: 
-223:     self.bases = left + middle + right
-224:   end
-
- -
- - - - -
- - -
- - -
- - to_bp() - click to toggle source - -
- -
- -

-Method that converts a Read object’s data to -a Biopiece record (a hash). -

- - - -
-
-     # File sff.rb, line 197
-197:   def to_bp
-198:     coordinates_get
-199: 
-200:     hash = {}
-201: 
-202:     hash[:SEQ_NAME]           = self.name
-203:     hash[:SEQ]                = self.bases
-204:     hash[:SEQ_LEN]            = self.bases.length
-205:     hash[:CLIP_QUAL_LEFT]     = self.clip_qual_left     - 1
-206:     hash[:CLIP_QUAL_RIGHT]    = self.clip_qual_right    - 1
-207:     hash[:CLIP_ADAPTOR_LEFT]  = self.clip_adapter_left  - 1
-208:     hash[:CLIP_ADAPTOR_RIGHT] = self.clip_adaptor_right - 1
-209:     hash[:SCORES]             = self.quality_scores.map { |i| (i += 64).chr }.join ""
-210:     hash[:X_POS]              = self.x_pos
-211:     hash[:Y_POS]              = self.y_pos
-212: 
-213:     hash
-214:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - coordinates_get() - click to toggle source - -
- -
- -

-Method that extracts the X/Y coordinates from an SFF -read name encoded with base36. -

- - - -
-
-     # File sff.rb, line 237
-237:   def coordinates_get
-238:     base36 = self.name[5, 5]
-239:     num    = Base36.decode(base36)
-240: 
-241:     self.x_pos = num >> BIT_SHIFT
-242:     self.y_pos = num &  BIT_MASK
-243:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/SFF.html b/code_ruby/Maasha/lib/doc/SFF.html deleted file mode 100644 index f3497f6..0000000 --- a/code_ruby/Maasha/lib/doc/SFF.html +++ /dev/null @@ -1,712 +0,0 @@ - - - - - - - Class: SFF - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - - - -
-

Included Modules

- -
- -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

SFF

- -
-

-Class containing methods to parse SFF files: www.ncbi.nlm.nih.gov/Traces/trace.cgi?cmd=show&f=formats&m=doc&s=format#sff -

- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - new(io) - click to toggle source - -
- -
- -

-Method to initialize an SFF object along with -instance variables pertaining to the SFF header -section. -

- - - -
-
-    # File sff.rb, line 58
-58:   def initialize(io)
-59:     @io                       = io
-60:     @magic_number             = 0
-61:     @version                  = ""
-62:     @index_offset             = 0
-63:     @index_length             = 0
-64:     @number_of_reads          = 0
-65:     @header_length            = 0
-66:     @key_length               = 0
-67:     @number_of_flows_per_read = 0
-68:     @flowgram_format_code     = 0
-69:     @flow_chars               = ""
-70:     @key_sequence             = ""
-71:     @eight_byte_padding       = 0
-72: 
-73:     header_parse
-74:   end
-
- -
- - - - -
- - -
- - -
- - open(*args) - click to toggle source - -
- -
- -

-Class method for opening SFF files. -

- - - -
-
-    # File sff.rb, line 41
-41:   def self.open(*args)
-42:     ios = File.open(*args)
-43: 
-44:     if block_given?
-45:       begin
-46:         yield self.new(ios)
-47:       ensure
-48:         ios.close
-49:       end
-50:     else
-51:       return self.new(ios)
-52:     end
-53:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - close() - click to toggle source - -
- -
- -

-Method to close ios. -

- - - -
-
-    # File sff.rb, line 77
-77:   def close
-78:     @io.close
-79:   end
-
- -
- - - - -
- - -
- - -
- - each() - click to toggle source - -
- -
- -

-Method to iterate over each SFF entry. -

- - - -
-
-    # File sff.rb, line 82
-82:   def each
-83:     while (read = read_parse) do
-84:       yield read
-85:     end
-86: 
-87:     self   # conventionally
-88:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - check_header_length() - click to toggle source - -
- -
- -

-Method to check the header length of an SFF file. -Raises an error if the header length don’t match the file position -after reading the header section. -

- - - -
-
-     # File sff.rb, line 183
-183:   def check_header_length
-184:     raise SFFError, "Bad header length: #{header_length}" unless @io.pos == @header_length
-185:   end
-
- -
- - - - -
- - -
- - -
- - check_magic_number() - click to toggle source - -
- -
- -

-Method to check the magic number of an SFF file. -Raises an error if the magic number don’t match. -

- - - -
-
-     # File sff.rb, line 170
-170:   def check_magic_number
-171:     raise SFFError, "Badly formatted SFF file." unless @magic_number == 779314790
-172:   end
-
- -
- - - - -
- - -
- - -
- - check_version() - click to toggle source - -
- -
- -

-Method to check the version number of an SFF file. -Raises an error if the version don’t match. -

- - - -
-
-     # File sff.rb, line 176
-176:   def check_version
-177:     raise SFFError, "Wrong version: #{@version}" unless @version.to_i == 1
-178:   end
-
- -
- - - - -
- - -
- - -
- - fast_forward() - click to toggle source - -
- -
- -

-Method that reads the eight_byte_padding field found at the end of the data -section and fast forwards, i.e. move the file read pointer, so that the -length of the section is divisible by 8. -

- - - -
-
-     # File sff.rb, line 122
-122:   def fast_forward
-123:     eight_byte_padding = 8 - (@io.pos % 8)
-124: 
-125:     @io.read(eight_byte_padding) unless eight_byte_padding == 8
-126:   end
-
- -
- - - - -
- - -
- - -
- - header_parse() - click to toggle source - -
- -
- -

-Method to parse the SFF file’s header section -and load the information into the instance variables. -

- - - -
-
-     # File sff.rb, line 94
- 94:   def header_parse
- 95:     template     = "NC4N2NNnnnC"
- 96:     bits_in_uint = 32
- 97: 
- 98:     data = @io.read(31).unpack(template)
- 99:     
-100:     @magic_number             = data[0]
-101:     @version                  = data[1 .. 4].join ""
-102:     @index_offset             = (data[5] << bits_in_uint) | data[6]
-103:     @index_length             = data[7]
-104:     @number_of_reads          = data[8]
-105:     @header_length            = data[9]
-106:     @key_length               = data[10]
-107:     @number_of_flows_per_read = data[11]
-108:     @flowgram_format_code     = data[12]
-109:     @flow_chars               = @io.read(@number_of_flows_per_read).unpack("A*").join ""
-110:     @key_sequence             = @io.read(@key_length).unpack("A*").join ""
-111: 
-112:     fast_forward
-113: 
-114:     check_magic_number
-115:     check_version
-116:     check_header_length
-117:   end
-
- -
- - - - -
- - -
- - -
- - read_parse() - click to toggle source - -
- -
- -

-Method to parse a read section of an SFF file. -

- - - -
-
-     # File sff.rb, line 129
-129:   def read_parse
-130:     return nil if @number_of_reads == @@count
-131: 
-132:     template = "nnNnnnn"
-133: 
-134:     read = Read.new()
-135: 
-136:     data = @io.read(16).unpack(template)
-137: 
-138:     read.read_header_length  = data[0]
-139:     read.name_length         = data[1]
-140:     read.number_of_bases     = data[2]
-141:     read.clip_qual_left      = data[3]
-142:     read.clip_qual_right     = data[4]
-143:     read.clip_adapter_left   = data[5]
-144:     read.clip_adaptor_right  = data[6]
-145:     read.name                = @io.read(read.name_length).unpack("A*").join ""
-146: 
-147:     fast_forward
-148: 
-149:     @io.read(2 * @number_of_flows_per_read) # skip through flowgram_values
-150:     @io.read(read.number_of_bases)          # skip through flow_index_per_base
-151: 
-152:     # NB! Parsing of flowgram_values and flow_index_per_base is currently disabled since these are not needed.
-153:     # read.flowgram_values     = @io.read(2 * @number_of_flows_per_read).unpack("n*").map { |val| val = sprintf("%.2f", val * 0.01) }
-154:     # flow_index_per_base      = @io.read(read.number_of_bases).unpack("C*")
-155:     # (1 ... flow_index_per_base.length).each { |i| flow_index_per_base[i] += flow_index_per_base[i - 1] }
-156:     # read.flow_index_per_base = flow_index_per_base
-157: 
-158:     read.bases               = @io.read(read.number_of_bases).unpack("A*").join ""
-159:     read.quality_scores      = @io.read(read.number_of_bases).unpack("C*")
-160: 
-161:     fast_forward
-162: 
-163:     @@count += 1
-164: 
-165:     read
-166:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/SFFError.html b/code_ruby/Maasha/lib/doc/SFFError.html deleted file mode 100644 index 5ce72a1..0000000 --- a/code_ruby/Maasha/lib/doc/SFFError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: SFFError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

SFFError

- -
-

-Error class for all exceptions to do with SFF. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Seq.html b/code_ruby/Maasha/lib/doc/Seq.html deleted file mode 100644 index b458f01..0000000 --- a/code_ruby/Maasha/lib/doc/Seq.html +++ /dev/null @@ -1,1825 +0,0 @@ - - - - - - - Class: Seq - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - - - -
-

Included Modules

- -
- -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Seq

- -
- -
- - - - - - -
-

Attributes

- - -
- - - - -
- seq_name[RW] -
- -
- - - -
-
- -
- - - - -
- seq[RW] -
- -
- - - -
-
- -
- - - - -
- type[RW] -
- -
- - - -
-
- -
- - - - -
- qual[RW] -
- -
- - - -
-
- -
- - - - -
-

Public Class Methods

- - -
- - -
- - generate_oligos(length, type) - click to toggle source - -
- -
- -

-Method that generates all possible oligos of a specifed length and type. -

- - - -
-
-    # File seq.rb, line 47
-47:   def self.generate_oligos(length, type)
-48:     raise SeqError, "Cannot generate negative oligo length: #{length}" if length <= 0
-49: 
-50:     case type.downcase
-51:     when /dna/     then alph = DNA
-52:     when /rna/     then alph = RNA
-53:     when /protein/ then alph = PROTEIN
-54:     else
-55:       raise SeqError, "Unknown sequence type: #{type}"
-56:     end
-57: 
-58:     oligos = [""]
-59: 
-60:     (1 .. length).each do
-61:       list = []
-62: 
-63:       oligos.each do |oligo|
-64:         alph.each do |char|
-65:           list << oligo + char
-66:         end
-67:       end
-68: 
-69:       oligos = list
-70:     end
-71: 
-72:     oligos
-73:   end
-
- -
- - - - -
- - -
- - -
- - new(seq_name = nil, seq = nil, type = nil, qual = nil) - click to toggle source - -
- -
- -

-Initialize a sequence object with the following arguments: -

-
    -
  • -seq_name: Name of the sequence. -

    -
  • -
  • -seq: The sequence. -

    -
  • -
  • -type: The sequence type - DNA, RNA, or protein -

    -
  • -
  • -qual: An Illumina type quality scores string. -

    -
  • -
- - - -
-
-    # File seq.rb, line 80
-80:   def initialize(seq_name = nil, seq = nil, type = nil, qual = nil)
-81:     @seq_name = seq_name
-82:     @seq      = seq
-83:     @type     = type
-84:     @qual     = qual
-85:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - adaptor_clip_left(adaptor, hd_percent = 0) - click to toggle source - -
- -
- -

-Method that locates an adaptor or part thereof in the sequence of a Seq object beginning from the left and removes the -adaptor sequence if found. The hd_percent is used to calculate the maximum -hamming distance allowed for all possible overlaps. -

- - - -
-
-     # File seq.rb, line 377
-377:   def adaptor_clip_left(adaptor, hd_percent = 0)
-378:     pos = self.adaptor_locate_left(adaptor, hd_percent)
-379: 
-380:     if pos > 0
-381:       self.seq  = self.seq[pos + 1 ... self.length]
-382:       self.qual = self.qual[pos + 1 ... self.qual.length] unless self.qual.nil?
-383:     end
-384:   end
-
- -
- - - - -
- - -
- - -
- - adaptor_clip_right(adaptor, hd_percent = 0) - click to toggle source - -
- -
- -

-Method that locates an adaptor or part thereof in the sequence of a Seq object beginning from the right and removes the -adaptor sequence if found. The hd_percent is used to calculate the maximum -hamming distance allowed for all possible overlaps. -

- - - -
-
-     # File seq.rb, line 364
-364:   def adaptor_clip_right(adaptor, hd_percent = 0)
-365:     pos = self.adaptor_locate_right(adaptor, hd_percent)
-366: 
-367:     if pos > 0
-368:       self.seq  = self.seq[0 ... pos]
-369:       self.qual = self.qual[0 ... pos] unless self.qual.nil?
-370:     end
-371:   end
-
- -
- - - - -
- - -
- - -
- - adaptor_locate_left(adaptor, hd_percent = 0) - click to toggle source - -
- -
- -

-Method that locates an adaptor or part thereof in the sequence of a Seq object beginning from the left. Returns the -location in the sequence that overlaps with the adaptor or -1 if the -adaptor was not found. The hd_percent is used to calculate the maximum -hamming distance allowed for all possible overlaps. -

- - - -
-
-     # File seq.rb, line 340
-340:   def adaptor_locate_left(adaptor, hd_percent = 0)
-341:     raise SeqError, "Hamming distance percent out of range #{hd_percent}" unless (0 .. 100).include? hd_percent
-342:     pos = adaptor.length
-343: 
-344:     while pos > 0
-345:       len          = pos
-346:       subseq       = self.seq[0 ... len].upcase
-347:       subadaptor   = adaptor[adaptor.length - len ... adaptor.length].upcase
-348:       m            = Hamming.new(subseq)
-349:       hamming_dist = m.match(subadaptor)
-350:       hamming_max  = (len * hd_percent * 0.01).round
-351: 
-352:       pos -= 1
-353: 
-354:       return pos if hamming_dist <= hamming_max
-355:     end
-356:     
-357:     1
-358:   end
-
- -
- - - - -
- - -
- - -
- - adaptor_locate_right(adaptor, hd_percent = 0) - click to toggle source - -
- -
- -

-Method that locates an adaptor or part thereof in the sequence of a Seq object beginning from the right. Returns the -location in the sequence that overlaps with the adaptor or -1 if the -adaptor was not found. The hd_percent is used to calculate the maximum -hamming distance allowed for all possible overlaps. -

- - - -
-
-     # File seq.rb, line 316
-316:   def adaptor_locate_right(adaptor, hd_percent = 0)
-317:     raise SeqError, "Hamming distance percent out of range #{hd_percent}" unless (0 .. 100).include? hd_percent
-318:     pos = self.length - adaptor.length
-319: 
-320:     while pos < self.length
-321:       len          = self.length - pos
-322:       subseq       = self.seq[pos ... pos + len].upcase
-323:       subadaptor   = adaptor[0 ... len].upcase
-324:       m            = Hamming.new(subseq)
-325:       hamming_dist = m.match(subadaptor)
-326:       hamming_max  = (len * hd_percent * 0.01).round
-327:       return pos if hamming_dist <= hamming_max
-328: 
-329:       pos += 1
-330:     end
-331: 
-332:     1
-333:   end
-
- -
- - - - -
- - -
- - -
- - complement() - click to toggle source - -
- -
- -

-Method that complements sequence including ambiguity codes. -

- - - -
-
-     # File seq.rb, line 196
-196:   def complement
-197:     raise SeqError, "Cannot complement 0 length sequence" if self.length == 0
-198: 
-199:     if self.is_dna?
-200:       self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'TCGAAYRWSKMDHBVNtcgaayrwskmdhbvn' )
-201:     elsif self.is_rna?
-202:       self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'UCGAAYRWSKMDHBVNucgaayrwskmdhbvn' )
-203:     else
-204:       raise SeqError, "Cannot complement sequence type: #{self.type}"
-205:     end
-206:   end
-
- -
- - - - -
- - -
- - -
- - composition() - click to toggle source - -
- -
- -

-Method that returns the residue compositions of a sequence in a hash where -the key is the residue and the value is the residue count. -

- - - -
-
-     # File seq.rb, line 272
-272:   def composition
-273:     comp = Hash.new(0);
-274: 
-275:     self.seq.upcase.each_char do |char|
-276:       comp[char] += 1
-277:     end
-278: 
-279:     comp
-280:   end
-
- -
- - - - -
- - -
- - -
- - convert_phred2illumina!() - click to toggle source - -
- -
- -

-Method to convert the quality scores from a specified base to another base. -

- - - -
-
-     # File seq.rb, line 388
-388:   def convert_phred2illumina!
-389:     self.qual.gsub! /./ do |score|
-390:       score_phred  = score.ord - SCORE_PHRED
-391:       raise SeqError, "Bad Phred score: #{score} (#{score_phred})" unless (0 .. 40).include? score_phred
-392:       score_illumina = score_phred + SCORE_ILLUMINA
-393:       score          = score_illumina.chr
-394:     end
-395:   end
-
- -
- - - - -
- - -
- - -
- - convert_solexa2illumina!() - click to toggle source - -
- -
- -

-Method to convert the quality scores from Solexa odd/ratio to Illumina -format. -

- - - -
-
-     # File seq.rb, line 399
-399:   def convert_solexa2illumina!
-400:     self.qual.gsub! /./ do |score|
-401:       score = solexa_char2illumina_char(score)
-402:     end
-403:   end
-
- -
- - - - -
- - -
- - -
- - generate(length, type) - click to toggle source - -
- -
- -

-Method that generates a random sequence of a given length and type. -

- - - -
-
-     # File seq.rb, line 209
-209:   def generate(length, type)
-210:     raise SeqError, "Cannot generate sequence length < 1: #{length}" if length <= 0
-211: 
-212:     case type.downcase
-213:     when "dna"
-214:       alph = DNA
-215:     when "rna"
-216:       alph = RNA
-217:     when "protein"
-218:       alph = PROTEIN
-219:     else
-220:       raise SeqError, "Unknown sequence type: #{type}"
-221:     end
-222: 
-223:     seq_new   = Array.new(length) { alph[rand(alph.size)] }.join("")
-224:     self.seq  = seq_new
-225:     self.type = type.downcase
-226:     seq_new
-227:   end
-
- -
- - - - -
- - -
- - -
- - hard_mask() - click to toggle source - -
- -
- -

-Method that returns the percentage of hard masked residues or N’s in -a sequence. -

- - - -
-
-     # File seq.rb, line 301
-301:   def hard_mask
-302:     ((self.seq.upcase.scan("N").size.to_f / (self.len - self.indels).to_f) * 100).round(2)
-303:   end
-
- -
- - - - -
- - -
- - -
- - homopol_max(min = 1) - click to toggle source - -
- -
- -

-Method that returns the length of the longest homopolymeric stretch found -in a sequence. -

- - - -
-
-     # File seq.rb, line 284
-284:   def homopol_max(min = 1)
-285:     return 0 if self.seq.nil? or self.seq.empty?
-286: 
-287:     found = false
-288: 
-289:     self.seq.upcase.scan(/A{#{min},}|T{#{min},}|G{#{min},}|C{#{min},}|N{#{min},}/) do |match|
-290:       found = true
-291:       min   = match.size > min ? match.size : min
-292:     end
-293: 
-294:     return 0 unless found
-295:  
-296:     min
-297:   end
-
- -
- - - - -
- - -
- - -
- - indels() - click to toggle source - -
- -
- -

-Return the number indels in a sequence. -

- - - -
-
-    # File seq.rb, line 95
-95:   def indels
-96:     regex = Regexp.new(/[#{Regexp.escape(INDELS.join(""))}]/)
-97:     self.seq.scan(regex).size
-98:   end
-
- -
- - - - -
- - -
- - -
- - is_dna?() - click to toggle source - -
- -
- -

-Method that returns true is a given sequence type is DNA. -

- - - -
-
-     # File seq.rb, line 101
-101:   def is_dna?
-102:     self.type == 'dna'
-103:   end
-
- -
- - - - -
- - -
- - -
- - is_protein?() - click to toggle source - -
- -
- -

-Method that returns true is a given sequence type is protein. -

- - - -
-
-     # File seq.rb, line 111
-111:   def is_protein?
-112:     self.type == 'protein'
-113:   end
-
- -
- - - - -
- - -
- - -
- - is_rna?() - click to toggle source - -
- -
- -

-Method that returns true is a given sequence type is RNA. -

- - - -
-
-     # File seq.rb, line 106
-106:   def is_rna?
-107:     self.type == 'rna'
-108:   end
-
- -
- - - - -
- - -
- - -
- - len() - click to toggle source - -
- -
- - - - - -
- - - - -
- Alias for: length -
- -
- - -
- - -
- - length() - click to toggle source - -
- -
- -

-Returns the length of a sequence. -

- - - -
-
-    # File seq.rb, line 88
-88:   def length
-89:     self.seq.nil? ? 0 : self.seq.length
-90:   end
-
- -
- - -
- Also aliased as: len -
- - - -
- - -
- - -
- - match(patter, pos) - click to toggle source - -
- -
- -
-  seq.match(pattern[, pos ] [, hd=max] [, ed=max]) -> matchdata or nil
-
-

-Method to locate a pattern in a sequence and return the position of the -match or nil if no match was found. Optional maximum Hamming and Edit -distance can be specified. -

- - - -
-
-     # File seq.rb, line 411
-411:   def match(patter, pos)
-412:   end
-
- -
- - - - -
- - -
- - -
- - revcomp() - click to toggle source - -
- -
- - - - - -
- - - - -
- Alias for: reverse_complement -
- -
- - -
- - -
- - reverse() - click to toggle source - -
- -
- -

-Method to reverse the sequence. -

- - - -
-
-     # File seq.rb, line 191
-191:   def reverse
-192:     self.seq.reverse!
-193:   end
-
- -
- - - - -
- - -
- - -
- - reverse_complement() - click to toggle source - -
- -
- -

-Method to reverse complement sequence. -

- - - -
-
-     # File seq.rb, line 183
-183:   def reverse_complement
-184:     self.reverse
-185:     self.complement
-186:   end
-
- -
- - -
- Also aliased as: revcomp -
- - - -
- - -
- - -
- - soft_mask() - click to toggle source - -
- -
- -

-Method that returns the percentage of soft masked residues or lower cased -residues in a sequence. -

- - - -
-
-     # File seq.rb, line 307
-307:   def soft_mask
-308:     ((self.seq.scan(/[a-z]/).size.to_f / (self.len - self.indels).to_f) * 100).round(2)
-309:   end
-
- -
- - - - -
- - -
- - -
- - subseq(start, length = self.length - start) - click to toggle source - -
- -
- -

-Method that returns a subsequence of from a given start position and of a -given length. -

- - - -
-
-     # File seq.rb, line 231
-231:   def subseq(start, length = self.length - start)
-232:     raise SeqError, "subsequence start: #{start} < 0"                                                if start  < 0
-233:     raise SeqError, "subsequence length: #{length} < 1"                                              if length <= 0
-234:     raise SeqError, "subsequence start + length > Seq.length: #{start} + #{length} > #{self.length}" if start + length > self.length
-235: 
-236:     stop = start + length - 1
-237: 
-238:     seq  = self.seq[start .. stop]
-239:     qual = self.qual[start .. stop] unless self.qual.nil?
-240: 
-241:     Seq.new(self.seq_name, seq, self.type, qual)
-242:   end
-
- -
- - - - -
- - -
- - -
- - subseq!(start, length = self.length - start) - click to toggle source - -
- -
- -

-Method that replaces a sequence with a subsequence from a given start -position and of a given length. -

- - - -
-
-     # File seq.rb, line 246
-246:   def subseq!(start, length = self.length - start)
-247:     raise SeqError, "subsequence start: #{start} < 0"                                                if start  < 0
-248:     raise SeqError, "subsequence length: #{length} < 1"                                              if length <= 0
-249:     raise SeqError, "subsequence start + length > Seq.length: #{start} + #{length} > #{self.length}" if start + length > self.length
-250: 
-251:     stop = start + length - 1
-252: 
-253:     self.seq  = self.seq[start .. stop]
-254:     self.qual = self.qual[start .. stop] unless self.qual.nil?
-255:   end
-
- -
- - - - -
- - -
- - -
- - subseq_rand(length) - click to toggle source - -
- -
- -

-Method that returns a subsequence of a given length beginning at a random -position. -

- - - -
-
-     # File seq.rb, line 259
-259:   def subseq_rand(length)
-260:     if self.length - length + 1 == 0
-261:       start = 0
-262:     else
-263:       start = rand(self.length - length + 1)
-264:     end
-265: 
-266:     self.subseq(start, length)
-267:   end
-
- -
- - - - -
- - -
- - -
- - to_bp() - click to toggle source - -
- -
- -

-Method that given a Seq entry returns a Biopieces record (a hash). -

- - - -
-
-     # File seq.rb, line 132
-132:   def to_bp
-133:     raise SeqError, "Missing seq_name" if self.seq_name.nil?
-134:     raise SeqError, "Missing seq"      if self.seq.nil?
-135:     record             = {}
-136:     record[:SEQ_NAME] = self.seq_name
-137:     record[:SEQ]      = self.seq
-138:     record[:SEQ_LEN]  = self.length
-139:     record[:SCORES]   = self.qual if self.qual
-140:     record
-141:   end
-
- -
- - - - -
- - -
- - -
- - to_dna() - click to toggle source - -
- -
- -

-Method to reverse-transcribe RNA to DNA. -

- - - -
-
-     # File seq.rb, line 124
-124:   def to_dna
-125:     raise SeqError, "Cannot reverse-transcribe 0 length sequence" if self.length == 0
-126:     raise SeqError, "Cannot reverse-transcribe sequence type: #{self.type}" unless self.is_rna?
-127:     self.type = 'dna'
-128:     self.seq.tr!('Uu','Tt')
-129:   end
-
- -
- - - - -
- - -
- - -
- - to_fasta(wrap = nil) - click to toggle source - -
- -
- -

-Method that given a Seq entry returns a FASTA entry -(a string). -

- - - -
-
-     # File seq.rb, line 144
-144:   def to_fasta(wrap = nil)
-145:     raise SeqError, "Missing seq_name" if self.seq_name.nil?
-146:     raise SeqError, "Missing seq"      if self.seq.nil?
-147: 
-148:     seq_name = self.seq_name
-149:     seq      = self.seq
-150: 
-151:     unless wrap.nil?
-152:       seq.gsub! /(.{#{wrap}})/ do |match|
-153:         match << "\n"
-154:       end
-155: 
-156:       seq.chomp!
-157:     end
-158: 
-159:     ">#{seq_name}\n#{seq}\n"
-160:   end
-
- -
- - - - -
- - -
- - -
- - to_key() - click to toggle source - -
- -
- -

-Method that generates a unique key for a DNA sequence and return this key -as a Fixnum. -

- - - -
-
-     # File seq.rb, line 164
-164:   def to_key
-165:     key = 0
-166:     
-167:     self.seq.upcase.each_char do |char|
-168:       key <<= 2
-169:       
-170:       case char
-171:       when 'A' then key |= 0
-172:       when 'C' then key |= 1
-173:       when 'G' then key |= 2
-174:       when 'T' then key |= 3
-175:       else raise SeqError, "Bad residue: #{char}"
-176:       end
-177:     end
-178:     
-179:     key
-180:   end
-
- -
- - - - -
- - -
- - -
- - to_rna() - click to toggle source - -
- -
- -

-Method to transcribe DNA to RNA. -

- - - -
-
-     # File seq.rb, line 116
-116:   def to_rna
-117:     raise SeqError, "Cannot transcribe 0 length sequence" if self.length == 0
-118:     raise SeqError, "Cannot transcribe sequence type: #{self.type}" unless self.is_dna?
-119:     self.type = 'rna'
-120:     self.seq.tr!('Tt','Uu')
-121:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - solexa2phred(score) - click to toggle source - -
- -
- -

-Method to convert a Solexa score (odd ratio) to a phred (probability) -integer score. -

- - - -
-
-     # File seq.rb, line 418
-418:   def solexa2phred(score)
-419:     (10.0 * Math.log(10.0 ** (score / 10.0) + 1.0, 10)).to_i
-420:   end
-
- -
- - - - -
- - -
- - -
- - solexa_char2illumina_char(char) - click to toggle source - -
- -
- -

-Method to convert a Solexa score encoded using base 64 ASCII to a Phred -score encoded using base 64 ASCII. -

- - - -
-
-     # File seq.rb, line 424
-424:   def solexa_char2illumina_char(char)
-425:     score_solexa = char.ord - 64
-426:     score_phred  = solexa2phred(score_solexa)
-427:     (score_phred + 64).chr
-428:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/SeqError.html b/code_ruby/Maasha/lib/doc/SeqError.html deleted file mode 100644 index 16dca69..0000000 --- a/code_ruby/Maasha/lib/doc/SeqError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: SeqError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

SeqError

- -
-

-Error class for all exceptions to do with Seq. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Status.html b/code_ruby/Maasha/lib/doc/Status.html deleted file mode 100644 index a06e728..0000000 --- a/code_ruby/Maasha/lib/doc/Status.html +++ /dev/null @@ -1,524 +0,0 @@ - - - - - - - Class: Status - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Status

- -
-

-Class for manipulating the execution status of Biopieces by setting a status file with a time -stamp, process id, and command arguments. The status file is used for -creating log entries and for displaying the runtime status of Biopieces. -

- -
- - - - - - - - - -
-

Public Instance Methods

- - -
- - -
- - delete() - click to toggle source - -
- -
- -

-Delete status file. -

- - - -
-
-     # File biopieces.rb, line 547
-547:   def delete
-548:     File.delete(path)
-549:   end
-
- -
- - - - -
- - -
- - -
- - get_tmpdir() - click to toggle source - -
- -
- -

-Extract the temporary directory path from the status file, and return this -or nil if not found. -

- - - -
-
-     # File biopieces.rb, line 520
-520:   def get_tmpdir
-521:     File.open(path, mode="r") do |fh|
-522:       tmpdir_path = fh.read.chomp.split(";").last
-523:       return tmpdir_path if File.directory?(tmpdir_path)
-524:     end
-525: 
-526:     nil
-527:   end
-
- -
- - - - -
- - -
- - -
- - log(exit_status) - click to toggle source - -
- -
- -

-Write the Biopiece status to the log file. -

- - - -
-
-     # File biopieces.rb, line 530
-530:   def log(exit_status)
-531:     time1   = Time.new.strftime("%Y-%m-%d %X")
-532:     user    = ENV["USER"]
-533:     script  = File.basename($0)
-534: 
-535:     stream = File.open(path)
-536:     time0, args, tmp_dir = stream.first.split(";")
-537:     stream.close
-538: 
-539:     elap     = time_diff(time0, time1)
-540:     command  = [script, args].join(" ") 
-541:     log_file = ENV["BP_LOG"] + "/biopieces.log"
-542: 
-543:     File.open(log_file, mode = "a") { |file| file.puts [time0, time1, elap, user, exit_status, command].join("\t") }
-544:   end
-
- -
- - - - -
- - -
- - -
- - set() - click to toggle source - -
- -
- -

-Write the status to a status file. -

- - - -
-
-     # File biopieces.rb, line 495
-495:   def set
-496:     time0  = Time.new.strftime("%Y-%m-%d %X")
-497: 
-498:     File.open(path, mode="w") do |fh|
-499:       fh.puts [time0, ARGV.join(" ")].join(";")
-500:     end
-501:   end
-
- -
- - - - -
- - -
- - -
- - set_tmpdir(tmpdir_path) - click to toggle source - -
- -
- -

-Append the a temporary directory path to the status file. -

- - - -
-
-     # File biopieces.rb, line 504
-504:   def set_tmpdir(tmpdir_path)
-505:     status = ""
-506: 
-507:     File.open(path, mode="r") do |fh|
-508:       status = fh.read.chomp
-509:     end
-510: 
-511:     status = "#{status};#{tmpdir_path}\n"
-512: 
-513:     File.open(path, mode="w") do |fh|
-514:       fh << status
-515:     end
-516:   end
-
- -
- - - - -
- - -
- -
-

Private Instance Methods

- - -
- - -
- - path() - click to toggle source - -
- -
- -

-Path to status file -

- - - -
-
-     # File biopieces.rb, line 554
-554:   def path
-555:     user   = ENV["USER"]
-556:     script = File.basename($0)
-557:     pid    = $$
-558:     path   = ENV["BP_TMP"] + "/" + [user, script, pid, "status"].join(".")
-559:   end
-
- -
- - - - -
- - -
- - -
- - time_diff(t0, t1) - click to toggle source - -
- -
- -

-Get the elapsed time from the difference between two time stamps. -

- - - -
-
-     # File biopieces.rb, line 562
-562:   def time_diff(t0, t1)
-563:     Time.at((DateTime.parse(t1).to_time - DateTime.parse(t0).to_time).to_i).gmtime.strftime('%X')
-564:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/Stream.html b/code_ruby/Maasha/lib/doc/Stream.html deleted file mode 100644 index 24d3772..0000000 --- a/code_ruby/Maasha/lib/doc/Stream.html +++ /dev/null @@ -1,557 +0,0 @@ - - - - - - - Class: Stream - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

Stream

- -
- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - open(options, mode, stdio) - click to toggle source - -
- -
- -

-Open Biopieces output data stream for reading -from stdin or a file specified in options[:stream_in] OR writing to stdout -or a file specified in options[:stream_out] or options[:data_out]. -

- - - -
-
-     # File biopieces.rb, line 572
-572:   def self.open(options, mode, stdio)
-573:     if mode == "r"
-574:       if options[:data_in] and options[:data_in].first == "-"
-575:         self.nread(["-"])
-576:       else
-577:         $stdin.tty? ? read(options[:stream_in]) : stdio
-578:       end
-579:     elsif mode == "w"
-580:       options[:stream_out] ? self.write(options[:stream_out], options[:compress]) : stdio
-581:     else
-582:       raise "Bad mode #{mode}"
-583:     end
-584:   end
-
- -
- - - - -
- - -
- -
-

Private Class Methods

- - -
- - -
- - nread(files) - click to toggle source - -
- -
- -

-Opens a list of files for reading and return an io object. -

- - - -
-
-     # File biopieces.rb, line 616
-616:   def self.nread(files)
-617:     stdin, stdout, stderr = Open3.popen3("cat " + files.join(' '));
-618:     stdin.close
-619:     stderr.close
-620:     stdout
-621:   end
-
- -
- - - - -
- - -
- - -
- - nwrite(file) - click to toggle source - -
- -
- -

-Opens a file for writing and return an io object. -

- - - -
-
-     # File biopieces.rb, line 624
-624:   def self.nwrite(file)
-625:     File.open(file, mode="w")
-626:   end
-
- -
- - - - -
- - -
- - -
- - read(files) - click to toggle source - -
- -
- -

-Opens a reads stream to a list of files. -

- - - -
-
-     # File biopieces.rb, line 589
-589:   def self.read(files)
-590:     return if files.nil? #TODO case/when
-591:     self.zipped?(files) ? self.zread(files) : self.nread(files)
-592:   end
-
- -
- - - - -
- - -
- - -
- - write(file, zip=nil) - click to toggle source - -
- -
- -

-Opens a write stream to a file and returns a io object. -

- - - -
-
-     # File biopieces.rb, line 595
-595:   def self.write(file, zip=nil)
-596:     zip ? self.zwrite(file) : self.nwrite(file)
-597:   end
-
- -
- - - - -
- - -
- - -
- - zipped?(files) - click to toggle source - -
- -
- -

-Test if a list of files are gzipped or not. Raises if files are mixed -zipped and unzipped. -

- - - -
-
-     # File biopieces.rb, line 630
-630:   def self.zipped?(files)
-631:     type_hash = {}
-632: 
-633:     files.each do |file|
-634:       type = `file #{file}`
-635: 
-636:       if type =~ /gzip compressed/
-637:         type_hash[:gzip] = true
-638:       else
-639:         type_hash[:ascii] = true
-640:       end
-641:     end
-642: 
-643:     raise "Mixture of zipped and unzipped files" if type_hash.size == 2
-644: 
-645:     type_hash[:gzip]
-646:   end
-
- -
- - - - -
- - -
- - -
- - zread(files) - click to toggle source - -
- -
- -

-Opens a list of gzipped files for reading and return an io object. -

- - - -
-
-     # File biopieces.rb, line 600
-600:   def self.zread(files)
-601:     stdin, stdout, stderr = Open3.popen3("zcat " + files.join(' '));
-602:     stdin.close
-603:     stderr.close
-604:     stdout
-605:   end
-
- -
- - - - -
- - -
- - -
- - zwrite(file) - click to toggle source - -
- -
- -

-Opens a file for gzipped writing and return an io object. -

- - - -
-
-     # File biopieces.rb, line 608
-608:   def self.zwrite(file)
-609:     stdin, stdout, stderr = Open3.popen3("gzip -f > #{file}")
-610:     stderr.close
-611:     stdout.close
-612:     stdin
-613:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/String.html b/code_ruby/Maasha/lib/doc/String.html deleted file mode 100644 index 61c0653..0000000 --- a/code_ruby/Maasha/lib/doc/String.html +++ /dev/null @@ -1,408 +0,0 @@ - - - - - - - Class: String - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - -
-

Methods

- -
- - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

String

- -
-

-Monkey patching Class String to add bitwise -operators. Behaviour matching Perl’s: perldoc.perl.org/perlop.html#Bitwise-String-Operators -

- -
- - - - - - - - - -
-

Public Class Methods

- - -
- - -
- - hamming_dist(str1, str2) - click to toggle source - -
- -
- -

-Method to that returns the case senstive Hamming Distance between two -strings. en.wikipedia.org/wiki/Hamming_distance -

- - - -
-
-    # File bits.rb, line 34
-34:   def self.hamming_dist(str1, str2)
-35:     raise StringError, "Uneven string lengths: #{str1.length} != #{str2.length}" if str1.length != str2.length
-36:     (str1 ^ str2 ).count("\x01-\xff")
-37:   end
-
- -
- - - - -
- - -
- -
-

Public Instance Methods

- - -
- - -
- - &(str) - click to toggle source - -
- -
- -

-Method that performs bitwise AND operation where bits are copied if they -exists in BOTH operands. If the operand sizes are different, the & -operator methods acts as though the longer operand were truncated to the -length of the shorter. -

- - - -
-
-    # File bits.rb, line 43
-43:   def &(str)
-44:     new = ""
-45: 
-46:     (0 ... [self.length, str.length].min).each do |i|
-47:       new << (self[i].ord & str[i].ord)
-48:     end
-49: 
-50:     new
-51:   end
-
- -
- - - - -
- - -
- - -
- - ^(str) - click to toggle source - -
- -
- -

-Method that performs bitwise XOR operation where bits are copied if they -exists in ONE BUT NOT BOTH operands. -

- - - -
-
-    # File bits.rb, line 77
-77:   def ^(str)
-78:     new = ""
-79: 
-80:     (0 ... [self.length, str.length].min).each do |i|
-81:       new << (self[i].ord ^ str[i].ord)
-82:     end
-83: 
-84:     new
-85:   end
-
- -
- - - - -
- - -
- - -
- - |(str) - click to toggle source - -
- -
- -

-Method that performs bitwise OR operation where bits are copied if they -exists in EITHER operands. If the operand sizes differ, the shorter operand -is extended with the terminal part of the longer operand. -

- - - -
-
-    # File bits.rb, line 57
-57:   def |(str)
-58:     new = ""
-59: 
-60:     min = [self.length, str.length].min
-61: 
-62:     (0 ... min).each do |i|
-63:       new << (self[i].ord | str[i].ord)
-64:     end
-65: 
-66:     if self.length > str.length
-67:       new << self[min ... self.length]
-68:     elsif self.length < str.length
-69:       new << str[min ... str.length]
-70:     end
-71: 
-72:     new
-73:   end
-
- -
- - - - -
- - -
- - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/StringError.html b/code_ruby/Maasha/lib/doc/StringError.html deleted file mode 100644 index 2151699..0000000 --- a/code_ruby/Maasha/lib/doc/StringError.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - - Class: StringError - - - - - - - - - - - -
-
-
-

- Home - Classes - Methods -

-
-
- -
-
-

In Files

-
- -
-
- - -
- -
- - - -
-

Parent

- - - -
- - - - - - - - - - -
- -
- - - -
-

Class Index - [+]

-
-
- Quicksearch - -
-
- - - -
- - -
-
- -
-

StringError

- -
-

-Error class for all exceptions to do with String. -

- -
- - - - - - - - - - -
- - -
- -

Disabled; run with --debug to generate this.

- -
- -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - - - diff --git a/code_ruby/Maasha/lib/doc/base36_rb.html b/code_ruby/Maasha/lib/doc/base36_rb.html deleted file mode 100644 index 5b15245..0000000 --- a/code_ruby/Maasha/lib/doc/base36_rb.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - - File: base36.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-02-11 19:42:32 +0100
- - -
Requires
-
-
    - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/biopieces_rb.html b/code_ruby/Maasha/lib/doc/biopieces_rb.html deleted file mode 100644 index 9757f4c..0000000 --- a/code_ruby/Maasha/lib/doc/biopieces_rb.html +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - File: biopieces.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 09:14:44 +0100
- - -
Requires
-
-
    - -
  • fileutils
  • - -
  • date
  • - -
  • optparse
  • - -
  • open3
  • - -
  • pp
  • - -
-
- - - -
-
- -
- -
-

Description

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/bitarray_rb.html b/code_ruby/Maasha/lib/doc/bitarray_rb.html deleted file mode 100644 index bb50590..0000000 --- a/code_ruby/Maasha/lib/doc/bitarray_rb.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - - File: bitarray.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-17 15:02:03 +0100
- - -
Requires
-
-
    - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/bits_rb.html b/code_ruby/Maasha/lib/doc/bits_rb.html deleted file mode 100644 index 2380506..0000000 --- a/code_ruby/Maasha/lib/doc/bits_rb.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - - File: bits.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-08 11:37:57 +0100
- - -
Requires
-
-
    - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/boulder_rb.html b/code_ruby/Maasha/lib/doc/boulder_rb.html deleted file mode 100644 index 5416de3..0000000 --- a/code_ruby/Maasha/lib/doc/boulder_rb.html +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - File: boulder.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 09:17:13 +0100
- - -
Requires
-
-
    - -
  • filesys
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.html deleted file mode 100644 index b5ad0f7..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.html +++ /dev/null @@ -1,301 +0,0 @@ - - - - Class: Biopieces [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassBiopieces
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - Object - -
-
- - -
- -
- -
-

-Biopieces are command line scripts and uses -OptionParser to parse command line options according to a list of casts. -Each cast prescribes the long and short name of the option, the type, if it -is mandatory, the default value, and allowed and disallowed values. An -optional list of extra casts can be supplied, and the integrity of the -casts are checked. Following the command line parsing, the options are -checked according to the casts. Methods are also included for handling the -parsing and emitting of Biopiece records, which are ASCII text records -consisting of lines with a key/value pair seperated by a colon and a white -space ’: ’. Each record is separated by a line with three -dashes ’—’. -

- -
- -
- - -
-

Methods

- -
- - each   - - each_record   - - mktmpdir   - - new   - - parse   - - puts   - -
-
- -
- - - -
- - - - - - -
- -

Public Class methods

- - -
- - - - -
- -

-Initialize a Biopiece and write the status to file. Options are for testing -purposes only. -

- -
-
- - -

Public Instance methods

- - -
- - -
- - each() - -
- -
- -

-Alias for each_record -

- -
-
- - -
- - - - -
- -

-Open Biopiece input stream if not open and iterate over all Biopiece -records in the stream. -

- -
-
- - -
- - - - -
- -

-Create a temporary directory inside the ENV[“BP_TMP“] dir. -

- -
-
- - -
- - - - -
- -

-Check the integrity of a list of casts, followed by parsion options from -argv and finally checking the options according to the casts. Returns nil -if argv is empty, otherwise an options hash. -

- -
-
- - -
- - - - -
- -

-Open Biopiece output stream if not open and puts record to the stream. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000001.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000001.html deleted file mode 100644 index 7e9371a..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000001.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - new (Biopieces) - - - - -
# File biopieces.rb, line 43
-  def initialize(test=nil, input=STDIN, output=STDOUT)
-    @test   = test
-    @input  = input
-    @output = output
-    @status = Status.new
-    @status.set unless @test
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000002.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000002.html deleted file mode 100644 index b69e120..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000002.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - parse (Biopieces) - - - - -
# File biopieces.rb, line 54
-  def parse(argv, cast_list=[], script_path=$0)
-    casts          = Casts.new(cast_list)
-    option_handler = OptionHandler.new(argv, casts, script_path, @test)
-    @options       = option_handler.options_parse
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000003.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000003.html deleted file mode 100644 index 2675d14..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000003.html +++ /dev/null @@ -1,34 +0,0 @@ - - - - each_record (Biopieces) - - - - -
# File biopieces.rb, line 62
-  def each_record
-    @in = Stream::open(@options, mode="r", @input) unless @in.is_a? IO
-    return if @in.nil?
-
-    record = {}
-
-    @in.each_line do |line|
-      case line
-      when /^([^:]+): (.*)$/
-        record[$1] = $2
-      when /^---$/
-        yield record unless record.empty?
-        record = {}
-      else
-        raise "Bad record format: #{line}"
-      end
-    end
-
-    yield record unless record.empty?
-
-    self # conventionally
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000005.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000005.html deleted file mode 100644 index cb2274b..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000005.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - puts (Biopieces) - - - - -
# File biopieces.rb, line 88
-  def puts(record)
-    @out = Stream::open(@options, mode="w", @output) unless @out.is_a? IO
-
-    record.each do |key,value|
-      @out.print "#{key}: #{value}\n"
-    end
-
-    @out.print "---\n"
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000006.html b/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000006.html deleted file mode 100644 index 9e4ff5e..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Biopieces.src/M000006.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - mktmpdir (Biopieces) - - - - -
# File biopieces.rb, line 99
-  def mktmpdir
-    time = Time.now.to_i
-    user = ENV["USER"]
-    pid  = $$
-    path = ENV["BP_TMP"] + "/" + [user, time + pid, pid, "bp_tmp"].join("_")
-    Dir.mkdir(path)
-    @status.set_tmpdir(path)
-    path
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/CastError.html b/code_ruby/Maasha/lib/doc/classes/CastError.html deleted file mode 100644 index bec2260..0000000 --- a/code_ruby/Maasha/lib/doc/classes/CastError.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - Class: CastError [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassCastError
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - StandardError - -
-
- - -
- -
- -
-

-Error class for all exceptions to do with option casts. -

- -
- -
- - -
- - - -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Casts.html b/code_ruby/Maasha/lib/doc/classes/Casts.html deleted file mode 100644 index b0a6e48..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Casts.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - Class: Casts [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassCasts
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - Array - -
-
- - -
- -
- -
-

-Class to handle casts of command line options. Each cast prescribes the -long and short name of the option, the type, if it is mandatory, the -default value, and allowed and disallowed values. An optional list of extra -casts can be supplied, and the integrity of the casts are checked. -

- -
- -
- - -
-

Methods

- -
- - new   - -
-
- -
- - - -
- -
-

Constants

- -
- - - - - - - - - - - - - - - - -
TYPES=%w[flag string list int uint float file file! files files! dir dir! genome]
MANDATORY=%w[long short type mandatory default allowed disallowed]
-
-
- - - - - - -
- -

Public Class methods

- - -
- - - - -
- -

-Initialize cast object with an optional options cast list to which -ubiquitous casts are added after which all casts are checked. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Casts.src/M000007.html b/code_ruby/Maasha/lib/doc/classes/Casts.src/M000007.html deleted file mode 100644 index 8ae5d3f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Casts.src/M000007.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - new (Casts) - - - - -
# File biopieces.rb, line 125
-  def initialize(cast_list=[])
-    @cast_list = cast_list
-    ubiquitous
-    check
-    self.push *@cast_list
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Fasta.html b/code_ruby/Maasha/lib/doc/classes/Fasta.html deleted file mode 100644 index ab36f56..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Fasta.html +++ /dev/null @@ -1,266 +0,0 @@ - - - - Class: Fasta [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassFasta
In: - - - - - fasta.rb - - - - -
- -
Parent: - - Object - -
-
- - -
- -
- -
- - -
-

Methods

- -
- - close   - - each   - - get_entry   - - new   - - open   - -
-
- -
- - - -
-

Included Modules

- -
- - Enumerable - -
-
- -
- - - - - - -
- -

Public Class methods

- - -
- - - - -
- -
-
- - -
- - - - -
- -

-Class method allowing open to be used on (zipped) files. See File.open. -

- -
-
- - -

Public Instance methods

- - -
- - - - -
- -

-Method to close ios. -

- -
-
- - -
- - - - -
- -

-Iterator method for parsing FASTA enries. -

- -
-
- - -
- - - - -
- -

-Method to get the next FASTA entry form an ios and return this as a Seq -object. If no entry is found or eof then nil is returned. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000031.html b/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000031.html deleted file mode 100644 index c9a4be0..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000031.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - open (Fasta) - - - - -
# File fasta.rb, line 33
-  def self.open(*args)
-    ios   = File.open(*args)
-    fasta = self.new(ios)
-
-    if block_given?
-      begin
-        yield fasta
-      ensure
-        ios.close
-      end
-
-      return true
-    else
-      return fasta
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000032.html b/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000032.html deleted file mode 100644 index ad1c045..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000032.html +++ /dev/null @@ -1,16 +0,0 @@ - - - - new (Fasta) - - - - -
# File fasta.rb, line 50
-  def initialize(io, type=nil)
-    @io   = io
-    @type = type
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000033.html b/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000033.html deleted file mode 100644 index 40d2bc9..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000033.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - each (Fasta) - - - - -
# File fasta.rb, line 56
-  def each
-    while entry = get_entry do
-      yield entry
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000034.html b/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000034.html deleted file mode 100644 index 62a8104..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Fasta.src/M000034.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - get_entry (Fasta) - - - - -
# File fasta.rb, line 64
-  def get_entry
-    block = @io.gets($/ + '>')
-    return nil if block.nil?
-
-    block.chomp!($/ + '>')
-
-    (seq_name, seq) = block.split($/, 2)
-
-    raise FastaError, "Bad FASTA format" if seq_name.nil? or seq.nil?
-
-    entry          = Seq.new
-    entry.type     = @type.nil? ? nil : @type.downcase
-    entry.seq      = seq.gsub(/\s/, '')
-    entry.seq_name = seq_name.sub(/^>/, '').rstrip
-
-    raise FastaError, "Bad FASTA format" if entry.seq_name.empty?
-    raise FastaError, "Bad FASTA format" if entry.seq.empty?
-
-    entry
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/FastaError.html b/code_ruby/Maasha/lib/doc/classes/FastaError.html deleted file mode 100644 index d188d55..0000000 --- a/code_ruby/Maasha/lib/doc/classes/FastaError.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - Class: FastaError [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassFastaError
In: - - - - - fasta.rb - - - - -
- -
Parent: - - StandardError - -
-
- - -
- -
- -
-

-Error class for all exceptions to do with FASTA. -

- -
- -
- - -
- - - -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.html deleted file mode 100644 index 177aca6..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.html +++ /dev/null @@ -1,615 +0,0 @@ - - - - Class: OptionHandler [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassOptionHandler
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - Object - -
-
- - -
- -
- -
-

-Class for parsing argv using OptionParser according to given casts. Default -options are set, file glob expressions expanded, and options are checked -according to the casts. Usage information is printed and exit called if -required. -

- -
- -
- - - - -
- - - -
- -
-

Constants

- -
- - - - - - - - - - - - - - - - - - - - - - - -
REGEX_LIST=/^(list|files|files!)$/
REGEX_INT=/^(int|uint)$/
REGEX_STRING=/^(string|file|file!|dir|dir!|genome)$/
-
-
- - - - - - -
- -

Public Class methods

- - - - - -

Public Instance methods

- - -
- - - - -
- -

-Check all options according to casts. -

- -
-
- - -
- - - - -
- -

-Check options and raise unless allowed. -

- -
-
- - -
- - - - -
- -

-Check dir! type argument and raise if directory don’t exist. -

- -
-
- - -
- - - - -
- -

-Check disallowed argument values and raise if disallowed. -

- -
-
- - -
- - - - -
- -

-Check file! type argument and raise if file don’t exists. -

- -
-
- - -
- - - - -
- -

-Check files! type argument and raise if files don’t exists. -

- -
-
- - -
- - - - -
- -

-Check int type option and raise if not an integer. -

- -
-
- - -
- - - - -
- -

-Check if a mandatory option is set and raise if it isn’t. -

- -
-
- - -
- - - - -
- -

-Check uint type option and raise if not an unsinged integer. -

- -
-
- - -
- - - - -
- -

-Set default options value from cast unless a value is set. -

- -
-
- - -
- - - - -
- -

-Expands glob expressions to a full list of paths. Examples: -“*.fna” or “foo.fna,*.fna” or -“foo.fna,/bar/*.fna“ -

- -
-
- - -
- - - - -
- -

-Parse options from argv using OptionParser and casts denoting long and -short option names. Usage information is printed and exit called. A hash -with options is returned. -

- -
-
- - -
- - - - -
- -

-Print usage info by Calling an external script ‘print_wiki’ -using a system() call and exit. An optional ‘full’ flag outputs -the full usage info. -

- -
-
- - -
- - - - -
- -

-Check if full “usage info” should be printed. -

- -
-
- - -
- - - - -
- -

-Check if short “usage info” should be printed. -

- -
-
- - -
- - - - -
- -

-Given the script name determine the path of the wiki file with the usage -info. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000008.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000008.html deleted file mode 100644 index 5a296d0..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000008.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - new (OptionHandler) - - - - -
# File biopieces.rb, line 250
-  def initialize(argv, casts, script_path, test=nil)
-    @argv        = argv
-    @casts       = casts
-    @script_path = script_path
-    @test        = test
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000009.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000009.html deleted file mode 100644 index 97be195..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000009.html +++ /dev/null @@ -1,58 +0,0 @@ - - - - options_parse (OptionHandler) - - - - -
# File biopieces.rb, line 260
-  def options_parse
-    @options = {}
-
-    option_parser = OptionParser.new do |option|
-      @casts.each do |cast|
-        case cast[:type]
-        when 'flag'
-          option.on("-#{cast[:short]}", "--#{cast[:long]}") do |o|
-            @options[cast[:long]] = o
-          end
-        when 'float'
-          option.on("-#{cast[:short]}", "--#{cast[:long]} F", Float) do |f|
-            @options[cast[:long]] = f
-          end
-        when REGEX_LIST
-          option.on( "-#{cast[:short]}", "--#{cast[:long]} A", Array) do |a|
-            @options[cast[:long]] = a
-          end
-        when REGEX_INT
-          option.on("-#{cast[:short]}", "--#{cast[:long]} I", Integer) do |i|
-            @options[cast[:long]] = i
-          end
-        when REGEX_STRING
-          option.on("-#{cast[:short]}", "--#{cast[:long]} S", String) do |s|
-            @options[cast[:long]] = s
-          end
-        else
-          raise ArgumentError, "Unknown option type: '#{cast[:type]}'"
-        end
-      end
-    end
-
-    option_parser.parse!(@argv)
-
-    if print_usage_full?
-      print_usage_and_exit(true)
-    elsif print_usage_short?
-      print_usage_and_exit
-    end
-
-    options_default
-    options_glob
-    options_check
-
-    @options
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000010.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000010.html deleted file mode 100644 index f8f6991..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000010.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - wiki_path (OptionHandler) - - - - -
# File biopieces.rb, line 308
-  def wiki_path
-    path = ENV["BP_DIR"] + "/bp_usage/" + File.basename(@script_path) + ".wiki"
-    raise "No such wiki file: #{path}" unless File.file? path
-    path
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000011.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000011.html deleted file mode 100644 index fc4110d..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000011.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - print_usage_full? (OptionHandler) - - - - -
# File biopieces.rb, line 315
-  def print_usage_full?
-    @options["help"]
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000012.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000012.html deleted file mode 100644 index 454bef7..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000012.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - print_usage_short? (OptionHandler) - - - - -
# File biopieces.rb, line 320
-  def print_usage_short?
-    if not $stdin.tty?
-      return false
-    elsif @options["stream_in"]
-      return false
-    elsif @options["data_in"]
-      return false
-    elsif wiki_path =~ /^(list_biopieces|list_genomes|list_mysql_databases|biostat)$/  # TODO get rid of this!
-      return false
-    else
-      return true
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000013.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000013.html deleted file mode 100644 index 859c8a1..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000013.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - print_usage_and_exit (OptionHandler) - - - - -
# File biopieces.rb, line 337
-  def print_usage_and_exit(full=nil)
-    if @test
-      return
-    else
-      if full
-        system("print_wiki --data_in #{wiki_path} --help")
-      else
-        system("print_wiki --data_in #{wiki_path}")
-      end
-
-      raise "Failed printing wiki: #{wiki_path}" unless $?.success?
-
-      exit
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000014.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000014.html deleted file mode 100644 index 6666325..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000014.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - options_default (OptionHandler) - - - - -
# File biopieces.rb, line 354
-  def options_default
-    @casts.each do |cast|
-      if cast[:default]
-        @options[cast[:long]] = cast[:default] unless @options.has_key? cast[:long]
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000015.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000015.html deleted file mode 100644 index 44dfb09..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000015.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - options_glob (OptionHandler) - - - - -
# File biopieces.rb, line 364
-  def options_glob
-    @casts.each do |cast|
-      if cast[:type] == 'files' or cast[:type] == 'files!'
-        if @options.has_key? cast[:long]
-          files = []
-        
-          @options[cast[:long]].each do |path|
-            if path.include? "*"
-              Dir.glob(path).each do |file|
-                files << file if File.file? file
-              end
-            else
-              files << path
-            end
-          end
-
-          @options[cast[:long]] = files
-        end
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000016.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000016.html deleted file mode 100644 index 59771a2..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000016.html +++ /dev/null @@ -1,24 +0,0 @@ - - - - options_check (OptionHandler) - - - - -
# File biopieces.rb, line 387
-  def options_check
-    @casts.each do |cast|
-      options_check_mandatory(cast)
-      options_check_int(cast)
-      options_check_uint(cast)
-      options_check_file(cast)
-      options_check_files(cast)
-      options_check_dir(cast)
-      options_check_allowed(cast)
-      options_check_disallowed(cast)
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000017.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000017.html deleted file mode 100644 index f6c78dd..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000017.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - options_check_mandatory (OptionHandler) - - - - -
# File biopieces.rb, line 401
-  def options_check_mandatory(cast)
-    if cast[:mandatory]
-      raise ArgumentError, "Mandatory argument: --#{cast[:long]}" unless @options.has_key? cast[:long]
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000018.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000018.html deleted file mode 100644 index 91480ab..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000018.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - options_check_int (OptionHandler) - - - - -
# File biopieces.rb, line 408
-  def options_check_int(cast)
-    if cast[:type] == 'int' and @options.has_key? cast[:long]
-      unless @options[cast[:long]].is_a? Integer
-        raise ArgumentError, "Argument to --#{cast[:long]} must be an integer, not '#{@options[cast[:long]]}'"
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000019.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000019.html deleted file mode 100644 index 2bae214..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000019.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - options_check_uint (OptionHandler) - - - - -
# File biopieces.rb, line 417
-  def options_check_uint(cast)
-    if cast[:type] == 'uint' and @options.has_key? cast[:long]
-      unless @options[cast[:long]].is_a? Integer and @options[cast[:long]] >= 0
-        raise ArgumentError, "Argument to --#{cast[:long]} must be an unsigned integer, not '#{@options[cast[:long]]}'"
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000020.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000020.html deleted file mode 100644 index c4ad6f1..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000020.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - options_check_file (OptionHandler) - - - - -
# File biopieces.rb, line 426
-  def options_check_file(cast)
-    if cast[:type] == 'file!' and @options.has_key? cast[:long]
-      raise ArgumentError, "No such file: '#{@options[cast[:long]]}'" unless File.file? @options[cast[:long]]
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000021.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000021.html deleted file mode 100644 index 12c6e7b..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000021.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - options_check_files (OptionHandler) - - - - -
# File biopieces.rb, line 433
-  def options_check_files(cast)
-    if cast[:type] == 'files!' and @options.has_key? cast[:long]
-      @options[cast[:long]].each do |path|
-        raise ArgumentError, "No such file: '#{path}'" unless File.file? path
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000022.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000022.html deleted file mode 100644 index b7399d7..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000022.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - options_check_dir (OptionHandler) - - - - -
# File biopieces.rb, line 442
-  def options_check_dir(cast)
-    if cast[:type] == 'dir!' and @options.has_key? cast[:long]
-      raise ArgumentError, "No such directory: '#{@options[cast[:long]]}'" unless File.directory? @options[cast[:long]]
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000023.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000023.html deleted file mode 100644 index de6439e..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000023.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - options_check_allowed (OptionHandler) - - - - -
# File biopieces.rb, line 449
-  def options_check_allowed(cast)
-    if cast[:allowed] and @options.has_key? cast[:long]
-      allowed_hash = {}
-      cast[:allowed].split(',').each { |a| allowed_hash[a.to_s] = 1 }
-  
-      raise ArgumentError, "Argument '#{@options[cast[:long]]}' to --#{cast[:long]} not allowed" unless allowed_hash.has_key? @options[cast[:long]].to_s
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000024.html b/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000024.html deleted file mode 100644 index 5bbf893..0000000 --- a/code_ruby/Maasha/lib/doc/classes/OptionHandler.src/M000024.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - options_check_disallowed (OptionHandler) - - - - -
# File biopieces.rb, line 459
-  def options_check_disallowed(cast)
-    if cast[:disallowed] and @options.has_key? cast[:long]
-      cast[:disallowed].split(',').each do |val|
-        raise ArgumentError, "Argument '#{@options[cast[:long]]}' to --#{cast[:long]} is disallowed" if val.to_s == @options[cast[:long]].to_s
-      end
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.html b/code_ruby/Maasha/lib/doc/classes/Seq.html deleted file mode 100644 index 2617168..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.html +++ /dev/null @@ -1,412 +0,0 @@ - - - - Class: Seq [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeq
In: - - - - - seq.rb - - - - -
- -
Parent: - - Object - -
-
- - -
- -
- -
- - -
-

Methods

- -
- - complement   - - generate   - - is_dna   - - is_protein   - - is_rna   - - len   - - length   - - to_bp   - - to_dna   - - to_rna   - -
-
- -
- - - -
- - - -
-

Attributes

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
qual [RW] 
seq [RW] 
seq_name [RW] 
type [RW] 
-
-
- - - - -
- -

Public Instance methods

- - -
- - - - -
- -

-Method that complements sequence including ambiguity codes. -

- -
-
- - -
- - - - -
- -

-Method that generates a random sequence of a given length. -

- -
-
- - -
- - - - -
- -

-Method that returns true is a given sequence type is DNA. -

- -
-
- - -
- - - - -
- -
-
- - -
- - - - -
- -
-
- - -
- - -
- - len() - -
- -
- -

-Alias for length -

- -
-
- - -
- - - - -
- -
-
- - -
- - - - -
- -

-Method that given a Seq entry returns a Biopieces record (a hash). -

- -
-
- - -
- - - - -
- -

-Method to reverse-transcribe RNA to DNA. -

- -
-
- - -
- - - - -
- -

-Method to transcribe DNA to RNA. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000001.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000001.html deleted file mode 100644 index 9817e7f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000001.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - length (Seq) - - - - -
# File seq.rb, line 11
-  def length
-    self.seq.nil? ? 0 : self.seq.length
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000003.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000003.html deleted file mode 100644 index bb35b7f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000003.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_dna (Seq) - - - - -
# File seq.rb, line 18
-  def is_dna
-    self.type == 'dna'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000004.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000004.html deleted file mode 100644 index 1ab276a..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000004.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_rna (Seq) - - - - -
# File seq.rb, line 22
-  def is_rna
-    self.type == 'rna'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000005.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000005.html deleted file mode 100644 index 445bd31..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000005.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_protein (Seq) - - - - -
# File seq.rb, line 26
-  def is_protein
-    self.type == 'protein'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000006.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000006.html deleted file mode 100644 index 0d2143f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000006.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - to_rna (Seq) - - - - -
# File seq.rb, line 31
-  def to_rna
-    raise SeqError, "Cannot transcribe 0 length sequence" if self.length == 0
-    raise SeqError, "Cannot transcribe sequence type: #{self.type}" unless self.is_dna
-    self.type = 'rna'
-    self.seq.tr!('Tt','Uu')
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000007.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000007.html deleted file mode 100644 index 84cddb0..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000007.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - to_dna (Seq) - - - - -
# File seq.rb, line 39
-  def to_dna
-    raise SeqError, "Cannot reverse-transcribe 0 length sequence" if self.length == 0
-    raise SeqError, "Cannot reverse-transcribe sequence type: #{self.type}" unless self.is_rna
-    self.type = 'dna'
-    self.seq.tr!('Uu','Tt')
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000008.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000008.html deleted file mode 100644 index cde9366..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000008.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - complement (Seq) - - - - -
# File seq.rb, line 47
-  def complement
-    raise SeqError, "Cannot complement 0 length sequence" if self.length == 0
-
-    if self.is_dna
-      self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'TCGAAYRWSKMDHBVNtcgaayrwskmdhbvn' )
-    elsif self.is_rna
-      self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'UCGAAYRWSKMDHBVNucgaayrwskmdhbvn' )
-    else
-      raise SeqError, "Cannot complement sequence type: #{self.type}"
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000009.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000009.html deleted file mode 100644 index fc415c3..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000009.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - generate (Seq) - - - - -
# File seq.rb, line 60
-  def generate(length,type)
-    raise SeqError, "Cannot generate negative sequence length: #{length}" if length <= 0
-
-    case type.downcase
-    when "dna"
-      alph = DNA
-    when "rna"
-      alph = RNA
-    when "protein"
-      alph = PROTEIN
-    else
-      raise SeqError, "Unknown sequence type: #{type}"
-    end
-
-    seq_new   = Array.new(length) { alph[rand(alph.size)] }.join("")
-    self.seq  = seq_new
-    self.type = type.downcase
-
-    seq_new
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000031.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000031.html deleted file mode 100644 index 1a623c0..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000031.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - guess_type (Seq) - - - - -
# File seq.rb, line 4
-        def guess_type
-                raise ArgumentError, "No sequence." if self.empty?
-
-                seq_beg = self[ 0, 100 ].upcase
-
-                if seq_beg.count( "FLPQIE" ) > 0
-                        Seq::AA.new( self )
-                elsif seq_beg.count( "U" ) > 0
-                        Seq::NA::RNA.new( self )
-                else
-                        Seq::NA::DNA.new( self )
-                end
-        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000032.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000032.html deleted file mode 100644 index a03cc80..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000032.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - wrap (Seq) - - - - -
# File seq.rb, line 19
-        def wrap( width = 80, delimit = "\n" )
-                raise ArgumentError, "Cannot wrap sequence to negative width: #{ width }." if width <= 0
-
-                self.delete!( " \t\n\r" )
-                self.gsub( /.{#{ width }}(?!$)/, "\\0#{ delimit }" )
-        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000033.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000033.html deleted file mode 100644 index a6e505c..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000033.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - wrap! (Seq) - - - - -
# File seq.rb, line 27
-        def wrap!( width = 80, delimit = "\n" )
-                self.replace( self.wrap( width, delimit ) )
-        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000034.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000034.html deleted file mode 100644 index e50a92b..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000034.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - generate (Seq) - - - - -
# File seq.rb, line 32
-        def generate( length )
-                raise ArgumentError, "Cannot generate negative sequence length: #{ length }." if length <= 0
-
-                alph = self.residues
-                Array.new( length ) { alph[ rand( alph.size ) ] }.join( "" )
-        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000035.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000035.html deleted file mode 100644 index 9817e7f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000035.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - length (Seq) - - - - -
# File seq.rb, line 11
-  def length
-    self.seq.nil? ? 0 : self.seq.length
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000037.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000037.html deleted file mode 100644 index bb35b7f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000037.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_dna (Seq) - - - - -
# File seq.rb, line 18
-  def is_dna
-    self.type == 'dna'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000038.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000038.html deleted file mode 100644 index 1ab276a..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000038.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_rna (Seq) - - - - -
# File seq.rb, line 22
-  def is_rna
-    self.type == 'rna'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000039.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000039.html deleted file mode 100644 index 445bd31..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000039.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - is_protein (Seq) - - - - -
# File seq.rb, line 26
-  def is_protein
-    self.type == 'protein'
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000040.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000040.html deleted file mode 100644 index 0d2143f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000040.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - to_rna (Seq) - - - - -
# File seq.rb, line 31
-  def to_rna
-    raise SeqError, "Cannot transcribe 0 length sequence" if self.length == 0
-    raise SeqError, "Cannot transcribe sequence type: #{self.type}" unless self.is_dna
-    self.type = 'rna'
-    self.seq.tr!('Tt','Uu')
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000041.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000041.html deleted file mode 100644 index 84cddb0..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000041.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - to_dna (Seq) - - - - -
# File seq.rb, line 39
-  def to_dna
-    raise SeqError, "Cannot reverse-transcribe 0 length sequence" if self.length == 0
-    raise SeqError, "Cannot reverse-transcribe sequence type: #{self.type}" unless self.is_rna
-    self.type = 'dna'
-    self.seq.tr!('Uu','Tt')
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000042.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000042.html deleted file mode 100644 index 85e6cb2..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000042.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - to_bp (Seq) - - - - -
# File seq.rb, line 47
-  def to_bp
-    raise SeqError, "Missing seq_name" if self.seq_name.nil?
-    raise SeqError, "Missing seq"      if self.seq.nil?
-    record             = {}
-    record['SEQ_NAME'] = self.seq_name
-    record['SEQ']      = self.seq
-    record['SEQ_LEN']  = self.length
-    record
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000043.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000043.html deleted file mode 100644 index 19a14ca..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000043.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - complement (Seq) - - - - -
# File seq.rb, line 58
-  def complement
-    raise SeqError, "Cannot complement 0 length sequence" if self.length == 0
-
-    if self.is_dna
-      self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'TCGAAYRWSKMDHBVNtcgaayrwskmdhbvn' )
-    elsif self.is_rna
-      self.seq.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'UCGAAYRWSKMDHBVNucgaayrwskmdhbvn' )
-    else
-      raise SeqError, "Cannot complement sequence type: #{self.type}"
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000044.html b/code_ruby/Maasha/lib/doc/classes/Seq.src/M000044.html deleted file mode 100644 index 7b22124..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq.src/M000044.html +++ /dev/null @@ -1,31 +0,0 @@ - - - - generate (Seq) - - - - -
# File seq.rb, line 71
-  def generate(length,type)
-    raise SeqError, "Cannot generate negative sequence length: #{length}" if length <= 0
-
-    case type.downcase
-    when "dna"
-      alph = DNA
-    when "rna"
-      alph = RNA
-    when "protein"
-      alph = PROTEIN
-    else
-      raise SeqError, "Unknown sequence type: #{type}"
-    end
-
-    seq_new   = Array.new(length) { alph[rand(alph.size)] }.join("")
-    self.seq  = seq_new
-    self.type = type.downcase
-    seq_new
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/AA.html b/code_ruby/Maasha/lib/doc/classes/Seq/AA.html deleted file mode 100644 index 985ba72..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/AA.html +++ /dev/null @@ -1,193 +0,0 @@ - - - - Class: Seq::AA [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeq::AA
In: - - - - - seq.rb - - - - -
- -
Parent: - - - - Seq - - - -
-
- - -
- -
- -
-

-Class containing methods specific for amino acid (AA) -sequences. -

- -
- -
- - -
-

Methods

- -
- - mol_weight   - - residues   - -
-
- -
- - - -
- - - - - - -
- -

Public Instance methods

- - -
- - - - -
- -

-Calculate the molecular weight of an amino acid seuqunce. The caluculation -is only approximate since there is no correction for amino bond formation -and the MW used are somewhat imprecise: www.expasy.ch/tools/pscale/Molecularweight.html -

- -
-
- - -
- - - - -
- -

-Method that returns an array of amino acid residues. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000036.html b/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000036.html deleted file mode 100644 index db8e35b..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000036.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - residues (Seq::AA) - - - - -
# File seq.rb, line 47
-                def residues
-                        %w{ F L S Y C W P H Q R I M T N K V A D E G }
-                end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000037.html b/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000037.html deleted file mode 100644 index 6bf454b..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/AA.src/M000037.html +++ /dev/null @@ -1,44 +0,0 @@ - - - - mol_weight (Seq::AA) - - - - -
# File seq.rb, line 55
-                def mol_weight
-                        raise ArgumentError, "invalid residues found: #{self.delete("#{residues.join( "" )}")}" if self.upcase =~ /[^#{residues.join( "" )}]/
-
-                        mol_weight_aa = {
-                                "A" => 89.000,    # Ala
-                                "R" => 174.000,   # Arg
-                                "N" => 132.000,   # Asn
-                                "D" => 133.000,   # Asp
-                                "C" => 121.000,   # Cys
-                                "Q" => 146.000,   # Gln
-                                "E" => 147.000,   # Glu
-                                "G" => 75.000,    # Gly
-                                "H" => 155.000,   # His
-                                "I" => 131.000,   # Ile
-                                "L" => 131.000,   # Leu
-                                "K" => 146.000,   # Lys
-                                "M" => 149.000,   # Met
-                                "F" => 165.000,   # Phe
-                                "P" => 115.000,   # Pro
-                                "S" => 105.000,   # Ser
-                                "T" => 119.000,   # Thr
-                                "W" => 204.000,   # Trp
-                                "Y" => 181.000,   # Tyr
-                                "V" => 117.000,   # Val
-                        }
-
-                        mw = 0.0
-
-                        self.upcase.each_char { |c| mw += mol_weight_aa[ c ] }
-
-                        mw
-                end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA.html deleted file mode 100644 index 97c8ec4..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - Class: Seq::NA [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeq::NA
In: - - - - - seq.rb - - - - -
- -
Parent: - - - - Seq - - - -
-
- - -
- -
- -
-

-Class containing methods specific for nucleic acid (NA) sequences. -

- -
- -
- - -
- - - -
- -
-

Classes and Modules

- - Class Seq::NA::DNA
-Class Seq::NA::RNA
- -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.html deleted file mode 100644 index 778adf2..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.html +++ /dev/null @@ -1,217 +0,0 @@ - - - - Class: Seq::NA::DNA [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeq::NA::DNA
In: - - - - - seq.rb - - - - -
- -
Parent: - - - - Seq::NA - - - -
-
- - -
- -
- -
-

-Class containing methods specific for DNA sequences. -

- -
- -
- - -
-

Methods

- -
- - complement   - - residues   - - to_RNA   - -
-
- -
- - - -
- - - - - - -
- -

Public Instance methods

- - -
- - - - -
- -

-Method that complements DNA sequence including -ambiguity codes. -

- -
-
- - -
- - - - -
- -

-Method that returns an array of DNA residues. -

- -
-
- - -
- - - - -
- -

-Method to transcribe DNA to RNA. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000038.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000038.html deleted file mode 100644 index cf7df44..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000038.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - residues (Seq::NA::DNA) - - - - -
# File seq.rb, line 94
-                        def residues
-                                %w{ A T C G }
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000039.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000039.html deleted file mode 100644 index 60835d9..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000039.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - to_RNA (Seq::NA::DNA) - - - - -
# File seq.rb, line 99
-                        def to_RNA
-                                Seq::NA::RNA.new( self.tr( 'Tt', 'Uu' ) )
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000040.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000040.html deleted file mode 100644 index 6e79d17..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/DNA.src/M000040.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - complement (Seq::NA::DNA) - - - - -
# File seq.rb, line 104
-                        def complement
-                                self.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'TCGAAYRWSKMDHBVNtcgaayrwskmdhbvn' )
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.html deleted file mode 100644 index 2345f3f..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.html +++ /dev/null @@ -1,217 +0,0 @@ - - - - Class: Seq::NA::RNA [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeq::NA::RNA
In: - - - - - seq.rb - - - - -
- -
Parent: - - - - Seq::NA - - - -
-
- - -
- -
- -
-

-Class containing methods specific for RNA sequences. -

- -
- -
- - -
-

Methods

- -
- - complement   - - residues   - - to_DNA   - -
-
- -
- - - -
- - - - - - -
- -

Public Instance methods

- - -
- - - - -
- -

-Method that complements RNA sequence including -ambiguity codes. -

- -
-
- - -
- - - - -
- -

-Method that returns an array of RNA residues. -

- -
-
- - -
- - - - -
- -

-Method to reverse transcribe RNA to DNA. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000041.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000041.html deleted file mode 100644 index 92655b3..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000041.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - residues (Seq::NA::RNA) - - - - -
# File seq.rb, line 112
-                        def residues
-                                %w{ A U C G }
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000042.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000042.html deleted file mode 100644 index 7307861..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000042.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - to_DNA (Seq::NA::RNA) - - - - -
# File seq.rb, line 117
-                        def to_DNA
-                                Seq::NA::DNA.new( self.tr( 'Uu', 'Tt' ) )
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000043.html b/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000043.html deleted file mode 100644 index 7f5d3f2..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Seq/NA/RNA.src/M000043.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - complement (Seq::NA::RNA) - - - - -
# File seq.rb, line 122
-                        def complement
-                                self.tr!( 'AGCUTRYWSMKHDVBNagcutrywsmkhdvbn', 'UCGAAYRWSKMDHBVNucgaayrwskmdhbvn' )
-                        end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/SeqError.html b/code_ruby/Maasha/lib/doc/classes/SeqError.html deleted file mode 100644 index 192b171..0000000 --- a/code_ruby/Maasha/lib/doc/classes/SeqError.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - Class: SeqError [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassSeqError
In: - - - - - seq.rb - - - - -
- -
Parent: - - StandardError - -
-
- - -
- -
- -
-

-Error class for all exceptions to do with Seq. -

- -
- -
- - -
- - - -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.html b/code_ruby/Maasha/lib/doc/classes/Status.html deleted file mode 100644 index d6681d4..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.html +++ /dev/null @@ -1,268 +0,0 @@ - - - - Class: Status [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassStatus
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - Object - -
-
- - -
- -
- -
-

-Class for manipulating the execution status of Biopieces by setting a status file with a time -stamp, process id, and command arguments. The status file is used for -creating log entries and for displaying the runtime status of Biopieces. -

- -
- -
- - -
-

Methods

- -
- - delete   - - get_tmpdir   - - log   - - set   - - set_tmpdir   - -
-
- -
- - - -
- - - - - - -
- -

Public Instance methods

- - -
- - - - -
- -

-Delete status file. -

- -
-
- - -
- - - - -
- -

-Extract the temporary directory path from the status file, and return this -or nil if not found. -

- -
-
- - -
- - - - -
- -

-Write the Biopiece status to the log file. -

- -
-
- - -
- - - - -
- -

-Write the status to a status file. -

- -
-
- - -
- - - - -
- -

-Append the a temporary directory path to the status file. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.src/M000025.html b/code_ruby/Maasha/lib/doc/classes/Status.src/M000025.html deleted file mode 100644 index 84e53d7..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.src/M000025.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - set (Status) - - - - -
# File biopieces.rb, line 474
-  def set
-    time0  = Time.new.strftime("%Y-%m-%d %X")
-
-    File.open(path, mode="w") do |fh|
-      fh.puts [time0, ARGV.join(" ")].join(";")
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.src/M000026.html b/code_ruby/Maasha/lib/doc/classes/Status.src/M000026.html deleted file mode 100644 index 3a81609..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.src/M000026.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - set_tmpdir (Status) - - - - -
# File biopieces.rb, line 483
-  def set_tmpdir(tmpdir_path)
-    File.open(path, mode="r") do |fh|
-      fh.read.chomp
-    end
-
-    File.open(path, mode="w") do |fh|
-      fh << [status, tmpdir_path].join(";") + "\n"
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.src/M000027.html b/code_ruby/Maasha/lib/doc/classes/Status.src/M000027.html deleted file mode 100644 index a78ea57..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.src/M000027.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - get_tmpdir (Status) - - - - -
# File biopieces.rb, line 495
-  def get_tmpdir
-    File.open(path, mode="r") do |fh|
-      tmpdir_path = fh.read.chomp.split(";").last
-      return tmpdir_path if File.directory?(tmpdir_path)
-    end
-
-    nil
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.src/M000028.html b/code_ruby/Maasha/lib/doc/classes/Status.src/M000028.html deleted file mode 100644 index 4f73b4e..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.src/M000028.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - log (Status) - - - - -
# File biopieces.rb, line 505
-  def log(exit_status)
-    time1   = Time.new.strftime("%Y-%m-%d %X")
-    user    = ENV["USER"]
-    script  = File.basename($0)
-
-    stream = File.open(path)
-    time0, args, tmp_dir = stream.first.split(";")
-    stream.close
-
-    elap     = time_diff(time0, time1)
-    command  = [script, args].join(" ") 
-    log_file = ENV["BP_LOG"] + "/biopieces.log"
-
-    File.open(log_file, mode="a") { |file| file.puts [time0, time1, elap, user, exit_status, command].join("\t") }
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Status.src/M000029.html b/code_ruby/Maasha/lib/doc/classes/Status.src/M000029.html deleted file mode 100644 index 2e74133..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Status.src/M000029.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - delete (Status) - - - - -
# File biopieces.rb, line 522
-  def delete
-    File.delete(path)
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/classes/Stream.html b/code_ruby/Maasha/lib/doc/classes/Stream.html deleted file mode 100644 index a1db5ee..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Stream.html +++ /dev/null @@ -1,154 +0,0 @@ - - - - Class: Stream [RDoc Documentation] - - - - - - - - - -
- - - - - - - - - - - - - - - - -
ClassStream
In: - - - - - biopieces.rb - - - - -
- -
Parent: - - IO - -
-
- - -
- -
- -
- - -
-

Methods

- -
- - open   - -
-
- -
- - - -
- - - - - - -
- -

Public Class methods

- - -
- - - - -
- -

-Open Biopieces output data stream for reading -from stdin or a file specified in options[“stream_in“] OR -writing to stdout or a file specified in options[“stream_out“]. -

- -
-
- - - -
- - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/classes/Stream.src/M000030.html b/code_ruby/Maasha/lib/doc/classes/Stream.src/M000030.html deleted file mode 100644 index 9a8cbd8..0000000 --- a/code_ruby/Maasha/lib/doc/classes/Stream.src/M000030.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - open (Stream) - - - - -
# File biopieces.rb, line 547
-  def self.open(options, mode, stdio)
-    if mode == "r"
-      $stdin.tty? ? read(options["stream_in"]) : stdio
-    elsif mode == "w"
-      options["stream_out"] ? self.write(options["stream_out"], options["compress"]) : stdio
-    else
-      raise "Bad mode #{mode}"
-    end
-  end
- - diff --git a/code_ruby/Maasha/lib/doc/created.rid b/code_ruby/Maasha/lib/doc/created.rid deleted file mode 100644 index 36dfd11..0000000 --- a/code_ruby/Maasha/lib/doc/created.rid +++ /dev/null @@ -1,13 +0,0 @@ -Sat, 19 Mar 2011 16:29:12 +0100 -./base36.rb Fri, 11 Feb 2011 19:42:32 +0100 -./biopieces.rb Sat, 19 Mar 2011 09:14:44 +0100 -./bitarray.rb Thu, 17 Mar 2011 15:02:03 +0100 -./bits.rb Tue, 08 Mar 2011 11:37:57 +0100 -./boulder.rb Sat, 19 Mar 2011 09:17:13 +0100 -./digest.rb Sat, 19 Mar 2011 15:41:06 +0100 -./fasta.rb Sat, 19 Mar 2011 09:11:06 +0100 -./fastq.rb Sat, 19 Mar 2011 09:09:52 +0100 -./filesys.rb Fri, 18 Mar 2011 22:13:22 +0100 -./genbank.rb Sat, 19 Mar 2011 09:19:25 +0100 -./seq.rb Sat, 19 Mar 2011 16:29:08 +0100 -./sff.rb Fri, 11 Feb 2011 19:55:38 +0100 diff --git a/code_ruby/Maasha/lib/doc/digest_rb.html b/code_ruby/Maasha/lib/doc/digest_rb.html deleted file mode 100644 index 22b22e5..0000000 --- a/code_ruby/Maasha/lib/doc/digest_rb.html +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - File: digest.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 15:41:06 +0100
- - -
Requires
-
-
    - -
  • seq
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/fasta_rb.html b/code_ruby/Maasha/lib/doc/fasta_rb.html deleted file mode 100644 index 1782158..0000000 --- a/code_ruby/Maasha/lib/doc/fasta_rb.html +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - - File: fasta.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 09:11:06 +0100
- - -
Requires
-
-
    - -
  • seq
  • - -
  • filesys
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/fastq_rb.html b/code_ruby/Maasha/lib/doc/fastq_rb.html deleted file mode 100644 index 0d97142..0000000 --- a/code_ruby/Maasha/lib/doc/fastq_rb.html +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - - File: fastq.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 09:09:52 +0100
- - -
Requires
-
-
    - -
  • seq
  • - -
  • filesys
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/files/biopieces_rb.html b/code_ruby/Maasha/lib/doc/files/biopieces_rb.html deleted file mode 100644 index 0efeadc..0000000 --- a/code_ruby/Maasha/lib/doc/files/biopieces_rb.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - File: biopieces.rb [RDoc Documentation] - - - - - - - - - -
-

biopieces.rb

- - - - - - - - - -
Path:biopieces.rb - -
Last Update:2010-08-17 14:23:28 +0200
-
- - -
- -
- -
-

-Copyright (C) 2007-2010 Martin A. Hansen. -

- -
- -
-

Required files

- -
- - fileutils   - - date   - - optparse   - - open3   - - pp   - -
-
- -
- - -
- - - -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/files/fasta_rb.html b/code_ruby/Maasha/lib/doc/files/fasta_rb.html deleted file mode 100644 index 21a9b00..0000000 --- a/code_ruby/Maasha/lib/doc/files/fasta_rb.html +++ /dev/null @@ -1,112 +0,0 @@ - - - - File: fasta.rb [RDoc Documentation] - - - - - - - - - -
-

fasta.rb

- - - - - - - - - -
Path:fasta.rb - -
Last Update:2010-08-18 21:33:24 +0200
-
- - -
- -
- -
-

-This program is free software; you can redistribute it and/or modify it -under the terms of the GNU General Public License as published by the Free -Software Foundation; either version 2 of the License, or (at your option) -any later version. -

- -
- -
-

Required files

- -
- - seq   - - zlib   - -
-
- -
- - -
- - - -
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/files/seq_rb.html b/code_ruby/Maasha/lib/doc/files/seq_rb.html deleted file mode 100644 index e080b99..0000000 --- a/code_ruby/Maasha/lib/doc/files/seq_rb.html +++ /dev/null @@ -1,121 +0,0 @@ - - - - File: seq.rb [RDoc Documentation] - - - - - - - - - -
-

seq.rb

- - - - - - - - - -
Path:seq.rb - -
Last Update:2010-08-17 08:33:38 +0200
-
- - -
- -
- -
- - -
- - - -
- -
-

Constants

- -
- - - - - - - - - - - - - - - - - - - - - - - -
DNA=%w[a t c g]
RNA=%w[a u c g]
PROTEIN=%w[f l s y c w p h q r i m t n k v a d e g]
-
-
- - - - - - - - - -
- -
-

[Validate]

-
- - - diff --git a/code_ruby/Maasha/lib/doc/filesys_rb.html b/code_ruby/Maasha/lib/doc/filesys_rb.html deleted file mode 100644 index 7d9ac37..0000000 --- a/code_ruby/Maasha/lib/doc/filesys_rb.html +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - File: filesys.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-18 22:13:22 +0100
- - -
Requires
-
-
    - -
  • zlib
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/fr_class_index.html b/code_ruby/Maasha/lib/doc/fr_class_index.html deleted file mode 100644 index 2557682..0000000 --- a/code_ruby/Maasha/lib/doc/fr_class_index.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - Classes [RDoc Documentation] - - - - - -
-

Classes

-
- - Fasta
- - FastaError
- -
-
- - diff --git a/code_ruby/Maasha/lib/doc/fr_file_index.html b/code_ruby/Maasha/lib/doc/fr_file_index.html deleted file mode 100644 index 83e8a04..0000000 --- a/code_ruby/Maasha/lib/doc/fr_file_index.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - - Files [RDoc Documentation] - - - - - -
-

Files

-
- - fasta.rb
- -
-
- - diff --git a/code_ruby/Maasha/lib/doc/fr_method_index.html b/code_ruby/Maasha/lib/doc/fr_method_index.html deleted file mode 100644 index 007edaa..0000000 --- a/code_ruby/Maasha/lib/doc/fr_method_index.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - Methods [RDoc Documentation] - - - - - -
-

Methods

- -
- - diff --git a/code_ruby/Maasha/lib/doc/genbank_rb.html b/code_ruby/Maasha/lib/doc/genbank_rb.html deleted file mode 100644 index 7434343..0000000 --- a/code_ruby/Maasha/lib/doc/genbank_rb.html +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - - File: genbank.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 09:19:25 +0100
- - -
Requires
-
-
    - -
  • seq
  • - -
  • filesys
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2010 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/images/brick.png b/code_ruby/Maasha/lib/doc/images/brick.png deleted file mode 100644 index 7851cf34c946e5667221e3478668503eb1cd733f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 452 zcmV;#0XzPQP)Pdwe5?6tW?r-ok|b$oDQj8FV%kZPq;(MWOV8?8;<)(iP}>hNMU> z7fbz%jjlr7h8uuoQ~J6}n}@Y@PdTk=)PxO{%7zmL?dchpZX*~n;I{!C>*(8cU;q(~ zAS%Po_@naEU!xidrBXD?;hN|x^%W|Ij)0y*r5vi|?W&Fub(NqJ@z0o=O&SR3v>A``^efOSo-hEdApp;^Jd;9y!%1UfzX6Bh- z%-mbG|0Na{7Ruai_Y+DEb1s+b!*9k%Q!whMxjtZKA*?o;i1g&jy0@( zaU=-@d-h+o%gal6JRXEXA&L3`d2 z%jIxzZ~*p9O-;EJp_Ds0If38rM<5W8ic~K>FOK&2_p!CLg^i63OioVb6k$)zWHLx3 z5;!|M!}<9+#QSi1dRlbEcxPt^;cysUuU8@%3}RwpLRIGG<|IKnoyP6$Eh3SKw7a*r zSDXP=IYc&YZf;7@?fCe($^l9ORaJ3wbAx0uiC8QqRr$2t-Cfy8%XCI3B%pxJW>XdM zw~zPt_s}#A@pxQ5Ly)4szaMtH9lgE1SXx@b+S(fW`ub$fYPE8J7#bSNDzme*Ub07{ zQKV8SjEs!%0@v5ql8ggm!@$6Rbi^E8vBqpRM-}l+@5OSMrl+TWj*gC^qoV@>u{fQb zov5v?g~?>X@bEC&+uLPaQ&Ypn-y~^mZA}+f(&2EFH8eE%dU|@ENpN*_1-)L6_4Rc* zFuq@`IjX9vp1QiaK9ZojyZhnQURP99d=u;%37VRkpwsD4U0sd3x;hEQB&e^i|3QN0 z=H|Os1fRqaw!?#igLmS4HE!G3*ce(`TF} zlgUq0Q544c8(ae&UR$8ps&snq6^bPY3v3xAmMW74Di$h~GCH6E3TaYs2#6A<7K*gC z777H71_Wa;(dfp+g-drPCSWu)#PInZi72LJ;o?i~$-U=y&UbQ89Dul3%3P+Axkzc* zbH-y;QF=hR{qLItf%ci2_&e5wNo0gnVatG?ul6Zw=o$I9Ljfn*ic3`U?>IfEim3g{ zujU&$-hy6wn;w(xme|zJm;lWJxtTFfM)q0`kX!Vu0+d${$}LCddK1<^htTe-fUYL3 zB`SdNsZD>RgvLj1<^@h6_+cDRK2Brcr2~>%$*5S)hyV33PV^teac3%|4lz@8p4?)5 z?t5o^?q+%^%)Yygo~I^U4VR!bTnWuE35hcWrfCDR3q+sxJ79e7Fg`&)RCqLA^2^y^ z0laVfadW90_Fz8Brm|r47sB^u1VgI>kanj)Z4`zMSfHlm8>CwXa$JVM`$2RrmZB-3 zN10m-!;BvH*Br3V8t`DH7m`jf#2upVDXl{5ff18_pzCPK1Zu$$CKKvd8FGeFf)+K<|x33pc7P&S#3GZT4mEw;nr(Ze*F z3&*?-4U-lm*#tber5 z%S_ceqB`b3ko6r~BbvDwdohTvP(3a(pq{x#T$yQsu#OKwEe}KuH^Mh@nxg_(Nw136 zq#a^3xNBke)In+!?qk3%4wB69{pF`Tzg`07*qoM6N<$ Eg55P&8UO$Q diff --git a/code_ruby/Maasha/lib/doc/images/bullet_black.png b/code_ruby/Maasha/lib/doc/images/bullet_black.png deleted file mode 100644 index 57619706d10d9736b1849a83f2c5694fbe09c53b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 211 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!60wlNoGJgf6SkfJR9T^zbpD<_bdI{u9mbgZg z1m~xflqVLYGB~E>C#5QQ<|d}62BjvZR2H60wE-$h^>lFz(Kw&{<9vg>5sw~gS5O!4 zr|{HuUFIBKiQyL}eBJ-L{`UVT|6_O~L{G%N{Wbre{kQtZ_0LvEhC#5QQ<|d}62BjvZR2H60wE-$h^mK6y(Kw&{<9vg>(S^W+6Zii9 z|Nhthr~iNb*Z!}6uiN$Dz5neG3a-`baBX8yz1H+_;eX)`ni0%X8XBDc-`=Ph(Uan2 zYsR{H!kvIN--9isvHznRsC#5QQ<|d}62BjvZR2H60wE-$h_H=O!(Kw&{<9vg>(S^W+6Zii9 z|Nhthr~iNb*Z!}6uiN$Dz5neG3a-`baBX8yz4q@v|B?28{s)#N@CGn3@%_y|zAV9T z66e<&B4?b6oF&azg|C(V&1ZbI_D}pL`}(^FT2yXwG1Ph~$Q@h8mJYOz!PC{xWt~$( F699+YQR)By diff --git a/code_ruby/Maasha/lib/doc/images/date.png b/code_ruby/Maasha/lib/doc/images/date.png deleted file mode 100644 index 783c83357fdf90a1c7c024358e1d768b5c09c135..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 626 zcmV-&0*(ENP)5OC%H;f`~O(q$Q#t2<^v$A>fbmv%e#dKTwK=Ku{5lS|}<-`a#7b zzTCOnnT>at)D}AMFuOZ5&%EqFN(lyumd$2ASF6=;nM~%2?gqc@U=#|4PqkX@EBo-9 z7pD#bO_RUa>*faM`8;MYfVi$JnB-zcBFc6gjl$d!bF98Q!!!(Z1_R~P?e!pt#6CHJ9S&n_n&@=9 z%GP;!@Co4c*at+6vNz7o(6en^Q1%qHrc;1)9IRaz-$@S$Z-qdC^ds3X0NvQH;KS)D z-dh&rW&@X;1cS(45z)J&BVt+tv&GMVJ%!EiW) zLBGZW)#Z+gl-Lih&?>X3SS-S#ujQ;9JRXmIB7X)8`d6ETj)D#Q2+$s|<_b7-B9Xvq zwNfqlEp%y3$uY`h{Y$(Gn5@}sqEsq95lpAkFO5dyBmP6^H-51G4J|rN2Ujt<`2YX_ M07*qoM6N<$fP)IO9T&v~?D!=C@G6X*U1@h2}>2WE%HrrsjTfQsh6N9%SR25A5rkWp0g zzi;-6|3HJE;58sAyX1e@^d7EwiKQLb00%dp|5+t<{|l;G!D3eSuFDma zRCxr2MVY_`ELgLXqo}ssqp5E;*r|opZT~&|!~VN?1^mw`Yxp0VmiIp*r|Ey~#AW|W zTBd;IxVd?%*x1<_!3Ip2yP9Rn!u1aqt=siKx4a3At0%7dKV|u@|9wlg|7x7R;eT!K z{QuFp&Huxb3&AdAW?^~2z`(!^HUQ{cR*=op7H|BYU0VMi3A-|5H&#ol!zs_8lnTUg(&PtE($2Dhdk=&(F^R z|KGZGj(DV`tD_*NsU$2QNCCXqf9n(sfdh~LzJJdCa}5CGoUI+JZJBOCDz({abl~fE zw*5kfzVoR6cNi2r#C!ZEH0O;NW@rIh| zlqsqSSs9s#;sV;-@|>77A1W_O_DV`91Pq4Kz`Z(PaO&pn=GOMkuU$ROkc5GuVd!Y* zcn`UMYkYq7V07o@rsi~>-ziMLT zG+?a49zQWzia{TFcs{FKj#dh}e#z5@`O3omC>ELXboP2cR7WT?J@&ao#fn-I;sJ*F zD;=5p9?%y~V{F{q4^{|Zlt~d?*Ve!iWj&E%8@h^*gN$V29v5mAsN{O(ULD=kFMd^> zzLGLp)CZ#Qm6Q%3+`@kXtfre9GnE->Ai(oKKDoxtH@hRaB&C1e=IHR>I8;havNP_A z5Rq#nPVBdI5VpJ;S&et6>VVp>c?LwQ)tZWlq#H^i>)VP@16GREXU98`irCrvkEecY zkv~S7^T>M0*)Mb{LvE6`M77!t_ZXXI^`uU6W|L`YE-^~uca*s^)=F=9o*rxs>$qx+ zN_$rAd`ahYK2^cpF)HkQ1(Vq|Urh;b~<55D)DL$EUNo=p_A6VQ1A+M~) zfa$>U0O5Rbu4r3$+|O$+gUQaOR@{dPsf3U1Dln%z0(Y0xq^w4=AKW8UMLXPC9RL7* zZ3?i~&mg|kvE%&Q2{D=<{q^E0^^uNwISF-V^g!SN_6Pp zHm8=*qyzo0O&|aW=mQ}BV^c}pv_6$imk>cA#v4GgKI?F@S#sYw42|o9Jp1uLDt+Ls z2-H#~>q=LQWTF;nU7xJYKH2KCI4{O5B$T{{EgN}dE+rE|#F+n@O!gj|u;Xxe?Su03 z2tWqC_4M@)#<@OoQ{pg&@m`>d=YYXNQlKHoj2tjT2nB<`FCZcENCi2SLd5c#Iz{+w= zQMis*31e?RPgP7h#4AOzY&hE#R4n&Ii?x5Yq0)?J7KNcBj@XdX zlWZ;>n^k?`V`54w4oMu!H=JW%u_9}!!vS4^ZMC2#K+@g2!t)G5*y)(xiYlL_px35D zIhY0lK348EIpV!%r-=F;O(7xbv>oQP6>|(>Opp4COU-9M>Q6ub0PdDCFo(En#x&eN zGni{g@pt^Yi&Zk-WUSBg%!GQT&imw!)F&}=v0^+ zPAeQFDhtKVnUuxMHpDJZ^)IYcqn3l$E3tGu>6%O0JW{Qd&uUAT_CJz)Db-2{$Z4Cq zibD~-93PZJRMP~xt4_LEY#WADM=C$k2DOim8}|&T7PflIw)ySUdh%=c{&;)e+r`Hd z>F)2L5sYyl@Pwfv-Z+Q9(~d^Q%E@BrXlV!+zKk$1SUf5lN)jz7MS>v}FnGm>Qbf5( zWmQ8>Y4OMAhWe&Lk?b!b?Oi z7q@cwX@48D4*Plhd-GIrduvP}Ef)tlzfP@U!q&vPH#vyU*UZF+Z1UXs%zV%z6LOs+ zcaVxUJ2&!|`1z(BM}Lk=9HZd_-+C?1s|j(*3pM}K)5P_O^ZvgjpgCOOIH^P=rz zrnafS&0I?@i8t47Fuv>lf^b*BgG?Gr8}Rx=$^MeEIq58C~R;2W5b2+Z6DSOmY&y?jM>PP zmCH(!b;p5a z08~hSk!QD03@!sbLen@urU{Gbn>9K(ikm zl#3h~9C5N=ig9Rs_qtTd=#qk`!ZGs7NvnMZ+uzd@j(?Rvpko)yuH)l~lSKOGS)aBD z7_OmZBdg=SE=0lny&|8m4WGI#J|9BJ}fBGEjmh_+3QFV-yUQn(l{$5#`e$ znfciyaIqFV2bzbhDu?7{<$RLQFC=|ws^?CtX)4I8sO>-(eMb1ar-sUdK)fzgqvMk> zZ^Rh)#8kxW$|S;j1HHPvzPz`!bA(!5h*+9K{Bl4}FHo45&3%yp?rDAP3~x@+ME*8G z&}mIK2Y`4+qxB<9rNt@5hlZ)HG`HKZFPtZ(CdCW@wfOGs!rXe8 z-mBDPnj{HhE4Ayk=DMsy6c5sbcY=`3>S0gZ@AO)^Sd)t$p13pA3PJ#dmLDTD1s}Wz z02ItQF~53Ov+wZ2P`n_U4VAJGo_<)CMpqJ3n-|`KmS8^ z<6NCKAuP(yrPRXiqft#MxAk}%PIb2CItemH*OUB$_E1dAyieI6EigfeNusQvXT~9L zwllbU*O+j+W5Qti)3H?p?*D`9lDN^-b^Q#pv$U8g4>1bxARs=rK5^IfwL5Y4H4Pl{I}`^(PH1gYU{*wqe@3$h1OCneK4J4!&MRe zOI%s;fxPp5H9Bx6x{QqEsK*Hpw`q|yBo$$v_ZDvLxN=kn=g9|eG|t{-cBCa zWSp2ev%7lwBK@tsaE^R7fx&OwUGQ#^arcni@_`qa0+Ih<3e19Mf+3k%g+)@Z0>QL0 z!HU9+@@y$mUhU^$zNMt8xbj1@av;@3!U%#u{N{thykrE-duU`-05?CiI5){L zy%f8$xwgE)K0S*=93sE3FU*{+{yF$b=Jm0O!B_#^eoI(9dVeEu^GYSFGhk6VM2eP; zSzH6(dYAFYJ=IMG-RZ%6^E|!yINDStfqn3^nx(_a*MMt-QOJ6FngYP6Flzi8{}M1u z?#m8_6qlhH0|2mB*E(B$x{iH!qh!(v^CX*om>t8m-!J2T%OyrE@fg!+W!rCupnGfE zR%c(5_C1*?Q|=SfK?@c3?d{0gfIk6Qne%2NAR%5!D1e2lrEA=#=314|^y}mlbdU!h zPIxs%P{lm;bYgjBs1qyXxkN6UD66G>mRl#Xr4z~PvG$je@$TcPPQN{YiFfsV4Ahz{ z;nj44T{SOdcs1301%HU_N_w4#jyn9@;-ar3_x<_h`fhkmBj(Iby8UQuwZ@CP3EK}j zbXm^OyhBqkWQ~AeVy^iVB)4Wh)+=b5--vjbtrvx4823+e>fN%unKd+&T&~@;LSp8#I-|*I=U2LzE0($<|LW%XsA_XQ z3>6@ct56W8`Y2>d{!pjH=F?<22mf_ejVWx&mfsLml615hA!(-FDBnc-jDQv_NKXNy z(=8#eu15MT`JMYUW~~vr%z{`z9S|~|_VAY6Ov4M7#Wa(*O#3EWzRYv@&_zy|0i*@_46?BhYPPEpVGD|(a((4@b>fF)l-3jQvCcv z{o)yqMWo1gDTG1vWp=_AJoP5UPxA^qrdn6*;Qh%^sB8>DcX5d2bXh zu<5X$-n2+RVUy$k%$jmfMxgu4ZWTs$Oy{Q?tryu(5>W>)zs2)w zHL}wWPpTzwL2MM8=lkwHp3#jyMe3%J0Av0)*ixKl2lMvu@{j$n91n^pNe|jd``l0N z0RU<BSv#yWY}G&Kb9IUxK2(l z!4Sz=T3g)J1mqFu!`seMX@O}Bp}gyZ@I7GK*7vWYuax&DJ=8$){{tXS> z7+}lu)M-J126vy;?q&^}iM1!NCf1I@E@@H~O-PIlsM7kknVdsATr@pmBo(C~$G6gS z02;)2O@0&~`#fHDeC1eCZZs;s2N)@A;Z!v}6IRW@+w4GRSlrsuorBjfJ?y*o(0gj> zt+;DN~K1pX*UvM(B(Di$9F6+&eT z#bhNzlMA>q^N?j+@1IqnYvK};_)_77Ts{!elaGqJg{uwb(1mX6u=pkfLJYkfX+`v! zOm>eolNV>Nz$A&W8YqkN#cU|#i6j>Ox+Eu4*8Myq{Eq?u*kn+nT zQ@k8?r`Isov^UI2=T{#K~skC)fRP-aj zcrJyQmQ!u>p5&{_zp7xOM(Q%smb6M%g6o4s^>A8#L41?8Ox^e7CM$W~*3!e8F7P`S zK9!26tqJVBt`?fLxM^Gf`xAacdcbz&)u<6pKM?qA_ms76BOQWg0Le^W#?SMIT$jE7 zyw1!lG*$#k#iqZyl9~L_CjIwBb}$%9+e2Vw!1@$nfpvj1y2o4hJabo7^;(V}>++Tz z{|NtdydBeFpKnv*Vg9BTu3P)+)3J?9`*6t|c{b*k>-L!PvY`#5^i1^XCnxh zky})0T&rp6 zJFwUVv-;Dzt2_z1)}rtpHBQH#<-`N0%%UP1TF^VNx2@~Zh_4nbMMxj7zeHTrB&q)a Dl)1NK diff --git a/code_ruby/Maasha/lib/doc/images/macFFBgHack.png b/code_ruby/Maasha/lib/doc/images/macFFBgHack.png deleted file mode 100644 index c6473b324ee1dae1faaacc0826639833f551116c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 207 zcmeAS@N?(olHy`uVBq!ia0vp^k|4~%1|*NXY)uAIEX7WqAsj$Z!;#Vf4nJ za0`Jjl>Qs8<JF;+Fd5q0wCR k?u=~bH}2*0f`J3~k>FVdQ&MBb@0BAfpf&c&j diff --git a/code_ruby/Maasha/lib/doc/images/package.png b/code_ruby/Maasha/lib/doc/images/package.png deleted file mode 100644 index da3c2a2d74bab159ba0f65d7db601768258afcb2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 853 zcmV-b1FHOqP)5TQ^(M5v$(QKVE?W+9X! z*o}&~6c?_FreF)9NJB7b5Nbn{G0n4+%uJhR9(V5R|NFTpb|HgjefT!tIhLx@DR+N) zV+fHiR5Yt19}k|KnCsND{tH-`IMJ)3AE?OtyZ4>Un|6(d%h#JK`i&a7^xW9>`yBy` zS4SOHeOpC7$?hH5-#7Rswiue_8Ju*2N@$58=a#2OTA3png`w3v->gWif7t%e$ z$NLVS!tFT#8WL|Wa&K~+{%4P2cRfwesYV1_!F=3OaRVHl(>=`%&{x*s30c}#CNE@&;ItrAv!f!)Oy$Q9t$uS=(sD$-J{T*^(8Eez1E-l3}} zPrfHZ1`qsIFe&gipuL8-IZbo2Yg{lFGKs?ZZWcOaOdk*3`5T;$?AjbG1#`B510Er^h2)2r3Y{!8_2Gj=$KzuN5 zaErtW8W_Y2iJJjY)5pmTVJoPJYpanPOEuYHclM^C1F>${hFRpdi8a<2H|Xudf78bm(zwJ9`K%6I?q*Ua~ fW9JvIbn5*B+_J)rUMBs>00000NkvXXu0mjfH&TkY diff --git a/code_ruby/Maasha/lib/doc/images/page_green.png b/code_ruby/Maasha/lib/doc/images/page_green.png deleted file mode 100644 index de8e003f9fb8752c09e7f3655d5d8664b5c62fc3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 621 zcmV-z0+RiSP)QqUjAtB;_Vvt6}AS_5YgM`Uqu`yva+H8^=4U$e4gHb}u zAQ2N{V3A%pO|?Pv?tb6z=jC}SiRa$G^v3q?*6XcYz$p|cq{uLj@#~Fi`J(>5{@&&N zy%T^+;>8cXx%|o77anP?&W1?1A(>-T49z9pyeCl@7YI+Si zKti7=B~``}TImz(G{0PnlQA3P#MAd}sorMjkP!50B7$nAkU^%#nl{Q9lW0@}9fE-> zN(q7tRuiC_T1r|BBtVBTlQ2+70$Rf;eF`Z;lx46Cpu-rEgb)EBKq(b^W8l<^We(`D z43?0=01z<3G6+UUv6`CsWCk6^93!#+<;ws7007{zS3k2k9-zZKFO~(k`>s0y006+1 zgF_jyIhsL-`FMf~JL~C=cV75(CrJ|q;MVO961G=O zm9d)YpJg5g(4i_HKL75eSE}mq$Y}r}hyVdcV~p>6a}oXr80q`oj%+s700000NkvXX Hu0mjfPs|!l diff --git a/code_ruby/Maasha/lib/doc/images/page_white_text.png b/code_ruby/Maasha/lib/doc/images/page_white_text.png deleted file mode 100644 index 813f712f726c935f9adf8d2f2dd0d7683791ef11..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 342 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!60wlNoGJgf6SkfJR9T^zbpD<_bdI{u9mbgZg z1m~xflqVLYGB~E>C#5QQ<|d}62BjvZR2H60wE-%6;pyTSA|c6o&@eC9QG)Hj&ExYL zO&oVL^)+cM^qd@ApywS>pwx0H@RDN}hq;7mU-SKczYQ-hnrr=;iDAQMZQ+*g=YOM= z!QlMQEn7FbaD->uKAYgo_j9)W&$$zS*W9}m(ey0q$&7l-XEWO0Y(9M=SnhLbwy;d>@~SY$Ku*0xPvIOQeV1x7u_z-2-X>_74(yfh7C znXL|3GZ+d2`3re2hs?MKC#5QQ<|d}62BjvZR2H60wE-$R?&;zfqH(@;q9b3Efq-lM(nr^( z=EYR73-9e)UYMWsXy%?aZsD68Yyv^2$~6QgEcljw%kx>O(f-gQ?@fOOx3A-0+Qw?O zRx~W)kn~Qe2d6f9nMG#g9Q04Mk==M~N!Dglvxk!fgVh#w@ZV$IY1+Xc`d{d2UcaP~ zfWp)_Ivqj}l2SPy^9ZWy6rG9Yx4v67_uA&&9|XA~5-#3)W3%em1peD8RWH^#O%XoM zxMPud%}GTj#~*+7JMxTd!`{^Q+>(D3*|@KV`*G2;{QnANOxu1$r2xIe;OXk;vd$@? F2>@zac~<}c diff --git a/code_ruby/Maasha/lib/doc/images/plugin.png b/code_ruby/Maasha/lib/doc/images/plugin.png deleted file mode 100644 index 6187b15aec001b7080b51a5f944f07591f26cc15..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 591 zcmV-V0eEcNHZMNv|IbJ-M`( zKwWL~opzjJe^WpCmV9E;(0&ut2;4va_(#>M8)>9$R5viQnf(Nkh~VM$y>J(jqb$cj z+nL1Nm|mV)Gm|9MnHf*7Ja4OEAQz__^LRKOLEwqpiGV^^A*T=#&inGm-62Xs;dnSp zKj&H9T*boh2i)W+(n27l!C)>fq|L%VB1i ziC4p;NwV_}ZjW7$LRW#(_bKF#hp=!IqNO26Z*w2+LEwx{PVnZ&Sn}T;mtzb$;qA*nT@@+ zV5uQ@iXDTPoTbV#FRr~z04|PPh`wXTNoCm9*tG&?e3+fYl>K6+&3|Cc$KOpL`ER+_ dcRl5U#9zn6ZO}GFk7R5;7c zlif>`Q5?tj7Yw@ZCMtTF^Q|ZedeJhM%QPCR*bs8V79p$QTo7e94yQNXRs-{0?hOn_-8n0AMO@u1Ts zNl8QzJs1#rz%RBt?ux>l+amAvh+J!{$lkaqv}+Erb-6j2xp>K4GLQnNB*W`hFg*?P z^AL@~(h~Z+wfcWEXHqV^Tq-#z$7Y#o0;yFxA!00F}F2dX# zjE$iOgT#G4*1TR6kB1Gnn@>$meCh2a>c5YuIvFn-R2W@>4@M*m@-|jiDV?b)bccgA zyPfsMM!rjy>+1O2)5Eg29Z_*2p&qGnmS!OH?vZ(4>QB01d>j%9n4QINxkyT(Dos?I zjaWF$*IQmh`SF-?xU%xMEfjq1=6qY*g&lgG_cXv$BGoIWyfO5 zp>pdV*O+y=&6@N2WWFo(%RtT`Q(H^6zn^a%epE~Kx^mEJ{c8`luC$nc*z9j|4Ms8aJK-la^5T)AZ%#@G{_P{NCN^P z(J0zvSn~SSm(Ur);-M~8^*;61*VRI`T1BN&LAhK;sZ>I-SVW;vfUfJv=ko^ugnc0x zhJodBxe>iyk3%w<%wC8holUJ4(iv>tL{`DQt zPOsyUbO_Cmc&*iHkqbm3ku`|GcC^OhF>jj9W*GkH;^g!iUVpib_h*=@udp4h(P+e*zL_~ZmJjh(y^BxULwq>9zXoYE8sq{#pN~U0C6!8vY)5N2 z9P*}mw}7X$O^qTtJef1ACWvJT9^wt-)Zh0r~j#0bT`f;-zv6 z^Tmw22!%rMcs!TaUX<-8s;X-B`+Xbo+_uWuFa z1yIPc?DTrQ7KvRhmt*TG|L=EYQ=LqFX;=Lp`4}jx6BE-@00000NkvXXu0mjf=s_29 diff --git a/code_ruby/Maasha/lib/doc/images/wrench.png b/code_ruby/Maasha/lib/doc/images/wrench.png deleted file mode 100644 index 5c8213fef5ab969f03189d4367e32e597e38bd7f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 610 zcmV-o0-gPdP)^jb z4`0v}DG1te)wmeb(>p90leRz?_mO+^JKy=v&2<29Od6?F%9%(c8los#f*@G`-%W&* z$)uBj2i@u-@SgX}gtyWPe6d*|w6h%R? zScK2#Yn%$sum0cy>90DmY*i{1XqpClEtktsRTZ)lCUe z<FogV^*tm>8*AlX za4oiR!&85LrobG57qUHUX#{>Vz(RHpB5|@>9O6N$jqB8>%($0wxE5R3)b>Y~xtCo$ zCgEk&A?_#IxHdN)9tqre^o{ho4{?hmPuf@^@I3-wncaRd%|~O3xbrKY=&TiwPYkJroM{;WUQTuMY8vpg}f4o)2%U3C;eEDoiEh?94d(rV57VIF#8VqzW$HrDC|#U`x@QDbgi zVl)t9GGz&YY#D?gc%>hISA+_EBpnXt#pnC`p6@xw0$8TCbULjhlgVx(kuc)%xbgqq zR5+DNDFRN0!y)7Gm}oT0i39}h4h928qY?Rho^UvPGJ#kuW|-Amtrn`Pmd&+bFo@sp z$LI4IQw7BG?|#2ewOS<<3VjL$0=lMY^m;wqZujv5kx1l%Sl;V&Iy4#$ip3&@LV2!7vhhN=PCz%^9v24`qb(+m4W?!q-&~=?ssf5GfnAmJKV;3bvpDm0(NhahZ=&^sqo6Odj6>)Dq_3p~4~ zvb`d3Mydwjt&Df^hVmLtI2x=U&h9(JVYX-!y~z3zi;1>=LY;o(bL$(Yf$lf)dMf0-u^0HrpTG Wk@)HE*94aU0000m+BBgry{~j2fHLegbHP( zrgXNbr0}2;^nywdjLjZe?uxtrd3D(pZH@fFFc0{BW_~jxoO1w7-VX;6vK@ROA$$R6 zEmo;Ht-Mj|>5jUy{bQ^V5@53LRI8AgLpUm|m+15sqcz@QtVSo|oz7ArM8?pIn+>gN z0b=4_b5O|4A*;Q+vc9Vqr~%3V155*NV~@gTz}KSUiKB-uJzjMZ>5%Q#n24H!V{ zTY(LLAE*NAHZ}C#wnj%Bw5OFIkRhkkAW#kDC3j9Wm0YXRaXlyyp>#mVfYG)eC;@ab zDb=T-BCAY4LI(Z@GOTr2V_A{pRwSmz+8Be>CjAw(=gnbVWAeguvZa93JmL(EDxv1m z0OP4q=fpAK1Mq!C2`OkEn37o;m#wF#(t(8Pu#S?2f#x<~4EO{@fmm`p9veD6RZ_jp z@Au4};q&`XuKEYgIiB4((kgxOs#YdqJw0fY>9^K_agEu5+$#k;w#%I2N>n_?)YIqu z`tq&#_^p?-%K*U0^}|7+9U(&k0?s;=r=uCZ%)H9_edH8wK}gB(nUB1FFk+2Ol%BXV zHoFY`D~2x|2 - - - - - - - RDoc Documentation - - - - - - - - - - - - -

RDoc Documentation

- - -

This is the API documentation for 'RDoc Documentation'.

- - - - - -

Classes/Modules

- - -

Methods

- - -
-

[Validate]

-

Generated with the Darkfish - Rdoc Generator 1.1.6.

-
- - diff --git a/code_ruby/Maasha/lib/doc/js/darkfish.js b/code_ruby/Maasha/lib/doc/js/darkfish.js deleted file mode 100644 index 84565c1..0000000 --- a/code_ruby/Maasha/lib/doc/js/darkfish.js +++ /dev/null @@ -1,116 +0,0 @@ -/** - * - * Darkfish Page Functions - * $Id: darkfish.js 53 2009-01-07 02:52:03Z deveiant $ - * - * Author: Michael Granger - * - */ - -/* Provide console simulation for firebug-less environments */ -if (!("console" in window) || !("firebug" in console)) { - var names = ["log", "debug", "info", "warn", "error", "assert", "dir", "dirxml", - "group", "groupEnd", "time", "timeEnd", "count", "trace", "profile", "profileEnd"]; - - window.console = {}; - for (var i = 0; i < names.length; ++i) - window.console[names[i]] = function() {}; -}; - - -/** - * Unwrap the first element that matches the given @expr@ from the targets and return them. - */ -$.fn.unwrap = function( expr ) { - return this.each( function() { - $(this).parents( expr ).eq( 0 ).after( this ).remove(); - }); -}; - - -function showSource( e ) { - var target = e.target; - var codeSections = $(target). - parents('.method-detail'). - find('.method-source-code'); - - $(target). - parents('.method-detail'). - find('.method-source-code'). - slideToggle(); -}; - -function hookSourceViews() { - $('.method-description,.method-heading').click( showSource ); -}; - -function toggleDebuggingSection() { - $('.debugging-section').slideToggle(); -}; - -function hookDebuggingToggle() { - $('#debugging-toggle img').click( toggleDebuggingSection ); -}; - -function hookQuickSearch() { - $('.quicksearch-field').each( function() { - var searchElems = $(this).parents('.section').find( 'li' ); - var toggle = $(this).parents('.section').find('h3 .search-toggle'); - // console.debug( "Toggle is: %o", toggle ); - var qsbox = $(this).parents('form').get( 0 ); - - $(this).quicksearch( this, searchElems, { - noSearchResultsIndicator: 'no-class-search-results', - focusOnLoad: false - }); - $(toggle).click( function() { - // console.debug( "Toggling qsbox: %o", qsbox ); - $(qsbox).toggle(); - }); - }); -}; - -function highlightTarget( anchor ) { - console.debug( "Highlighting target '%s'.", anchor ); - - $("a[name=" + anchor + "]").each( function() { - if ( !$(this).parent().parent().hasClass('target-section') ) { - console.debug( "Wrapping the target-section" ); - $('div.method-detail').unwrap( 'div.target-section' ); - $(this).parent().wrap( '
' ); - } else { - console.debug( "Already wrapped." ); - } - }); -}; - -function highlightLocationTarget() { - console.debug( "Location hash: %s", window.location.hash ); - if ( ! window.location.hash || window.location.hash.length == 0 ) return; - - var anchor = window.location.hash.substring(1); - console.debug( "Found anchor: %s; matching %s", anchor, "a[name=" + anchor + "]" ); - - highlightTarget( anchor ); -}; - -function highlightClickTarget( event ) { - console.debug( "Highlighting click target for event %o", event.target ); - try { - var anchor = $(event.target).attr( 'href' ).substring(1); - console.debug( "Found target anchor: %s", anchor ); - highlightTarget( anchor ); - } catch ( err ) { - console.error( "Exception while highlighting: %o", err ); - }; -}; - - -$(document).ready( function() { - hookSourceViews(); - hookDebuggingToggle(); - hookQuickSearch(); - highlightLocationTarget(); - - $('ul.link-list a').bind( "click", highlightClickTarget ); -}); diff --git a/code_ruby/Maasha/lib/doc/js/jquery.js b/code_ruby/Maasha/lib/doc/js/jquery.js deleted file mode 100644 index afe9e74..0000000 --- a/code_ruby/Maasha/lib/doc/js/jquery.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * jQuery 1.2.6 - New Wave Javascript - * - * Copyright (c) 2008 John Resig (jquery.com) - * Dual licensed under the MIT (MIT-LICENSE.txt) - * and GPL (GPL-LICENSE.txt) licenses. - * - * $Date: 2008-09-25 09:50:52 -0700 (Thu, 25 Sep 2008) $ - * $Rev: 38 $ - */ -(function(){var _jQuery=window.jQuery,_$=window.$;var jQuery=window.jQuery=window.$=function(selector,context){return new jQuery.fn.init(selector,context);};var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/,isSimple=/^.[^:#\[\.]*$/,undefined;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(selector.nodeType){this[0]=selector;this.length=1;return this;}if(typeof selector=="string"){var match=quickExpr.exec(selector);if(match&&(match[1]||!context)){if(match[1])selector=jQuery.clean([match[1]],context);else{var elem=document.getElementById(match[3]);if(elem){if(elem.id!=match[3])return jQuery().find(selector);return jQuery(elem);}selector=[];}}else -return jQuery(context).find(selector);}else if(jQuery.isFunction(selector))return jQuery(document)[jQuery.fn.ready?"ready":"load"](selector);return this.setArray(jQuery.makeArray(selector));},jquery:"1.2.6",size:function(){return this.length;},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num];},pushStack:function(elems){var ret=jQuery(elems);ret.prevObject=this;return ret;},setArray:function(elems){this.length=0;Array.prototype.push.apply(this,elems);return this;},each:function(callback,args){return jQuery.each(this,callback,args);},index:function(elem){var ret=-1;return jQuery.inArray(elem&&elem.jquery?elem[0]:elem,this);},attr:function(name,value,type){var options=name;if(name.constructor==String)if(value===undefined)return this[0]&&jQuery[type||"attr"](this[0],name);else{options={};options[name]=value;}return this.each(function(i){for(name in options)jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[name],type,i,name));});},css:function(key,value){if((key=='width'||key=='height')&&parseFloat(value)<0)value=undefined;return this.attr(key,value,"curCSS");},text:function(text){if(typeof text!="object"&&text!=null)return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(text));var ret="";jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8)ret+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this]);});});return ret;},wrapAll:function(html){if(this[0])jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild)elem=elem.firstChild;return elem;}).append(this);return this;},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html);});},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html);});},append:function(){return this.domManip(arguments,true,false,function(elem){if(this.nodeType==1)this.appendChild(elem);});},prepend:function(){return this.domManip(arguments,true,true,function(elem){if(this.nodeType==1)this.insertBefore(elem,this.firstChild);});},before:function(){return this.domManip(arguments,false,false,function(elem){this.parentNode.insertBefore(elem,this);});},after:function(){return this.domManip(arguments,false,true,function(elem){this.parentNode.insertBefore(elem,this.nextSibling);});},end:function(){return this.prevObject||jQuery([]);},find:function(selector){var elems=jQuery.map(this,function(elem){return jQuery.find(selector,elem);});return this.pushStack(/[^+>] [^+>]/.test(selector)||selector.indexOf("..")>-1?jQuery.unique(elems):elems);},clone:function(events){var ret=this.map(function(){if(jQuery.browser.msie&&!jQuery.isXMLDoc(this)){var clone=this.cloneNode(true),container=document.createElement("div");container.appendChild(clone);return jQuery.clean([container.innerHTML])[0];}else -return this.cloneNode(true);});var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined)this[expando]=null;});if(events===true)this.find("*").andSelf().each(function(i){if(this.nodeType==3)return;var events=jQuery.data(this,"events");for(var type in events)for(var handler in events[type])jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data);});return ret;},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&&jQuery.grep(this,function(elem,i){return selector.call(elem,i);})||jQuery.multiFilter(selector,this));},not:function(selector){if(selector.constructor==String)if(isSimple.test(selector))return this.pushStack(jQuery.multiFilter(selector,this,true));else -selector=jQuery.multiFilter(selector,this);var isArrayLike=selector.length&&selector[selector.length-1]!==undefined&&!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)<0:this!=selector;});},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector=='string'?jQuery(selector):jQuery.makeArray(selector))));},is:function(selector){return!!selector&&jQuery.multiFilter(selector,this).length>0;},hasClass:function(selector){return this.is("."+selector);},val:function(value){if(value==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type=="select-one";if(index<0)return null;for(var i=one?index:0,max=one?index+1:options.length;i=0||jQuery.inArray(this.name,value)>=0);else if(jQuery.nodeName(this,"select")){var values=jQuery.makeArray(value);jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,values)>=0||jQuery.inArray(this.text,values)>=0);});if(!values.length)this.selectedIndex=-1;}else -this.value=value;});},html:function(value){return value==undefined?(this[0]?this[0].innerHTML:null):this.empty().append(value);},replaceWith:function(value){return this.after(value).remove();},eq:function(i){return this.slice(i,i+1);},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments));},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem);}));},andSelf:function(){return this.add(this.prevObject);},data:function(key,value){var parts=key.split(".");parts[1]=parts[1]?"."+parts[1]:"";if(value===undefined){var data=this.triggerHandler("getData"+parts[1]+"!",[parts[0]]);if(data===undefined&&this.length)data=jQuery.data(this[0],key);return data===undefined&&parts[1]?this.data(parts[0]):data;}else -return this.trigger("setData"+parts[1]+"!",[parts[0],value]).each(function(){jQuery.data(this,key,value);});},removeData:function(key){return this.each(function(){jQuery.removeData(this,key);});},domManip:function(args,table,reverse,callback){var clone=this.length>1,elems;return this.each(function(){if(!elems){elems=jQuery.clean(args,this.ownerDocument);if(reverse)elems.reverse();}var obj=this;if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(elems[0],"tr"))obj=this.getElementsByTagName("tbody")[0]||this.appendChild(this.ownerDocument.createElement("tbody"));var scripts=jQuery([]);jQuery.each(elems,function(){var elem=clone?jQuery(this).clone(true)[0]:this;if(jQuery.nodeName(elem,"script"))scripts=scripts.add(elem);else{if(elem.nodeType==1)scripts=scripts.add(jQuery("script",elem).remove());callback.call(obj,elem);}});scripts.each(evalScript);});}};jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if(elem.src)jQuery.ajax({url:elem.src,async:false,dataType:"script"});else -jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"");if(elem.parentNode)elem.parentNode.removeChild(elem);}function now(){return+new Date;}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options;if(target.constructor==Boolean){deep=target;target=arguments[1]||{};i=2;}if(typeof target!="object"&&typeof target!="function")target={};if(length==i){target=this;--i;}for(;i-1;}},swap:function(elem,options,callback){var old={};for(var name in options){old[name]=elem.style[name];elem.style[name]=options[name];}callback.call(elem);for(var name in options)elem.style[name]=old[name];},css:function(elem,name,force){if(name=="width"||name=="height"){var val,props={position:"absolute",visibility:"hidden",display:"block"},which=name=="width"?["Left","Right"]:["Top","Bottom"];function getWH(){val=name=="width"?elem.offsetWidth:elem.offsetHeight;var padding=0,border=0;jQuery.each(which,function(){padding+=parseFloat(jQuery.curCSS(elem,"padding"+this,true))||0;border+=parseFloat(jQuery.curCSS(elem,"border"+this+"Width",true))||0;});val-=Math.round(padding+border);}if(jQuery(elem).is(":visible"))getWH();else -jQuery.swap(elem,props,getWH);return Math.max(0,val);}return jQuery.curCSS(elem,name,force);},curCSS:function(elem,name,force){var ret,style=elem.style;function color(elem){if(!jQuery.browser.safari)return false;var ret=defaultView.getComputedStyle(elem,null);return!ret||ret.getPropertyValue("color")=="";}if(name=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(style,"opacity");return ret==""?"1":ret;}if(jQuery.browser.opera&&name=="display"){var save=style.outline;style.outline="0 solid black";style.outline=save;}if(name.match(/float/i))name=styleFloat;if(!force&&style&&style[name])ret=style[name];else if(defaultView.getComputedStyle){if(name.match(/float/i))name="float";name=name.replace(/([A-Z])/g,"-$1").toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if(computedStyle&&!color(elem))ret=computedStyle.getPropertyValue(name);else{var swap=[],stack=[],a=elem,i=0;for(;a&&color(a);a=a.parentNode)stack.unshift(a);for(;i]*?)\/>/g,function(all,front,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+">";});var tags=jQuery.trim(elem).toLowerCase(),div=context.createElement("div");var wrap=!tags.indexOf("",""]||!tags.indexOf("",""]||tags.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"","
"]||!tags.indexOf("",""]||(!tags.indexOf("",""]||!tags.indexOf("",""]||jQuery.browser.msie&&[1,"div
","
"]||[0,"",""];div.innerHTML=wrap[1]+elem+wrap[2];while(wrap[0]--)div=div.lastChild;if(jQuery.browser.msie){var tbody=!tags.indexOf(""&&tags.indexOf("=0;--j)if(jQuery.nodeName(tbody[j],"tbody")&&!tbody[j].childNodes.length)tbody[j].parentNode.removeChild(tbody[j]);if(/^\s/.test(elem))div.insertBefore(context.createTextNode(elem.match(/^\s*/)[0]),div.firstChild);}elem=jQuery.makeArray(div.childNodes);}if(elem.length===0&&(!jQuery.nodeName(elem,"form")&&!jQuery.nodeName(elem,"select")))return;if(elem[0]==undefined||jQuery.nodeName(elem,"form")||elem.options)ret.push(elem);else -ret=jQuery.merge(ret,elem);});return ret;},attr:function(elem,name,value){if(!elem||elem.nodeType==3||elem.nodeType==8)return undefined;var notxml=!jQuery.isXMLDoc(elem),set=value!==undefined,msie=jQuery.browser.msie;name=notxml&&jQuery.props[name]||name;if(elem.tagName){var special=/href|src|style/.test(name);if(name=="selected"&&jQuery.browser.safari)elem.parentNode.selectedIndex;if(name in elem&¬xml&&!special){if(set){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode)throw"type property can't be changed";elem[name]=value;}if(jQuery.nodeName(elem,"form")&&elem.getAttributeNode(name))return elem.getAttributeNode(name).nodeValue;return elem[name];}if(msie&¬xml&&name=="style")return jQuery.attr(elem.style,"cssText",value);if(set)elem.setAttribute(name,""+value);var attr=msie&¬xml&&special?elem.getAttribute(name,2):elem.getAttribute(name);return attr===null?undefined:attr;}if(msie&&name=="opacity"){if(set){elem.zoom=1;elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(value)+''=="NaN"?"":"alpha(opacity="+value*100+")");}return elem.filter&&elem.filter.indexOf("opacity=")>=0?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100)+'':"";}name=name.replace(/-([a-z])/ig,function(all,letter){return letter.toUpperCase();});if(set)elem[name]=value;return elem[name];},trim:function(text){return(text||"").replace(/^\s+|\s+$/g,"");},makeArray:function(array){var ret=[];if(array!=null){var i=array.length;if(i==null||array.split||array.setInterval||array.call)ret[0]=array;else -while(i)ret[--i]=array[i];}return ret;},inArray:function(elem,array){for(var i=0,length=array.length;i*",this).remove();while(this.firstChild)this.removeChild(this.firstChild);}},function(name,fn){jQuery.fn[name]=function(){return this.each(fn,arguments);};});jQuery.each(["Height","Width"],function(i,name){var type=name.toLowerCase();jQuery.fn[type]=function(size){return this[0]==window?jQuery.browser.opera&&document.body["client"+name]||jQuery.browser.safari&&window["inner"+name]||document.compatMode=="CSS1Compat"&&document.documentElement["client"+name]||document.body["client"+name]:this[0]==document?Math.max(Math.max(document.body["scroll"+name],document.documentElement["scroll"+name]),Math.max(document.body["offset"+name],document.documentElement["offset"+name])):size==undefined?(this.length?jQuery.css(this[0],type):null):this.css(type,size.constructor==String?size:size+"px");};});function num(elem,prop){return elem[0]&&parseInt(jQuery.curCSS(elem[0],prop,true),10)||0;}var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");jQuery.extend({expr:{"":function(a,i,m){return m[2]=="*"||jQuery.nodeName(a,m[2]);},"#":function(a,i,m){return a.getAttribute("id")==m[2];},":":{lt:function(a,i,m){return im[3]-0;},nth:function(a,i,m){return m[3]-0==i;},eq:function(a,i,m){return m[3]-0==i;},first:function(a,i){return i==0;},last:function(a,i,m,r){return i==r.length-1;},even:function(a,i){return i%2==0;},odd:function(a,i){return i%2;},"first-child":function(a){return a.parentNode.getElementsByTagName("*")[0]==a;},"last-child":function(a){return jQuery.nth(a.parentNode.lastChild,1,"previousSibling")==a;},"only-child":function(a){return!jQuery.nth(a.parentNode.lastChild,2,"previousSibling");},parent:function(a){return a.firstChild;},empty:function(a){return!a.firstChild;},contains:function(a,i,m){return(a.textContent||a.innerText||jQuery(a).text()||"").indexOf(m[3])>=0;},visible:function(a){return"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden";},hidden:function(a){return"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden";},enabled:function(a){return!a.disabled;},disabled:function(a){return a.disabled;},checked:function(a){return a.checked;},selected:function(a){return a.selected||jQuery.attr(a,"selected");},text:function(a){return"text"==a.type;},radio:function(a){return"radio"==a.type;},checkbox:function(a){return"checkbox"==a.type;},file:function(a){return"file"==a.type;},password:function(a){return"password"==a.type;},submit:function(a){return"submit"==a.type;},image:function(a){return"image"==a.type;},reset:function(a){return"reset"==a.type;},button:function(a){return"button"==a.type||jQuery.nodeName(a,"button");},input:function(a){return/input|select|textarea|button/i.test(a.nodeName);},has:function(a,i,m){return jQuery.find(m[3],a).length;},header:function(a){return/h\d/i.test(a.nodeName);},animated:function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length;}}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&&expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,"");cur=not?elems=f.r:jQuery.merge(cur,f.r);}return cur;},find:function(t,context){if(typeof t!="string")return[t];if(context&&context.nodeType!=1&&context.nodeType!=9)return[];context=context||document;var ret=[context],done=[],last,nodeName;while(t&&last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false,re=quickChild,m=re.exec(t);if(m){nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++)for(var c=ret[i].firstChild;c;c=c.nextSibling)if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName))r.push(c);ret=r;t=t.replace(re,"");if(t.indexOf(" ")==0)continue;foundToken=true;}else{re=/^([>+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var merge={};nodeName=m[2].toUpperCase();m=m[1];for(var j=0,rl=ret.length;j=0;if(!not&&pass||not&&!pass)tmp.push(r[i]);}return tmp;},filter:function(t,r,not){var last;while(t&&t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,"");break;}}if(!m)break;if(m[1]==":"&&m[2]=="not")r=isSimple.test(m[3])?jQuery.filter(m[3],r,true).r:jQuery(r).not(m[3]);else if(m[1]==".")r=jQuery.classFilter(r,m[2],not);else if(m[1]=="["){var tmp=[],type=m[3];for(var i=0,rl=r.length;i=0)^not)tmp.push(a);}r=tmp;}else if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"0n+"+m[3]||m[3]),first=(test[1]+(test[2]||1))-0,last=test[3]-0;for(var i=0,rl=r.length;i=0)add=true;if(add^not)tmp.push(node);}r=tmp;}else{var fn=jQuery.expr[m[1]];if(typeof fn=="object")fn=fn[m[2]];if(typeof fn=="string")fn=eval("false||function(a,i){return "+fn+";}");r=jQuery.grep(r,function(elem,i){return fn(elem,i,m,r);},not);}}return{r:r,t:t};},dir:function(elem,dir){var matched=[],cur=elem[dir];while(cur&&cur!=document){if(cur.nodeType==1)matched.push(cur);cur=cur[dir];}return matched;},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir])if(cur.nodeType==1&&++num==result)break;return cur;},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&n!=elem)r.push(n);}return r;}});jQuery.event={add:function(elem,types,handler,data){if(elem.nodeType==3||elem.nodeType==8)return;if(jQuery.browser.msie&&elem.setInterval)elem=window;if(!handler.guid)handler.guid=this.guid++;if(data!=undefined){var fn=handler;handler=this.proxy(fn,function(){return fn.apply(this,arguments);});handler.data=data;}var events=jQuery.data(elem,"events")||jQuery.data(elem,"events",{}),handle=jQuery.data(elem,"handle")||jQuery.data(elem,"handle",function(){if(typeof jQuery!="undefined"&&!jQuery.event.triggered)return jQuery.event.handle.apply(arguments.callee.elem,arguments);});handle.elem=elem;jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];handler.type=parts[1];var handlers=events[type];if(!handlers){handlers=events[type]={};if(!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem)===false){if(elem.addEventListener)elem.addEventListener(type,handle,false);else if(elem.attachEvent)elem.attachEvent("on"+type,handle);}}handlers[handler.guid]=handler;jQuery.event.global[type]=true;});elem=null;},guid:1,global:{},remove:function(elem,types,handler){if(elem.nodeType==3||elem.nodeType==8)return;var events=jQuery.data(elem,"events"),ret,index;if(events){if(types==undefined||(typeof types=="string"&&types.charAt(0)=="."))for(var type in events)this.remove(elem,type+(types||""));else{if(types.type){handler=types.handler;types=types.type;}jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];if(events[type]){if(handler)delete events[type][handler.guid];else -for(handler in events[type])if(!parts[1]||events[type][handler].type==parts[1])delete events[type][handler];for(ret in events[type])break;if(!ret){if(!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem)===false){if(elem.removeEventListener)elem.removeEventListener(type,jQuery.data(elem,"handle"),false);else if(elem.detachEvent)elem.detachEvent("on"+type,jQuery.data(elem,"handle"));}ret=null;delete events[type];}}});}for(ret in events)break;if(!ret){var handle=jQuery.data(elem,"handle");if(handle)handle.elem=null;jQuery.removeData(elem,"events");jQuery.removeData(elem,"handle");}}},trigger:function(type,data,elem,donative,extra){data=jQuery.makeArray(data);if(type.indexOf("!")>=0){type=type.slice(0,-1);var exclusive=true;}if(!elem){if(this.global[type])jQuery("*").add([window,document]).trigger(type,data);}else{if(elem.nodeType==3||elem.nodeType==8)return undefined;var val,ret,fn=jQuery.isFunction(elem[type]||null),event=!data[0]||!data[0].preventDefault;if(event){data.unshift({type:type,target:elem,preventDefault:function(){},stopPropagation:function(){},timeStamp:now()});data[0][expando]=true;}data[0].type=type;if(exclusive)data[0].exclusive=true;var handle=jQuery.data(elem,"handle");if(handle)val=handle.apply(elem,data);if((!fn||(jQuery.nodeName(elem,'a')&&type=="click"))&&elem["on"+type]&&elem["on"+type].apply(elem,data)===false)val=false;if(event)data.shift();if(extra&&jQuery.isFunction(extra)){ret=extra.apply(elem,val==null?data:data.concat(val));if(ret!==undefined)val=ret;}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(elem,'a')&&type=="click")){this.triggered=true;try{elem[type]();}catch(e){}}this.triggered=false;}return val;},handle:function(event){var val,ret,namespace,all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);namespace=event.type.split(".");event.type=namespace[0];namespace=namespace[1];all=!namespace&&!event.exclusive;handlers=(jQuery.data(this,"events")||{})[event.type];for(var j in handlers){var handler=handlers[j];if(all||handler.type==namespace){event.handler=handler;event.data=handler.data;ret=handler.apply(this,arguments);if(val!==false)val=ret;if(ret===false){event.preventDefault();event.stopPropagation();}}}return val;},fix:function(event){if(event[expando]==true)return event;var originalEvent=event;event={originalEvent:originalEvent};var props="altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which".split(" ");for(var i=props.length;i;i--)event[props[i]]=originalEvent[props[i]];event[expando]=true;event.preventDefault=function(){if(originalEvent.preventDefault)originalEvent.preventDefault();originalEvent.returnValue=false;};event.stopPropagation=function(){if(originalEvent.stopPropagation)originalEvent.stopPropagation();originalEvent.cancelBubble=true;};event.timeStamp=event.timeStamp||now();if(!event.target)event.target=event.srcElement||document;if(event.target.nodeType==3)event.target=event.target.parentNode;if(!event.relatedTarget&&event.fromElement)event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement;if(event.pageX==null&&event.clientX!=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&&doc.scrollLeft||body&&body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&&doc.scrollTop||body&&body.scrollTop||0)-(doc.clientTop||0);}if(!event.which&&((event.charCode||event.charCode===0)?event.charCode:event.keyCode))event.which=event.charCode||event.keyCode;if(!event.metaKey&&event.ctrlKey)event.metaKey=event.ctrlKey;if(!event.which&&event.button)event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)));return event;},proxy:function(fn,proxy){proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++;return proxy;},special:{ready:{setup:function(){bindReady();return;},teardown:function(){return;}},mouseenter:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseover",jQuery.event.special.mouseenter.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseover",jQuery.event.special.mouseenter.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseenter";return jQuery.event.handle.apply(this,arguments);}},mouseleave:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseout",jQuery.event.special.mouseleave.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseout",jQuery.event.special.mouseleave.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseleave";return jQuery.event.handle.apply(this,arguments);}}}};jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data);});},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return(fn||data).apply(this,arguments);});return this.each(function(){jQuery.event.add(this,type,one,fn&&data);});},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn);});},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn);});},triggerHandler:function(type,data,fn){return this[0]&&jQuery.event.trigger(type,data,this[0],false,fn);},toggle:function(fn){var args=arguments,i=1;while(i=0){var selector=url.slice(off,url.length);url=url.slice(0,off);}callback=callback||function(){};var type="GET";if(params)if(jQuery.isFunction(params)){callback=params;params=null;}else{params=jQuery.param(params);type="POST";}var self=this;jQuery.ajax({url:url,type:type,dataType:"html",data:params,complete:function(res,status){if(status=="success"||status=="notmodified")self.html(selector?jQuery("
").append(res.responseText.replace(//g,"")).find(selector):res.responseText);self.each(callback,[res.responseText,status,res]);}});return this;},serialize:function(){return jQuery.param(this.serializeArray());},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this;}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type));}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val};}):{name:elem.name,value:val};}).get();}});jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f);};});var jsc=now();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null;}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type});},getScript:function(url,callback){return jQuery.get(url,null,callback,"script");},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json");},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={};}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type});},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings);},ajaxSettings:{url:location.href,global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null,username:null,password:null,accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(s){s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre=/=\?(&|$)/g,status,data,type=s.type.toUpperCase();if(s.data&&s.processData&&typeof s.data!="string")s.data=jQuery.param(s.data);if(s.dataType=="jsonp"){if(type=="GET"){if(!s.url.match(jsre))s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?";}else if(!s.data||!s.data.match(jsre))s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?";s.dataType="json";}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;if(s.data)s.data=(s.data+"").replace(jsre,"="+jsonp+"$1");s.url=s.url.replace(jsre,"="+jsonp+"$1");s.dataType="script";window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp];}catch(e){}if(head)head.removeChild(script);};}if(s.dataType=="script"&&s.cache==null)s.cache=false;if(s.cache===false&&type=="GET"){var ts=now();var ret=s.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+ts+"$2");s.url=ret+((ret==s.url)?(s.url.match(/\?/)?"&":"?")+"_="+ts:"");}if(s.data&&type=="GET"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;s.data=null;}if(s.global&&!jQuery.active++)jQuery.event.trigger("ajaxStart");var remote=/^(?:\w+:)?\/\/([^\/?#]+)/;if(s.dataType=="script"&&type=="GET"&&remote.test(s.url)&&remote.exec(s.url)[1]!=location.host){var head=document.getElementsByTagName("head")[0];var script=document.createElement("script");script.src=s.url;if(s.scriptCharset)script.charset=s.scriptCharset;if(!jsonp){var done=false;script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;success();complete();head.removeChild(script);}};}head.appendChild(script);return undefined;}var requestDone=false;var xhr=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();if(s.username)xhr.open(type,s.url,s.async,s.username,s.password);else -xhr.open(type,s.url,s.async);try{if(s.data)xhr.setRequestHeader("Content-Type",s.contentType);if(s.ifModified)xhr.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT");xhr.setRequestHeader("X-Requested-With","XMLHttpRequest");xhr.setRequestHeader("Accept",s.dataType&&s.accepts[s.dataType]?s.accepts[s.dataType]+", */*":s.accepts._default);}catch(e){}if(s.beforeSend&&s.beforeSend(xhr,s)===false){s.global&&jQuery.active--;xhr.abort();return false;}if(s.global)jQuery.event.trigger("ajaxSend",[xhr,s]);var onreadystatechange=function(isTimeout){if(!requestDone&&xhr&&(xhr.readyState==4||isTimeout=="timeout")){requestDone=true;if(ival){clearInterval(ival);ival=null;}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xhr)&&"error"||s.ifModified&&jQuery.httpNotModified(xhr,s.url)&&"notmodified"||"success";if(status=="success"){try{data=jQuery.httpData(xhr,s.dataType,s.dataFilter);}catch(e){status="parsererror";}}if(status=="success"){var modRes;try{modRes=xhr.getResponseHeader("Last-Modified");}catch(e){}if(s.ifModified&&modRes)jQuery.lastModified[s.url]=modRes;if(!jsonp)success();}else -jQuery.handleError(s,xhr,status);complete();if(s.async)xhr=null;}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout>0)setTimeout(function(){if(xhr){xhr.abort();if(!requestDone)onreadystatechange("timeout");}},s.timeout);}try{xhr.send(s.data);}catch(e){jQuery.handleError(s,xhr,null,e);}if(!s.async)onreadystatechange();function success(){if(s.success)s.success(data,status);if(s.global)jQuery.event.trigger("ajaxSuccess",[xhr,s]);}function complete(){if(s.complete)s.complete(xhr,status);if(s.global)jQuery.event.trigger("ajaxComplete",[xhr,s]);if(s.global&&!--jQuery.active)jQuery.event.trigger("ajaxStop");}return xhr;},handleError:function(s,xhr,status,e){if(s.error)s.error(xhr,status,e);if(s.global)jQuery.event.trigger("ajaxError",[xhr,s,e]);},active:0,httpSuccess:function(xhr){try{return!xhr.status&&location.protocol=="file:"||(xhr.status>=200&&xhr.status<300)||xhr.status==304||xhr.status==1223||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpNotModified:function(xhr,url){try{var xhrRes=xhr.getResponseHeader("Last-Modified");return xhr.status==304||xhrRes==jQuery.lastModified[url]||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpData:function(xhr,type,filter){var ct=xhr.getResponseHeader("content-type"),xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0,data=xml?xhr.responseXML:xhr.responseText;if(xml&&data.documentElement.tagName=="parsererror")throw"parsererror";if(filter)data=filter(data,type);if(type=="script")jQuery.globalEval(data);if(type=="json")data=eval("("+data+")");return data;},param:function(a){var s=[];if(a.constructor==Array||a.jquery)jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value));});else -for(var j in a)if(a[j]&&a[j].constructor==Array)jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this));});else -s.push(encodeURIComponent(j)+"="+encodeURIComponent(jQuery.isFunction(a[j])?a[j]():a[j]));return s.join("&").replace(/%20/g,"+");}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock||"";if(jQuery.css(this,"display")=="none"){var elem=jQuery("<"+this.tagName+" />").appendTo("body");this.style.display=elem.css("display");if(this.style.display=="none")this.style.display="block";elem.remove();}}).end();},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");this.style.display="none";}).end();},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]();});},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback);},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback);},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback);},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback);},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback);},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback);},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[optall.queue===false?"each":"queue"](function(){if(this.nodeType!=1)return false;var opt=jQuery.extend({},optall),p,hidden=jQuery(this).is(":hidden"),self=this;for(p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden)return opt.complete.call(this);if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");opt.overflow=this.style.overflow;}}if(opt.overflow!=null)this.style.overflow="hidden";opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val))e[val=="toggle"?hidden?"show":"hide":val](prop);else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";if(unit!="px"){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit;}if(parts[1])end=((parts[1]=="-="?-1:1)*end)+start;e.custom(start,end,unit);}else -e.custom(start,val,"");}});return true;});},queue:function(type,fn){if(jQuery.isFunction(type)||(type&&type.constructor==Array)){fn=type;type="fx";}if(!type||(typeof type=="string"&&!fn))return queue(this[0],type);return this.each(function(){if(fn.constructor==Array)queue(this,type,fn);else{queue(this,type).push(fn);if(queue(this,type).length==1)fn.call(this);}});},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if(clearQueue)this.queue([]);this.each(function(){for(var i=timers.length-1;i>=0;i--)if(timers[i].elem==this){if(gotoEnd)timers[i](true);timers.splice(i,1);}});if(!gotoEnd)this.dequeue();return this;}});var queue=function(elem,type,array){if(elem){type=type||"fx";var q=jQuery.data(elem,type+"queue");if(!q||array)q=jQuery.data(elem,type+"queue",jQuery.makeArray(array));}return q;};jQuery.fn.dequeue=function(type){type=type||"fx";return this.each(function(){var q=queue(this,type);q.shift();if(q.length)q[0].call(this);});};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:jQuery.fx.speeds[opt.duration])||jQuery.fx.speeds.def;opt.old=opt.complete;opt.complete=function(){if(opt.queue!==false)jQuery(this).dequeue();if(jQuery.isFunction(opt.old))opt.old.call(this);};return opt;},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p;},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum;}},timers:[],timerId:null,fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig)options.orig={};}});jQuery.fx.prototype={update:function(){if(this.options.step)this.options.step.call(this.elem,this.now,this);(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop=="height"||this.prop=="width")this.elem.style.display="block";},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null)return this.elem[this.prop];var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0;},custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit||"px";this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(gotoEnd){return self.step(gotoEnd);}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timerId==null){jQuery.timerId=setInterval(function(){var timers=jQuery.timers;for(var i=0;ithis.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim)if(this.options.curAnim[i]!==true)done=false;if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,"display")=="none")this.elem.style.display="block";}if(this.options.hide)this.elem.style.display="none";if(this.options.hide||this.options.show)for(var p in this.options.curAnim)jQuery.attr(this.elem.style,p,this.options.orig[p]);}if(done)this.options.complete.call(this.elem);return false;}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update();}return true;}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200,def:400},step:{scrollLeft:function(fx){fx.elem.scrollLeft=fx.now;},scrollTop:function(fx){fx.elem.scrollTop=fx.now;},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now);},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit;}}});jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem)with(jQuery.browser){var parent=elem.parentNode,offsetChild=elem,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522&&!/adobeair/i.test(userAgent),css=jQuery.curCSS,fixed=css(elem,"position")=="fixed";if(elem.getBoundingClientRect){var box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));add(-doc.documentElement.clientLeft,-doc.documentElement.clientTop);}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&&!/^t(able|d|h)$/i.test(offsetParent.tagName)||safari&&!safari2)border(offsetParent);if(!fixed&&css(offsetParent,"position")=="fixed")fixed=true;offsetChild=/^body$/i.test(offsetParent.tagName)?offsetChild:offsetParent;offsetParent=offsetParent.offsetParent;}while(parent&&parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table.*$/i.test(css(parent,"display")))add(-parent.scrollLeft,-parent.scrollTop);if(mozilla&&css(parent,"overflow")!="visible")border(parent);parent=parent.parentNode;}if((safari2&&(fixed||css(offsetChild,"position")=="absolute"))||(mozilla&&css(offsetChild,"position")!="absolute"))add(-doc.body.offsetLeft,-doc.body.offsetTop);if(fixed)add(Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));}results={top:top,left:left};}function border(elem){add(jQuery.curCSS(elem,"borderLeftWidth",true),jQuery.curCSS(elem,"borderTopWidth",true));}function add(l,t){left+=parseInt(l,10)||0;top+=parseInt(t,10)||0;}return results;};jQuery.fn.extend({position:function(){var left=0,top=0,results;if(this[0]){var offsetParent=this.offsetParent(),offset=this.offset(),parentOffset=/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset();offset.top-=num(this,'marginTop');offset.left-=num(this,'marginLeft');parentOffset.top+=num(offsetParent,'borderTopWidth');parentOffset.left+=num(offsetParent,'borderLeftWidth');results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left};}return results;},offsetParent:function(){var offsetParent=this[0].offsetParent;while(offsetParent&&(!/^body|html$/i.test(offsetParent.tagName)&&jQuery.css(offsetParent,'position')=='static'))offsetParent=offsetParent.offsetParent;return jQuery(offsetParent);}});jQuery.each(['Left','Top'],function(i,name){var method='scroll'+name;jQuery.fn[method]=function(val){if(!this[0])return;return val!=undefined?this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[method]=val;}):this[0]==window||this[0]==document?self[i?'pageYOffset':'pageXOffset']||jQuery.boxModel&&document.documentElement[method]||document.body[method]:this[0][method];};});jQuery.each(["Height","Width"],function(i,name){var tl=i?"Left":"Top",br=i?"Right":"Bottom";jQuery.fn["inner"+name]=function(){return this[name.toLowerCase()]()+num(this,"padding"+tl)+num(this,"padding"+br);};jQuery.fn["outer"+name]=function(margin){return this["inner"+name]()+num(this,"border"+tl+"Width")+num(this,"border"+br+"Width")+(margin?num(this,"margin"+tl)+num(this,"margin"+br):0);};});})(); \ No newline at end of file diff --git a/code_ruby/Maasha/lib/doc/js/quicksearch.js b/code_ruby/Maasha/lib/doc/js/quicksearch.js deleted file mode 100644 index 70dbd33..0000000 --- a/code_ruby/Maasha/lib/doc/js/quicksearch.js +++ /dev/null @@ -1,114 +0,0 @@ -/** - * - * JQuery QuickSearch - Hook up a form field to hide non-matching elements. - * $Id: quicksearch.js 53 2009-01-07 02:52:03Z deveiant $ - * - * Author: Michael Granger - * - */ -jQuery.fn.quicksearch = function( target, searchElems, options ) { - // console.debug( "Quicksearch fn" ); - - var settings = { - delay: 250, - clearButton: false, - highlightMatches: false, - focusOnLoad: false, - noSearchResultsIndicator: null - }; - if ( options ) $.extend( settings, options ); - - return jQuery(this).each( function() { - // console.debug( "Creating a new quicksearch on %o for %o", this, searchElems ); - new jQuery.quicksearch( this, searchElems, settings ); - }); -}; - - -jQuery.quicksearch = function( searchBox, searchElems, settings ) { - var timeout; - var boxdiv = $(searchBox).parents('div').eq(0); - - function init() { - setupKeyEventHandlers(); - focusOnLoad(); - }; - - function setupKeyEventHandlers() { - // console.debug( "Hooking up the 'keypress' event to %o", searchBox ); - $(searchBox). - unbind( 'keyup' ). - keyup( function(e) { return onSearchKey( e.keyCode ); }); - $(searchBox). - unbind( 'keypress' ). - keypress( function(e) { - switch( e.which ) { - // Execute the search on Enter, Tab, or Newline - case 9: - case 13: - case 10: - clearTimeout( timeout ); - e.preventDefault(); - doQuickSearch(); - break; - - // Allow backspace - case 8: - return true; - break; - - // Only allow valid search characters - default: - return validQSChar( e.charCode ); - } - }); - }; - - function focusOnLoad() { - if ( !settings.focusOnLoad ) return false; - $(searchBox).focus(); - }; - - function onSearchKey ( code ) { - clearTimeout( timeout ); - // console.debug( "...scheduling search." ); - timeout = setTimeout( doQuickSearch, settings.delay ); - }; - - function validQSChar( code ) { - var c = String.fromCharCode( code ); - return ( - (c == ':') || - (c >= 'a' && c <= 'z') || - (c >= 'A' && c <= 'Z') - ); - }; - - function doQuickSearch() { - var searchText = searchBox.value; - var pat = new RegExp( searchText, "im" ); - var shownCount = 0; - - if ( settings.noSearchResultsIndicator ) { - $('#' + settings.noSearchResultsIndicator).hide(); - } - - // All elements start out hidden - $(searchElems).each( function(index) { - var str = $(this).text(); - - if ( pat.test(str) ) { - shownCount += 1; - $(this).fadeIn(); - } else { - $(this).hide(); - } - }); - - if ( shownCount == 0 && settings.noSearchResultsIndicator ) { - $('#' + settings.noSearchResultsIndicator).slideDown(); - } - }; - - init(); -}; diff --git a/code_ruby/Maasha/lib/doc/js/thickbox-compressed.js b/code_ruby/Maasha/lib/doc/js/thickbox-compressed.js deleted file mode 100644 index 3a3fdae..0000000 --- a/code_ruby/Maasha/lib/doc/js/thickbox-compressed.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - * Thickbox 3 - One Box To Rule Them All. - * By Cody Lindley (http://www.codylindley.com) - * Copyright (c) 2007 cody lindley - * Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php -*/ - -var tb_pathToImage = "../images/loadingAnimation.gif"; - -eval(function(p,a,c,k,e,r){e=function(c){return(c35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('$(o).2S(9(){1u(\'a.18, 3n.18, 3i.18\');1w=1p 1t();1w.L=2H});9 1u(b){$(b).s(9(){6 t=X.Q||X.1v||M;6 a=X.u||X.23;6 g=X.1N||P;19(t,a,g);X.2E();H P})}9 19(d,f,g){3m{3(2t o.v.J.2i==="2g"){$("v","11").r({A:"28%",z:"28%"});$("11").r("22","2Z");3(o.1Y("1F")===M){$("v").q("<4 5=\'B\'><4 5=\'8\'>");$("#B").s(G)}}n{3(o.1Y("B")===M){$("v").q("<4 5=\'B\'><4 5=\'8\'>");$("#B").s(G)}}3(1K()){$("#B").1J("2B")}n{$("#B").1J("2z")}3(d===M){d=""}$("v").q("<4 5=\'K\'><1I L=\'"+1w.L+"\' />");$(\'#K\').2y();6 h;3(f.O("?")!==-1){h=f.3l(0,f.O("?"))}n{h=f}6 i=/\\.2s$|\\.2q$|\\.2m$|\\.2l$|\\.2k$/;6 j=h.1C().2h(i);3(j==\'.2s\'||j==\'.2q\'||j==\'.2m\'||j==\'.2l\'||j==\'.2k\'){1D="";1G="";14="";1z="";1x="";R="";1n="";1r=P;3(g){E=$("a[@1N="+g+"]").36();25(D=0;((D&1d;&1d;2T &2R;"}n{1D=E[D].Q;1G=E[D].u;14="<1e 5=\'1U\'>&1d;&1d;&2O; 2N"}}n{1r=1b;1n="1t "+(D+1)+" 2L "+(E.1c)}}}S=1p 1t();S.1g=9(){S.1g=M;6 a=2x();6 x=a[0]-1M;6 y=a[1]-1M;6 b=S.z;6 c=S.A;3(b>x){c=c*(x/b);b=x;3(c>y){b=b*(y/c);c=y}}n 3(c>y){b=b*(y/c);c=y;3(b>x){c=c*(x/b);b=x}}13=b+30;1a=c+2G;$("#8").q("<1I 5=\'2F\' L=\'"+f+"\' z=\'"+b+"\' A=\'"+c+"\' 23=\'"+d+"\'/>"+"<4 5=\'2D\'>"+d+"<4 5=\'2C\'>"+1n+14+R+"<4 5=\'2A\'>1l 1k 1j 1s");$("#Z").s(G);3(!(14==="")){9 12(){3($(o).N("s",12)){$(o).N("s",12)}$("#8").C();$("v").q("<4 5=\'8\'>");19(1D,1G,g);H P}$("#1U").s(12)}3(!(R==="")){9 1i(){$("#8").C();$("v").q("<4 5=\'8\'>");19(1z,1x,g);H P}$("#1X").s(1i)}o.1h=9(e){3(e==M){I=2w.2v}n{I=e.2u}3(I==27){G()}n 3(I==3k){3(!(R=="")){o.1h="";1i()}}n 3(I==3j){3(!(14=="")){o.1h="";12()}}};16();$("#K").C();$("#1L").s(G);$("#8").r({Y:"T"})};S.L=f}n{6 l=f.2r(/^[^\\?]+\\??/,\'\');6 m=2p(l);13=(m[\'z\']*1)+30||3h;1a=(m[\'A\']*1)+3g||3f;W=13-30;V=1a-3e;3(f.O(\'2j\')!=-1){1E=f.1B(\'3d\');$("#15").C();3(m[\'1A\']!="1b"){$("#8").q("<4 5=\'2f\'><4 5=\'1H\'>"+d+"<4 5=\'2e\'>1l 1k 1j 1s ")}n{$("#B").N();$("#8").q(" ")}}n{3($("#8").r("Y")!="T"){3(m[\'1A\']!="1b"){$("#8").q("<4 5=\'2f\'><4 5=\'1H\'>"+d+"<4 5=\'2e\'>1l 1k 1j 1s<4 5=\'F\' J=\'z:"+W+"p;A:"+V+"p\'>")}n{$("#B").N();$("#8").q("<4 5=\'F\' 3c=\'3b\' J=\'z:"+W+"p;A:"+V+"p;\'>")}}n{$("#F")[0].J.z=W+"p";$("#F")[0].J.A=V+"p";$("#F")[0].3a=0;$("#1H").11(d)}}$("#Z").s(G);3(f.O(\'37\')!=-1){$("#F").q($(\'#\'+m[\'26\']).1T());$("#8").24(9(){$(\'#\'+m[\'26\']).q($("#F").1T())});16();$("#K").C();$("#8").r({Y:"T"})}n 3(f.O(\'2j\')!=-1){16();3($.1q.35){$("#K").C();$("#8").r({Y:"T"})}}n{$("#F").34(f+="&1y="+(1p 33().32()),9(){16();$("#K").C();1u("#F a.18");$("#8").r({Y:"T"})})}}3(!m[\'1A\']){o.21=9(e){3(e==M){I=2w.2v}n{I=e.2u}3(I==27){G()}}}}31(e){}}9 1m(){$("#K").C();$("#8").r({Y:"T"})}9 G(){$("#2Y").N("s");$("#Z").N("s");$("#8").2X("2W",9(){$(\'#8,#B,#1F\').2V("24").N().C()});$("#K").C();3(2t o.v.J.2i=="2g"){$("v","11").r({A:"1Z",z:"1Z"});$("11").r("22","")}o.1h="";o.21="";H P}9 16(){$("#8").r({2U:\'-\'+20((13/2),10)+\'p\',z:13+\'p\'});3(!(1V.1q.2Q&&1V.1q.2P<7)){$("#8").r({38:\'-\'+20((1a/2),10)+\'p\'})}}9 2p(a){6 b={};3(!a){H b}6 c=a.1B(/[;&]/);25(6 i=0;i :link, td > :visited { - background: transparent; - color: #039; - text-decoration: none; -} - -/* and inside a section title */ -.section-title > :link, .section-title > :visited { - background: transparent; - color: #eee; - text-decoration: none; -} - -/* === Structural elements =================================== */ - -.index { - margin: 0; - margin-left: -40px; - padding: 0; - font-size: 90%; -} - -.index :link, .index :visited { - margin-left: 0.7em; -} - -.index .section-bar { - margin-left: 0px; - padding-left: 0.7em; - background: #ccc; - font-size: small; -} - -#classHeader, #fileHeader { - width: auto; - color: white; - padding: 0.5em 1.5em 0.5em 1.5em; - margin: 0; - margin-left: -40px; - border-bottom: 3px solid #006; -} - -#classHeader :link, #fileHeader :link, -#classHeader :visited, #fileHeader :visited { - background: inherit; - color: white; -} - -#classHeader td, #fileHeader td { - background: inherit; - color: white; -} - -#fileHeader { - background: #057; -} - -#classHeader { - background: #048; -} - -.class-name-in-header { - font-size: 180%; - font-weight: bold; -} - -#bodyContent { - padding: 0 1.5em 0 1.5em; -} - -#description { - padding: 0.5em 1.5em; - background: #efefef; - border: 1px dotted #999; -} - -#description h1, #description h2, #description h3, -#description h4, #description h5, #description h6 { - color: #125; - background: transparent; -} - -#validator-badges { - text-align: center; -} - -#validator-badges img { - border: 0; -} - -#copyright { - color: #333; - background: #efefef; - font: 0.75em sans-serif; - margin-top: 5em; - margin-bottom: 0; - padding: 0.5em 2em; -} - -/* === Classes =================================== */ - -table.header-table { - color: white; - font-size: small; -} - -.type-note { - font-size: small; - color: #dedede; -} - -.section-bar { - color: #333; - border-bottom: 1px solid #999; - margin-left: -20px; -} - -.section-title { - background: #79a; - color: #eee; - padding: 3px; - margin-top: 2em; - margin-left: -30px; - border: 1px solid #999; -} - -.top-aligned-row { - vertical-align: top -} - -.bottom-aligned-row { - vertical-align: bottom -} - -#diagram img { - border: 0; -} - -/* --- Context section classes ----------------------- */ - -.context-row { } - -.context-item-name { - font-family: monospace; - font-weight: bold; - color: black; -} - -.context-item-value { - font-size: small; - color: #448; -} - -.context-item-desc { - color: #333; - padding-left: 2em; -} - -/* --- Method classes -------------------------- */ - -.method-detail { - background: #efefef; - padding: 0; - margin-top: 0.5em; - margin-bottom: 1em; - border: 1px dotted #ccc; -} - -.method-heading { - color: black; - background: #ccc; - border-bottom: 1px solid #666; - padding: 0.2em 0.5em 0 0.5em; -} - -.method-signature { - color: black; - background: inherit; -} - -.method-name { - font-weight: bold; -} - -.method-args { - font-style: italic; -} - -.method-description { - padding: 0 0.5em 0 0.5em; -} - -/* --- Source code sections -------------------- */ - -:link.source-toggle, :visited.source-toggle { - font-size: 90%; -} - -div.method-source-code { - background: #262626; - color: #ffdead; - margin: 1em; - padding: 0.5em; - border: 1px dashed #999; - overflow: auto; -} - -div.method-source-code pre { - color: #ffdead; -} - -/* --- Ruby keyword styles --------------------- */ - -.standalone-code { - background: #221111; - color: #ffdead; - overflow: auto; -} - -.ruby-constant { - color: #7fffd4; - background: transparent; -} - -.ruby-keyword { - color: #00ffff; - background: transparent; -} - -.ruby-ivar { - color: #eedd82; - background: transparent; -} - -.ruby-operator { - color: #00ffee; - background: transparent; -} - -.ruby-identifier { - color: #ffdead; - background: transparent; -} - -.ruby-node { - color: #ffa07a; - background: transparent; -} - -.ruby-comment { - color: #b22222; - font-weight: bold; - background: transparent; -} - -.ruby-regexp { - color: #ffa07a; - background: transparent; -} - -.ruby-value { - color: #7fffd4; - background: transparent; -} diff --git a/code_ruby/Maasha/lib/doc/rdoc.css b/code_ruby/Maasha/lib/doc/rdoc.css deleted file mode 100644 index ffe9960..0000000 --- a/code_ruby/Maasha/lib/doc/rdoc.css +++ /dev/null @@ -1,706 +0,0 @@ -/* - * "Darkfish" Rdoc CSS - * $Id: rdoc.css 54 2009-01-27 01:09:48Z deveiant $ - * - * Author: Michael Granger - * - */ - -/* Base Green is: #6C8C22 */ - -*{ padding: 0; margin: 0; } - -body { - background: #efefef; - font: 14px "Helvetica Neue", Helvetica, Tahoma, sans-serif; -} -body.class, body.module, body.file { - margin-left: 40px; -} -body.file-popup { - font-size: 90%; - margin-left: 0; -} - -h1 { - font-size: 300%; - text-shadow: rgba(135,145,135,0.65) 2px 2px 3px; - color: #6C8C22; -} -h2,h3,h4 { margin-top: 1.5em; } - -:link, -:visited { - color: #6C8C22; - text-decoration: none; -} -:link:hover, -:visited:hover { - border-bottom: 1px dotted #6C8C22; -} - -pre { - background: #ddd; - padding: 0.5em 0; -} - - -/* @group Generic Classes */ - -.initially-hidden { - display: none; -} - -.quicksearch-field { - width: 98%; - background: #ddd; - border: 1px solid #aaa; - height: 1.5em; - -webkit-border-radius: 4px; -} -.quicksearch-field:focus { - background: #f1edba; -} - -.missing-docs { - font-size: 120%; - background: white url(images/wrench_orange.png) no-repeat 4px center; - color: #ccc; - line-height: 2em; - border: 1px solid #d00; - opacity: 1; - padding-left: 20px; - text-indent: 24px; - letter-spacing: 3px; - font-weight: bold; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; -} - -.target-section { - border: 2px solid #dcce90; - border-left-width: 8px; - padding: 0 1em; - background: #fff3c2; -} - -/* @end */ - - -/* @group Index Page, Standalone file pages */ -body.indexpage { - margin: 1em 3em; -} -body.indexpage p, -body.indexpage div, -body.file p { - margin: 1em 0; -} - -.indexpage ul, -.file #documentation ul { - line-height: 160%; - list-style: none; -} -.indexpage ul :link, -.indexpage ul :visited { - font-size: 16px; -} - -.indexpage li, -.file #documentation li { - padding-left: 20px; - background: url(images/bullet_black.png) no-repeat left 4px; -} -.indexpage li.module { - background: url(images/package.png) no-repeat left 4px; -} -.indexpage li.class { - background: url(images/ruby.png) no-repeat left 4px; -} -.indexpage li.file { - background: url(images/page_white_text.png) no-repeat left 4px; -} -.file li p, -.indexpage li p { - margin: 0 0; -} - -/* @end */ - -/* @group Top-Level Structure */ - -.class #metadata, -.file #metadata, -.module #metadata { - float: left; - width: 260px; -} - -.class #documentation, -.file #documentation, -.module #documentation { - margin: 2em 1em 5em 300px; - min-width: 340px; -} - -.file #metadata { - margin: 0.8em; -} - -#validator-badges { - clear: both; - margin: 1em 1em 2em; -} - -/* @end */ - -/* @group Metadata Section */ -#metadata .section { - background-color: #dedede; - -moz-border-radius: 5px; - -webkit-border-radius: 5px; - border: 1px solid #aaa; - margin: 0 8px 16px; - font-size: 90%; - overflow: hidden; -} -#metadata h3.section-header { - margin: 0; - padding: 2px 8px; - background: #ccc; - color: #666; - -moz-border-radius-topleft: 4px; - -moz-border-radius-topright: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - border-bottom: 1px solid #aaa; -} -#metadata #home-section h3.section-header { - border-bottom: 0; -} - -#metadata ul, -#metadata dl, -#metadata p { - padding: 8px; - list-style: none; -} - -#file-metadata ul { - padding-left: 28px; - list-style-image: url(images/page_green.png); -} - -dl.svninfo { - color: #666; - margin: 0; -} -dl.svninfo dt { - font-weight: bold; -} - -ul.link-list li { - white-space: nowrap; -} -ul.link-list .type { - font-size: 8px; - text-transform: uppercase; - color: white; - background: #969696; - padding: 2px 4px; - -webkit-border-radius: 5px; -} - -/* @end */ - - -/* @group Project Metadata Section */ -#project-metadata { - margin-top: 3em; -} - -.file #project-metadata { - margin-top: 0em; -} - -#project-metadata .section { - border: 1px solid #aaa; -} -#project-metadata h3.section-header { - border-bottom: 1px solid #aaa; - position: relative; -} -#project-metadata h3.section-header .search-toggle { - position: absolute; - right: 5px; -} - - -#project-metadata form { - color: #777; - background: #ccc; - padding: 8px 8px 16px; - border-bottom: 1px solid #bbb; -} -#project-metadata fieldset { - border: 0; -} - -#no-class-search-results { - margin: 0 auto 1em; - text-align: center; - font-size: 14px; - font-weight: bold; - color: #aaa; -} - -/* @end */ - - -/* @group Documentation Section */ -#description { - font-size: 100%; - color: #333; -} - -#description p { - margin: 1em 0.4em; -} - -#description li p { - margin: 0; -} - -#description ul { - margin-left: 1.5em; -} -#description ul li { - line-height: 1.4em; -} - -#description dl, -#documentation dl { - margin: 8px 1.5em; - border: 1px solid #ccc; -} -#description dl { - font-size: 14px; -} - -#description dt, -#documentation dt { - padding: 2px 4px; - font-weight: bold; - background: #ddd; -} -#description dd, -#documentation dd { - padding: 2px 12px; -} -#description dd + dt, -#documentation dd + dt { - margin-top: 0.7em; -} - -#documentation .section { - font-size: 90%; -} -#documentation h3.section-header { - margin-top: 2em; - padding: 0.75em 0.5em; - background-color: #dedede; - color: #333; - font-size: 150%; - border: 1px solid #bbb; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; -} - -#constants-list > dl, -#attributes-list > dl { - margin: 1em 0 2em; - border: 0; -} -#constants-list > dl dt, -#attributes-list > dl dt { - padding-left: 0; - font-weight: bold; - font-family: Monaco, "Andale Mono"; - background: inherit; -} -#constants-list > dl dt a, -#attributes-list > dl dt a { - color: inherit; -} -#constants-list > dl dd, -#attributes-list > dl dd { - margin: 0 0 1em 0; - padding: 0; - color: #666; -} - -/* @group Method Details */ - -#documentation .method-source-code { - display: none; -} - -#documentation .method-detail { - margin: 0.5em 0; - padding: 0.5em 0; - cursor: pointer; -} -#documentation .method-detail:hover { - background-color: #f1edba; -} -#documentation .method-heading { - position: relative; - padding: 2px 4px 0 20px; - font-size: 125%; - font-weight: bold; - color: #333; - background: url(images/brick.png) no-repeat left bottom; -} -#documentation .method-heading :link, -#documentation .method-heading :visited { - color: inherit; -} -#documentation .method-click-advice { - position: absolute; - top: 2px; - right: 5px; - font-size: 10px; - color: #9b9877; - visibility: hidden; - padding-right: 20px; - line-height: 20px; - background: url(images/zoom.png) no-repeat right top; -} -#documentation .method-detail:hover .method-click-advice { - visibility: visible; -} - -#documentation .method-alias .method-heading { - color: #666; - background: url(images/brick_link.png) no-repeat left bottom; -} - -#documentation .method-description, -#documentation .aliases { - margin: 0 20px; - line-height: 1.2em; - color: #666; -} -#documentation .aliases { - padding-top: 4px; - font-style: italic; - cursor: default; -} -#documentation .method-description p { - padding: 0; -} -#documentation .method-description p + p { - margin-bottom: 0.5em; -} -#documentation .method-description ul { - margin-left: 1.5em; -} - -#documentation .attribute-method-heading { - background: url(images/tag_green.png) no-repeat left bottom; -} -#documentation #attribute-method-details .method-detail:hover { - background-color: transparent; - cursor: default; -} -#documentation .attribute-access-type { - font-size: 60%; - text-transform: uppercase; - vertical-align: super; - padding: 0 2px; -} -/* @end */ - -/* @end */ - - - -/* @group Source Code */ - -div.method-source-code { - background: #262626; - color: #efefef; - margin: 1em; - padding: 0.5em; - border: 1px dashed #999; - overflow: hidden; -} - -div.method-source-code pre { - background: inherit; - padding: 0; - color: white; - overflow: auto; -} - -/* @group Ruby keyword styles */ - -.ruby-constant { color: #7fffd4; background: transparent; } -.ruby-keyword { color: #00ffff; background: transparent; } -.ruby-ivar { color: #eedd82; background: transparent; } -.ruby-operator { color: #00ffee; background: transparent; } -.ruby-identifier { color: #ffdead; background: transparent; } -.ruby-node { color: #ffa07a; background: transparent; } -.ruby-comment { color: #b22222; font-weight: bold; background: transparent; } -.ruby-regexp { color: #ffa07a; background: transparent; } -.ruby-value { color: #7fffd4; background: transparent; } - -/* @end */ -/* @end */ - - -/* @group File Popup Contents */ - -.file #metadata, -.file-popup #metadata { -} - -.file-popup dl { - font-size: 80%; - padding: 0.75em; - background-color: #dedede; - color: #333; - border: 1px solid #bbb; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; -} -.file dt { - font-weight: bold; - padding-left: 22px; - line-height: 20px; - background: url(images/page_white_width.png) no-repeat left top; -} -.file dt.modified-date { - background: url(images/date.png) no-repeat left top; -} -.file dt.requires { - background: url(images/plugin.png) no-repeat left top; -} -.file dt.scs-url { - background: url(images/wrench.png) no-repeat left top; -} - -.file dl dd { - margin: 0 0 1em 0; -} -.file #metadata dl dd ul { - list-style: circle; - margin-left: 20px; - padding-top: 0; -} -.file #metadata dl dd ul li { -} - - -.file h2 { - margin-top: 2em; - padding: 0.75em 0.5em; - background-color: #dedede; - color: #333; - font-size: 120%; - border: 1px solid #bbb; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; -} - -/* @end */ - - - - -/* @group ThickBox Styles */ -#TB_window { - font: 12px Arial, Helvetica, sans-serif; - color: #333333; -} - -#TB_secondLine { - font: 10px Arial, Helvetica, sans-serif; - color:#666666; -} - -#TB_window :link, -#TB_window :visited { color: #666666; } -#TB_window :link:hover, -#TB_window :visited:hover { color: #000; } -#TB_window :link:active, -#TB_window :visited:active { color: #666666; } -#TB_window :link:focus, -#TB_window :visited:focus { color: #666666; } - -#TB_overlay { - position: fixed; - z-index:100; - top: 0px; - left: 0px; - height:100%; - width:100%; -} - -.TB_overlayMacFFBGHack {background: url(images/macFFBgHack.png) repeat;} -.TB_overlayBG { - background-color:#000; - filter:alpha(opacity=75); - -moz-opacity: 0.75; - opacity: 0.75; -} - -* html #TB_overlay { /* ie6 hack */ - position: absolute; - height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); -} - -#TB_window { - position: fixed; - background: #ffffff; - z-index: 102; - color:#000000; - display:none; - border: 4px solid #525252; - text-align:left; - top:50%; - left:50%; -} - -* html #TB_window { /* ie6 hack */ -position: absolute; -margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); -} - -#TB_window img#TB_Image { - display:block; - margin: 15px 0 0 15px; - border-right: 1px solid #ccc; - border-bottom: 1px solid #ccc; - border-top: 1px solid #666; - border-left: 1px solid #666; -} - -#TB_caption{ - height:25px; - padding:7px 30px 10px 25px; - float:left; -} - -#TB_closeWindow{ - height:25px; - padding:11px 25px 10px 0; - float:right; -} - -#TB_closeAjaxWindow{ - padding:7px 10px 5px 0; - margin-bottom:1px; - text-align:right; - float:right; -} - -#TB_ajaxWindowTitle{ - float:left; - padding:7px 0 5px 10px; - margin-bottom:1px; - font-size: 22px; -} - -#TB_title{ - background-color: #6C8C22; - color: #dedede; - height:40px; -} -#TB_title :link, -#TB_title :visited { - color: white !important; - border-bottom: 1px dotted #dedede; -} - -#TB_ajaxContent{ - clear:both; - padding:2px 15px 15px 15px; - overflow:auto; - text-align:left; - line-height:1.4em; -} - -#TB_ajaxContent.TB_modal{ - padding:15px; -} - -#TB_ajaxContent p{ - padding:5px 0px 5px 0px; -} - -#TB_load{ - position: fixed; - display:none; - height:13px; - width:208px; - z-index:103; - top: 50%; - left: 50%; - margin: -6px 0 0 -104px; /* -height/2 0 0 -width/2 */ -} - -* html #TB_load { /* ie6 hack */ -position: absolute; -margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); -} - -#TB_HideSelect{ - z-index:99; - position:fixed; - top: 0; - left: 0; - background-color:#fff; - border:none; - filter:alpha(opacity=0); - -moz-opacity: 0; - opacity: 0; - height:100%; - width:100%; -} - -* html #TB_HideSelect { /* ie6 hack */ - position: absolute; - height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); -} - -#TB_iframeContent{ - clear:both; - border:none; - margin-bottom:-1px; - margin-top:1px; - _margin-bottom:1px; -} - -/* @end */ - -/* @group Debugging Section */ - -#debugging-toggle { - text-align: center; -} -#debugging-toggle img { - cursor: pointer; -} - -#rdoc-debugging-section-dump { - display: none; - margin: 0 2em 2em; - background: #ccc; - border: 1px solid #999; -} - - - -/* @end */ diff --git a/code_ruby/Maasha/lib/doc/seq_rb.html b/code_ruby/Maasha/lib/doc/seq_rb.html deleted file mode 100644 index 3c50f10..0000000 --- a/code_ruby/Maasha/lib/doc/seq_rb.html +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - - File: seq.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-03-19 16:29:08 +0100
- - -
Requires
-
-
    - -
  • amatch
  • - -
  • digest
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2007-2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Maasha/lib/doc/sff_rb.html b/code_ruby/Maasha/lib/doc/sff_rb.html deleted file mode 100644 index 294f9a0..0000000 --- a/code_ruby/Maasha/lib/doc/sff_rb.html +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - - - File: sff.rb [RDoc Documentation] - - - - - - - - - - -
-
-
Last Modified
-
2011-02-11 19:55:38 +0100
- - -
Requires
-
-
    - -
  • base36
  • - -
-
- - - -
-
- -
- -
-

Description

-

-Copyright (C) 2011 Martin A. Hansen. -

- -
- -
- - - diff --git a/code_ruby/Sfern/test_module.rb b/code_ruby/Sfern/test_module.rb deleted file mode 100755 index 681661c..0000000 --- a/code_ruby/Sfern/test_module.rb +++ /dev/null @@ -1,7 +0,0 @@ -class Test - puts "Modules Test2 loaded" - - def greet_world - puts "World" - end -end diff --git a/code_ruby/Maasha/lib/base36.rb b/code_ruby/lib/maasha/base36.rb similarity index 100% rename from code_ruby/Maasha/lib/base36.rb rename to code_ruby/lib/maasha/base36.rb diff --git a/code_ruby/Maasha/lib/biopieces.rb b/code_ruby/lib/maasha/biopieces.rb similarity index 100% rename from code_ruby/Maasha/lib/biopieces.rb rename to code_ruby/lib/maasha/biopieces.rb diff --git a/code_ruby/Maasha/lib/bitarray.rb b/code_ruby/lib/maasha/bitarray.rb similarity index 100% rename from code_ruby/Maasha/lib/bitarray.rb rename to code_ruby/lib/maasha/bitarray.rb diff --git a/code_ruby/Maasha/lib/bits.rb b/code_ruby/lib/maasha/bits.rb similarity index 100% rename from code_ruby/Maasha/lib/bits.rb rename to code_ruby/lib/maasha/bits.rb diff --git a/code_ruby/lib/maasha/boulder.rb b/code_ruby/lib/maasha/boulder.rb new file mode 100644 index 0000000..2a484a4 --- /dev/null +++ b/code_ruby/lib/maasha/boulder.rb @@ -0,0 +1,78 @@ +# Copyright (C) 2007-2011 Martin A. Hansen. + +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# http://www.gnu.org/copyleft/gpl.html + +# >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< + +# This software is part of the Biopieces framework (www.biopieces.org). + +# >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< + +require 'maasha/filesys' + +# Error class for all exceptions to do with Boulder. +class BoulderError < StandardError; end + +# Record seperator +SEP = "\n=\n" + +# Class to manipulate boulder records - Lincoln Steins own +# YAML like format: +# http://stein.cshl.org/boulder/docs/Boulder.html +class Boulder < Filesys + # Initialize a Boulder object. + # Options are for testing purposes only. + def initialize(input=STDIN, output=STDOUT) + @input = input + @output = output + end + + def each + while not @input.eof? do + block = @input.gets(SEP) + raise BoulderError, "Missing record seperator" unless block =~ /#{SEP}$/ + + record = {} + + block.chomp(SEP).each_line do |line| + key, val = line.chomp.split('=', 2) + + raise BoulderError, "Missing key/value seperator" if val.nil? + raise BoulderError, "Missing key" if key.empty? + raise BoulderError, "Missing value" if val.empty? + + record[key.to_sym] = val + end + + yield record + end + end + + # Method that converts and returns a hash record as + # a Boulder string. + def to_boulder(record) + str = "" + + record.each_pair do |key, val| + str << "#{key}=#{val}\n" + end + + str << "=\n" + + str + end +end diff --git a/code_ruby/Maasha/lib/digest.rb b/code_ruby/lib/maasha/digest.rb similarity index 100% rename from code_ruby/Maasha/lib/digest.rb rename to code_ruby/lib/maasha/digest.rb diff --git a/code_ruby/Maasha/lib/fasta.rb b/code_ruby/lib/maasha/fasta.rb similarity index 97% rename from code_ruby/Maasha/lib/fasta.rb rename to code_ruby/lib/maasha/fasta.rb index e972751..f57a622 100644 --- a/code_ruby/Maasha/lib/fasta.rb +++ b/code_ruby/lib/maasha/fasta.rb @@ -22,8 +22,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'seq' -require 'filesys' +require 'maasha/seq' +require 'maasha/filesys' # Error class for all exceptions to do with FASTA. class FastaError < StandardError; end diff --git a/code_ruby/Maasha/lib/fastq.rb b/code_ruby/lib/maasha/fastq.rb similarity index 97% rename from code_ruby/Maasha/lib/fastq.rb rename to code_ruby/lib/maasha/fastq.rb index a1eb86c..b3ba85f 100644 --- a/code_ruby/Maasha/lib/fastq.rb +++ b/code_ruby/lib/maasha/fastq.rb @@ -22,8 +22,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'seq' -require 'filesys' +require 'maasha/seq' +require 'maasha/filesys' # Error class for all exceptions to do with FASTQ. class FastqError < StandardError; end diff --git a/code_ruby/Maasha/lib/filesys.rb b/code_ruby/lib/maasha/filesys.rb similarity index 100% rename from code_ruby/Maasha/lib/filesys.rb rename to code_ruby/lib/maasha/filesys.rb diff --git a/code_ruby/Maasha/lib/genbank.rb b/code_ruby/lib/maasha/genbank.rb similarity index 99% rename from code_ruby/Maasha/lib/genbank.rb rename to code_ruby/lib/maasha/genbank.rb index bb40d3d..a6ec292 100644 --- a/code_ruby/Maasha/lib/genbank.rb +++ b/code_ruby/lib/maasha/genbank.rb @@ -22,8 +22,8 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'seq' -require 'filesys' +require 'maasha/seq' +require 'maasha/filesys' # Error class for all exceptions to do with Genbank. class GenbankError < StandardError; end diff --git a/code_ruby/Maasha/lib/patscan.rb b/code_ruby/lib/maasha/patscan.rb similarity index 99% rename from code_ruby/Maasha/lib/patscan.rb rename to code_ruby/lib/maasha/patscan.rb index e0ae706..4e31398 100644 --- a/code_ruby/Maasha/lib/patscan.rb +++ b/code_ruby/lib/maasha/patscan.rb @@ -22,7 +22,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'filesys' +require 'maasha/filesys' require 'open3' # Module containing code to locate nucleotide patterns in sequences allowing for diff --git a/code_ruby/Maasha/lib/patternmatcher.rb b/code_ruby/lib/maasha/patternmatcher.rb similarity index 100% rename from code_ruby/Maasha/lib/patternmatcher.rb rename to code_ruby/lib/maasha/patternmatcher.rb diff --git a/code_ruby/Maasha/lib/prodigal.rb b/code_ruby/lib/maasha/prodigal.rb similarity index 99% rename from code_ruby/Maasha/lib/prodigal.rb rename to code_ruby/lib/maasha/prodigal.rb index 9ddbf79..35b4992 100644 --- a/code_ruby/Maasha/lib/prodigal.rb +++ b/code_ruby/lib/maasha/prodigal.rb @@ -22,7 +22,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'genbank' +require 'maasha/genbank' # Class for running the Prodigal gene finder. # http://prodigal.ornl.gov/ diff --git a/code_ruby/Maasha/lib/seq.rb b/code_ruby/lib/maasha/seq.rb similarity index 99% rename from code_ruby/Maasha/lib/seq.rb rename to code_ruby/lib/maasha/seq.rb index 1227ac4..21e6e07 100644 --- a/code_ruby/Maasha/lib/seq.rb +++ b/code_ruby/lib/maasha/seq.rb @@ -22,9 +22,9 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'digest' -#require 'patscan' -require 'patternmatcher' +require 'maasha/digest' +require 'maasha/patternmatcher' +#require 'maasha/patscan' # Residue alphabets DNA = %w[a t c g] diff --git a/code_ruby/Maasha/lib/sff.rb b/code_ruby/lib/maasha/sff.rb similarity index 99% rename from code_ruby/Maasha/lib/sff.rb rename to code_ruby/lib/maasha/sff.rb index a3497f0..0a9d2a1 100644 --- a/code_ruby/Maasha/lib/sff.rb +++ b/code_ruby/lib/maasha/sff.rb @@ -22,7 +22,7 @@ # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'base36' +require 'maasha/base36' # Error class for all exceptions to do with SFF. class SFFError < StandardError; end diff --git a/code_ruby/Maasha/test/test_base36.rb b/code_ruby/test/maasha/test_base36.rb similarity index 98% rename from code_ruby/Maasha/test/test_base36.rb rename to code_ruby/test/maasha/test_base36.rb index c966900..683d267 100755 --- a/code_ruby/Maasha/test/test_base36.rb +++ b/code_ruby/test/maasha/test_base36.rb @@ -26,7 +26,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< require 'test/unit' -require 'base36' +require 'maasha/base36' require 'pp' class Base36Test < Test::Unit::TestCase diff --git a/code_ruby/Maasha/test/test_biopieces.rb b/code_ruby/test/maasha/test_biopieces.rb similarity index 99% rename from code_ruby/Maasha/test/test_biopieces.rb rename to code_ruby/test/maasha/test_biopieces.rb index be702b5..49d10a5 100755 --- a/code_ruby/Maasha/test/test_biopieces.rb +++ b/code_ruby/test/maasha/test_biopieces.rb @@ -26,7 +26,8 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< require 'test/unit' -require 'biopieces' +require 'maasha/biopieces' +require 'stringio' require 'pp' TYPES = %w[flag string list int uint float file file! files files! dir dir! genome] diff --git a/code_ruby/Maasha/test/test_bitarray.rb b/code_ruby/test/maasha/test_bitarray.rb similarity index 99% rename from code_ruby/Maasha/test/test_bitarray.rb rename to code_ruby/test/maasha/test_bitarray.rb index 5a3a88a..4745401 100755 --- a/code_ruby/Maasha/test/test_bitarray.rb +++ b/code_ruby/test/maasha/test_bitarray.rb @@ -26,7 +26,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'bitarray' +require 'maasha/bitarray' require 'test/unit' require 'pp' diff --git a/code_ruby/Maasha/test/test_bits.rb b/code_ruby/test/maasha/test_bits.rb similarity index 99% rename from code_ruby/Maasha/test/test_bits.rb rename to code_ruby/test/maasha/test_bits.rb index f817dc2..5a589f5 100755 --- a/code_ruby/Maasha/test/test_bits.rb +++ b/code_ruby/test/maasha/test_bits.rb @@ -26,7 +26,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'bits' +require 'maasha/bits' require 'test/unit' require 'pp' diff --git a/code_ruby/test/maasha/test_boulder.rb b/code_ruby/test/maasha/test_boulder.rb new file mode 100755 index 0000000..a0afe99 --- /dev/null +++ b/code_ruby/test/maasha/test_boulder.rb @@ -0,0 +1,75 @@ +#!/usr/bin/env ruby +$:.unshift File.join(File.dirname(__FILE__),'..','lib') + +# Copyright (C) 2007-2010 Martin A. Hansen. + +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# http://www.gnu.org/copyleft/gpl.html + +# >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< + +# This software is part of the Biopieces framework (www.biopieces.org). + +# >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< + +require 'maasha/boulder' +require 'test/unit' +require 'stringio' +require 'pp' + +class TestBoulder < Test::Unit::TestCase + def test_Boulder_each_raises_on_missing_seperator + boulder = Boulder.new(StringIO.new("TEST_BAD=testbad\n")) + assert_raise(BoulderError) { boulder.each } + end + + def test_Boulder_each_raises_on_missing_key_val_seperator + boulder = Boulder.new(StringIO.new("TEST_BAD\n=\n")) + assert_raise(BoulderError) { boulder.each } + end + + def test_Boulder_each_raises_on_missing_value + boulder = Boulder.new(StringIO.new("TEST_BAD=\n=\n")) + assert_raise(BoulderError) { boulder.each } + end + + def test_Boulder_each_raises_on_missing_key + boulder = Boulder.new(StringIO.new("=testbad\n=\n")) + assert_raise(BoulderError) { boulder.each } + end + + def test_Boulder_each_with_one_key_val_pair_returns_correctly + boulder = Boulder.new(StringIO.new("TEST0=thisistest0\n=\n")) + + boulder.each do |record| + assert_equal({:TEST0=>'thisistest0'},record) + end + end + + def test_Boulder_each_with_two_key_val_pairs_return_correctly + boulder = Boulder.new(StringIO.new("TEST0=thisistest0\nTEST1=thisistest1\n=\n")) + + boulder.each do |record| + assert_equal({:TEST0=>'thisistest0', :TEST1=>'thisistest1'},record) + end + end + + def test_Boulder_to_boulder_returns_correctly + boulder = Boulder.new() + + assert_equal("TEST0=thisistest0\n=\n", boulder.to_boulder({:TEST0=>'thisistest0'})) + end +end diff --git a/code_ruby/Maasha/test/test_digest.rb b/code_ruby/test/maasha/test_digest.rb similarity index 96% rename from code_ruby/Maasha/test/test_digest.rb rename to code_ruby/test/maasha/test_digest.rb index 9db221a..1e09f96 100755 --- a/code_ruby/Maasha/test/test_digest.rb +++ b/code_ruby/test/maasha/test_digest.rb @@ -1,6 +1,6 @@ #!/usr/bin/env ruby -require 'seq' +require 'maasha/seq' require 'test/unit' require 'pp' diff --git a/code_ruby/Maasha/test/test_fasta.rb b/code_ruby/test/maasha/test_fasta.rb similarity index 99% rename from code_ruby/Maasha/test/test_fasta.rb rename to code_ruby/test/maasha/test_fasta.rb index 23672af..d5ba7bd 100755 --- a/code_ruby/Maasha/test/test_fasta.rb +++ b/code_ruby/test/maasha/test_fasta.rb @@ -26,7 +26,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< require 'test/unit' -require 'fasta' +require 'maasha/fasta' require 'stringio' require 'pp' diff --git a/code_ruby/Maasha/test/test_fastq.rb b/code_ruby/test/maasha/test_fastq.rb similarity index 98% rename from code_ruby/Maasha/test/test_fastq.rb rename to code_ruby/test/maasha/test_fastq.rb index c06a07e..2316fc7 100755 --- a/code_ruby/Maasha/test/test_fastq.rb +++ b/code_ruby/test/maasha/test_fastq.rb @@ -26,7 +26,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< require 'test/unit' -require 'fastq' +require 'maasha/fastq' require 'stringio' require 'pp' diff --git a/code_ruby/Maasha/test/test_genbank.rb b/code_ruby/test/maasha/test_genbank.rb similarity index 97% rename from code_ruby/Maasha/test/test_genbank.rb rename to code_ruby/test/maasha/test_genbank.rb index 3c46386..8f36440 100755 --- a/code_ruby/Maasha/test/test_genbank.rb +++ b/code_ruby/test/maasha/test_genbank.rb @@ -26,8 +26,8 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'genbank' -require 'seq' +require 'maasha/genbank' +require 'maasha/seq' require 'test/unit' require 'pp' diff --git a/code_ruby/Maasha/test/test_patternmatcher.rb b/code_ruby/test/maasha/test_patternmatcher.rb similarity index 99% rename from code_ruby/Maasha/test/test_patternmatcher.rb rename to code_ruby/test/maasha/test_patternmatcher.rb index 7993862..9a7a50e 100755 --- a/code_ruby/Maasha/test/test_patternmatcher.rb +++ b/code_ruby/test/maasha/test_patternmatcher.rb @@ -25,7 +25,7 @@ $:.unshift File.join(File.dirname(__FILE__),'..','lib') # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -require 'seq' +require 'maasha/seq' require 'test/unit' require 'pp' diff --git a/code_ruby/Maasha/test/test_seq.rb b/code_ruby/test/maasha/test_seq.rb similarity index 99% rename from code_ruby/Maasha/test/test_seq.rb rename to code_ruby/test/maasha/test_seq.rb index e463e6f..5e79a0f 100755 --- a/code_ruby/Maasha/test/test_seq.rb +++ b/code_ruby/test/maasha/test_seq.rb @@ -1,6 +1,6 @@ #!/usr/bin/env ruby -require 'seq' +require 'maasha/seq' require 'test/unit' require 'pp' -- 2.39.5