[BioRuby-cvs] bioruby/lib/bio/util/restriction_enzyme analysis.rb, 1.5, 1.6 cut_symbol.rb, 1.1, 1.2 double_stranded.rb, 1.1, 1.2 integer.rb, 1.1, 1.2 single_strand.rb, 1.1, 1.2 single_strand_complement.rb, 1.1, 1.2 string_formatting.rb, 1.1, 1.2

Trevor Wennblom trevor at dev.open-bio.org
Sun Dec 31 21:50:33 UTC 2006


Update of /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme
In directory dev.open-bio.org:/tmp/cvs-serv32395/restriction_enzyme

Modified Files:
	analysis.rb cut_symbol.rb double_stranded.rb integer.rb 
	single_strand.rb single_strand_complement.rb 
	string_formatting.rb 
Log Message:
Updated license for RestrictionEnzyme.

Index: integer.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/integer.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** integer.rb	1 Feb 2006 07:34:11 -0000	1.1
--- integer.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,35 ****
  #
! # bio/util/restrction_enzyme/integer.rb - 
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
  #
  #  $Id$
  #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
! #
! #++
! #
! #
! 
! =begin rdoc
! bio/util/restrction_enzyme/integer.rb - 
! =end
! class Integer
    def negative?
      self < 0
--- 1,12 ----
  #
! # bio/util/restrction_enzyme/integer.rb - Adds method to check for negative values
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
  #  $Id$
  #
! class Integer #:nodoc:
    def negative?
      self < 0

Index: string_formatting.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/string_formatting.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** string_formatting.rb	1 Feb 2006 07:34:11 -0000	1.1
--- string_formatting.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,2 ****
--- 1,11 ----
+ #
+ # bio/util/restriction_enzyme/string_formatting.rb - Useful functions for string manipulation
+ #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
+ #
+ #  $Id$
+ #
  require 'pathname'
  libpath = Pathname.new(File.join(File.dirname(__FILE__), ['..'] * 4, 'lib')).cleanpath.to_s
***************
*** 11,41 ****
  # bio/util/restriction_enzyme/string_formatting.rb - Useful functions for string manipulation
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
! #
! #  $Id$
! #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
! #
! #++
  #
- =begin rdoc
- bio/util/restriction_enzyme/string_formatting.rb - Useful functions for string manipulation
- =end
  module StringFormatting
    include CutSymbol
--- 20,27 ----
  # bio/util/restriction_enzyme/string_formatting.rb - Useful functions for string manipulation
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
  module StringFormatting
    include CutSymbol
***************
*** 103,109 ****
      ret ? ret : ''  # Don't pass nil values
    end
! 
! 
! end
! 
! end
--- 89,92 ----
      ret ? ret : ''  # Don't pass nil values
    end
! end # StringFormatting
! end # Bio::RestrictionEnzyme

Index: cut_symbol.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/cut_symbol.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** cut_symbol.rb	1 Feb 2006 07:34:11 -0000	1.1
--- cut_symbol.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,37 ****
- module Bio; end
- class Bio::RestrictionEnzyme
- 
  #
  # bio/util/restrction_enzyme/cut_symbol.rb - 
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
  #
  #  $Id$
  #
  #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
! #
! #++
  #
  #
- 
- =begin rdoc
- bio/util/restrction_enzyme/cut_symbol.rb - 
- =end
  module CutSymbol
  
--- 1,24 ----
  #
  # bio/util/restrction_enzyme/cut_symbol.rb - 
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
  #  $Id$
  #
+ 
+ nil # separate file-level rdoc from following statement
+ 
+ module Bio; end
+ class Bio::RestrictionEnzyme
+ 
  #
! # bio/util/restrction_enzyme/cut_symbol.rb - 
  #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
  #
  module CutSymbol
  
***************
*** 67,70 ****
    end
  
! end
! end
--- 54,57 ----
    end
  
! end # CutSymbol
! end # Bio::RestrictionEnzyme
\ No newline at end of file

Index: single_strand_complement.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/single_strand_complement.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** single_strand_complement.rb	1 Feb 2006 07:34:11 -0000	1.1
--- single_strand_complement.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,2 ****
--- 1,11 ----
+ #
+ # bio/util/restriction_enzyme/single_strand_complement.rb - Single strand restriction enzyme sequence in complement orientation
+ #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
+ #
+ #  $Id$
+ #
  require 'pathname'
  libpath = Pathname.new(File.join(File.dirname(__FILE__), ['..'] * 4, 'lib')).cleanpath.to_s
***************
*** 11,47 ****
  # bio/util/restriction_enzyme/single_strand_complement.rb - Single strand restriction enzyme sequence in complement orientation
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
! #
! #  $Id$
! #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
  #
