Class | Bio::RestrictionEnzyme::Range::CutRanges
In: | lib/bio/util/restriction_enzyme/range/cut_ranges.rb
Parent: | Array

Container for many CutRange objects or CutRange child objects. Inherits from array.

### Methods

include? max max_vertical min min_vertical vertical_min_max_helper

### Public Instance methods

include?(i)

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 22
    22:   def include?(i); self.collect{|a| a.include?(i)}.include?(true); end

max()

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 21
    21:   def max; self.collect{|a| a.max}.flatten.sort.last; end

max_vertical()

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 28
    28:   def max_vertical
    29:     vertical_min_max_helper( :max )
    30:   end

min()

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 20
    20:   def min; self.collect{|a| a.min}.flatten.sort.first; end

min_vertical()

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 24
    24:   def min_vertical
    25:     vertical_min_max_helper( :min )
    26:   end

### Protected Instance methods

vertical_min_max_helper( sym_which )

[Source]

        # File lib/bio/util/restriction_enzyme/range/cut_ranges.rb, line 34
    34:   def vertical_min_max_helper( sym_which )
    35:     tmp = []
    36:     self.each do |a|
    37:       next unless a.class == Bio::RestrictionEnzyme::Range::VerticalCutRange
    38:       tmp << a.send( sym_which )
    39:     end
    40:     z = (sym_which == :max) ? :last : :first
    41:     tmp.flatten.sort.send(z)
    42:   end

[Validate]