Sha256: e5a1ae510c221c046ab1a64acde291957f726948a1b9455802e6dd5b64aa2881

Contents?: true

Size: 300 Bytes

Versions: 56

Compression:

Stored size: 300 Bytes

Contents

class Object  
  def get_methods *types
    types.inject([]) do |list, type|
      list << case type
      when :all
        get_methods(:private, :protected, :public)
      when :private, :protected, :public
        send :"#{type}_methods"
      end
      list.flatten
    end.flatten.uniq
  end
end

Version data entries

56 entries across 56 versions & 1 rubygems

Version Path
sugar-high-0.6.3 lib/sugar-high/methods.rb
sugar-high-0.6.2.1 lib/sugar-high/methods.rb
sugar-high-0.6.1 lib/sugar-high/methods.rb
sugar-high-0.6.0 lib/sugar-high/methods.rb
sugar-high-0.5.5 lib/sugar-high/methods.rb
sugar-high-0.5.4 lib/sugar-high/methods.rb
sugar-high-0.5.3 lib/sugar-high/methods.rb
sugar-high-0.5.1 lib/sugar-high/methods.rb
sugar-high-0.5.0 lib/sugar-high/methods.rb
sugar-high-0.4.9.5 lib/sugar-high/methods.rb
sugar-high-0.4.9.3 lib/sugar-high/methods.rb
sugar-high-0.4.9.2 lib/sugar-high/methods.rb
sugar-high-0.4.9.1 lib/sugar-high/methods.rb
sugar-high-0.4.9 lib/sugar-high/methods.rb
sugar-high-0.4.8 lib/sugar-high/methods.rb
sugar-high-0.4.7 lib/sugar-high/methods.rb
sugar-high-0.4.6.4 lib/sugar-high/methods.rb
sugar-high-0.4.6.3 lib/sugar-high/methods.rb
sugar-high-0.4.6.2 lib/sugar-high/methods.rb
sugar-high-0.4.6.1 lib/sugar-high/methods.rb