! #++
  #
- =begin rdoc
- bio/util/restriction_enzyme/single_strand_complement.rb - Single strand restriction enzyme sequence in complement orientation
- 
- A single strand of restriction enzyme sequence pattern with a 3' to 5' orientation.
- =end
  class SingleStrandComplement < SingleStrand
    # Orientation of the strand, 3' to 5'
    def orientation; [3, 5]; end
! end
! 
! end
--- 20,32 ----
  # bio/util/restriction_enzyme/single_strand_complement.rb - Single strand restriction enzyme sequence in complement orientation
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
! # A single strand of restriction enzyme sequence pattern with a 3' to 5' orientation.
  #
  class SingleStrandComplement < SingleStrand
    # Orientation of the strand, 3' to 5'
    def orientation; [3, 5]; end
! end # SingleStrandComplement
! end # Bio::RestrictionEnzyme

Index: double_stranded.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/double_stranded.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** double_stranded.rb	1 Feb 2006 07:34:11 -0000	1.1
--- double_stranded.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,2 ****
--- 1,11 ----
+ #
+ # bio/util/restrction_enzyme/double_stranded.rb - DoubleStranded restriction enzyme sequence
+ #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
+ #
+ #  $Id$
+ #
  require 'pathname'
  libpath = Pathname.new(File.join(File.dirname(__FILE__), ['..'] * 4, 'lib')).cleanpath.to_s
***************
*** 16,58 ****
  
  #
! # bio/util/restriction_enzyme/double_stranded.rb - DoubleStranded restriction enzyme sequence
! #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
! #
! #  $Id$
! #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
  #
! #++
  #
! 
! =begin rdoc
! bio/util/restriction_enzyme/double_stranded.rb - DoubleStranded restriction enzyme sequence
! 
! A pair of +SingleStrand+ and +SingleStrandComplement+ objects with methods to
! add utility to their relation.
! 
! == Notes
!  * This is created by Bio::RestrictionEnzyme.new for convenience.
!  * The two strands accessible are +primary+ and +complement+.
!  * SingleStrand methods may be used on DoubleStranded and they will be passed to +primary+.
! 
! =end
  class DoubleStranded
    include CutSymbol
--- 25,42 ----
  
  #
! # bio/util/restrction_enzyme/double_stranded.rb - DoubleStranded restriction enzyme sequence
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
! # A pair of +SingleStrand+ and +SingleStrandComplement+ objects with methods to
! # add utility to their relation.
! # 
! # = Notes
! #  * This is created by Bio::RestrictionEnzyme.new for convenience.
! #  * The two strands accessible are +primary+ and +complement+.
! #  * SingleStrand methods may be used on DoubleStranded and they will be passed to +primary+.
! # 
  class DoubleStranded
    include CutSymbol
***************
*** 73,78 ****
    attr_reader :cut_locations_in_enzyme_notation
  
!   # +erp+:: Enzyme or Rebase or Pattern.  One of three:  The name of an enzyme.  A REBASE::EnzymeEntry object.  A nucleotide pattern.
!   # +raw_cut_pairs+:: The cut locations in enzyme index notation.
    #
    # Enzyme index notation:: 1.._n_, value before 1 is -1
--- 57,62 ----
    attr_reader :cut_locations_in_enzyme_notation
  
!   # [+erp+] One of three possible parameters:  The name of an enzyme, a REBASE::EnzymeEntry object, or a nucleotide pattern with a cut mark.
!   # [+raw_cut_pairs+] The cut locations in enzyme index notation.
    #
    # Enzyme index notation:: 1.._n_, value before 1 is -1
***************
*** 94,97 ****
--- 78,82 ----
    #
    def initialize(erp, *raw_cut_pairs)
+     # 'erp' : 'E'nzyme / 'R'ebase / 'P'attern
      k = erp.class
  
***************
*** 217,221 ****
    end
  
! end
! 
! end
--- 202,205 ----
    end
  
! end # DoubleStranded
! end # Bio::RestrictionEnzyme

Index: single_strand.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/single_strand.rb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** single_strand.rb	1 Feb 2006 07:34:11 -0000	1.1
--- single_strand.rb	31 Dec 2006 21:50:31 -0000	1.2
***************
*** 1,2 ****
--- 1,11 ----
+ #
+ # bio/util/restriction_enzyme/single_strand.rb - Single strand of a restriction enzyme sequence
+ #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
+ #
+ #  $Id$
+ #
  require 'pathname'
  libpath = Pathname.new(File.join(File.dirname(__FILE__), ['..'] * 4, 'lib')).cleanpath.to_s
***************
*** 13,50 ****
  # bio/util/restriction_enzyme/single_strand.rb - Single strand of a restriction enzyme sequence
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
! #
! #  $Id$
! #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
  #
