class Array

Public Instance Methods

inspect_original()

alias_method :inspect_original, :inspect

Alias for: to_s
to_s() click to toggle source

def inspect

# File lib/pry-parsecom/model_formatter.rb, line 17
  def to_s
    if self.empty? || self.all? {|e| e === Parse::Object}
puts self.first.class.name
      heads = self.first.to_h.keys
      table = PryParsecom::Table.new heads
      self.each do |e|
        table.add_row heads.map{|h| e[h]}
      end
      table.to_s
    else
puts :inspect_original
      inspect_original
    end
  end
Also aliased as: inspect_original