class Pry::Command::Ls::LsEntity
Attributes
_pry_[R]
Public Class Methods
new(opts)
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 17 def initialize(opts) @interrogatee = opts[:interrogatee] @no_user_opts = opts[:no_user_opts] @opts = opts[:opts] @args = opts[:args] @grep = Grep.new(Regexp.new(opts[:opts][:G] || '.')) @_pry_ = opts.delete(:_pry_) end
Public Instance Methods
entities_table()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 26 def entities_table entities.map(&:write_out).reject { |o| !o }.join('') end
Private Instance Methods
constants()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 40 def constants grep Constants.new(@interrogatee, @no_user_opts, @opts, _pry_) end
entities()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 64 def entities [globals, constants, methods, self_methods, instance_vars, local_names, local_vars] end
globals()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 36 def globals grep Globals.new(@opts, _pry_) end
grep(entity)
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 32 def grep(entity) entity.tap { |o| o.grep = @grep } end
instance_vars()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 52 def instance_vars grep InstanceVars.new(@interrogatee, @no_user_opts, @opts, _pry_) end
local_names()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 56 def local_names grep LocalNames.new(@no_user_opts, @args, _pry_) end
local_vars()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 60 def local_vars LocalVars.new(@opts, _pry_) end
methods()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 44 def methods grep(Methods.new(@interrogatee, @no_user_opts, @opts, _pry_)) end
self_methods()
click to toggle source
# File lib/pry/commands/ls/ls_entity.rb, line 48 def self_methods grep SelfMethods.new(@interrogatee, @no_user_opts, @opts, _pry_) end