! #++
  #
- 
- =begin rdoc
- bio/util/restriction_enzyme/single_strand.rb - Single strand of a restriction enzyme sequence
- 
- A single strand of restriction enzyme sequence pattern with a 5' to 3' 
- orientation.
-  
- DoubleStranded puts the SingleStrand and SingleStrandComplement together to 
- create the sequence pattern with cuts on both strands.
- =end
  class SingleStrand < Bio::Sequence::NA
    include CutSymbol
--- 22,35 ----
  # bio/util/restriction_enzyme/single_strand.rb - Single strand of a restriction enzyme sequence
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
! # A single strand of restriction enzyme sequence pattern with a 5' to 3' 
! # orientation.
! #  
! # DoubleStranded puts the SingleStrand and SingleStrandComplement together to 
! # create the sequence pattern with cuts on both strands.
  #
  class SingleStrand < Bio::Sequence::NA
    include CutSymbol
***************
*** 142,146 ****
    end
  
! 
    # NOTE: BEING WORKED ON, BUG EXISTS IN Bio::NucleicAcid
  =begin  
--- 127,131 ----
    end
  
! # FIXME recheck this
    # NOTE: BEING WORKED ON, BUG EXISTS IN Bio::NucleicAcid
  =begin  
***************
*** 198,202 ****
    once :pattern, :with_cut_symbols, :with_spaces, :to_re
  
! end
! 
! end
--- 183,186 ----
    once :pattern, :with_cut_symbols, :with_spaces, :to_re
  
! end # SingleStrand
! end # Bio::RestrictionEnzyme
\ No newline at end of file

Index: analysis.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/util/restriction_enzyme/analysis.rb,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** analysis.rb	1 Mar 2006 01:40:00 -0000	1.5
--- analysis.rb	31 Dec 2006 21:50:31 -0000	1.6
***************
*** 1,2 ****
--- 1,13 ----
+ #
+ # bio/util/restrction_enzyme/analysis.rb - Does the work of fragmenting the DNA from the enzymes
+ #
+ # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
+ # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
+ # License::   Distributes under the same terms as Ruby
+ #
+ #  $Id$
+ #
+ 
+ #--
  #if RUBY_VERSION[0..2] == '1.9' or RUBY_VERSION == '2.0'
  #  err = "This class makes use of 'include' on ranges quite a bit.  Possibly unstable in development Ruby.  2005/12/20."
***************
*** 4,7 ****
--- 15,19 ----
  #  raise err
  #end
+ #++
  
  require 'pathname'
***************
*** 10,15 ****
  
  require 'bio'
- 
  class Bio::Sequence::NA
    def cut_with_enzyme(*args)
      Bio::RestrictionEnzyme::Analysis.cut(self, *args)
--- 22,27 ----
  
  require 'bio'
  class Bio::Sequence::NA
+   # See Bio::RestrictionEnzyme::Analysis.cut
    def cut_with_enzyme(*args)
      Bio::RestrictionEnzyme::Analysis.cut(self, *args)
***************
*** 24,59 ****
  
  class Bio::RestrictionEnzyme
  #
  # bio/util/restrction_enzyme/analysis.rb - Does the work of fragmenting the DNA from the enzymes
  #
! # Copyright::  Copyright (C) 2006 Trevor Wennblom <trevor at corevx.com>
! # License::    LGPL
! #
! #  $Id$
! #
! #
! #--
! #
! #  This library is free software; you can redistribute it and/or
! #  modify it under the terms of the GNU Lesser General Public
! #  License as published by the Free Software Foundation; either
! #  version 2 of the License, or (at your option) any later version.
! #
! #  This library 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
! #  Lesser General Public License for more details.
! #
! #  You should have received a copy of the GNU Lesser General Public
! #  License along with this library; if not, write to the Free Software
! #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA
! #
! #++
! #
  #
- 
- =begin rdoc
- bio/util/restrction_enzyme/analysis.rb - Does the work of fragmenting the DNA from the enzymes
- =end
  class Analysis
  
--- 36,47 ----
  
  class Bio::RestrictionEnzyme
+ 
  #
  # bio/util/restrction_enzyme/analysis.rb - Does the work of fragmenting the DNA from the enzymes
  #
! # Author::    Trevor Wennblom  <mailto:trevor at corevx.com>
! # Copyright:: Copyright (c) 2005-2007 Midwinter Laboratories, LLC (http://midwinterlabs.com)
! # License::   Distributes under the same terms as Ruby
  #
  class Analysis
  
***************
*** 375,378 ****
    end
  
! end
! end
--- 363,366 ----
    end
  
! end # Analysis
! end # Bio::RestrictionEnzyme




More information about the bioruby-cvs mailing list