Sha256: 8cd86ee56fa8119fe9addeb1c96f49935f9b12c8dd199626ed7b71b67adff520

Contents?: true

Size: 313 Bytes

Versions: 6

Compression:

Stored size: 313 Bytes

Contents

class Object
  # Constructs the string "#{self.class}:#{self}". Useful for inspection.
  # 
  def y_inspect( option=nil )
    case option
    when :full then "#<#{y_inspect}>"
    when :short then
      "#{self.class.name.to_s.split( "::" ).last}:#{self}"
    else
      "#{self.class}:#{self}"
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
y_support-2.5.3 lib/y_support/core_ext/object/inspection.rb
y_support-2.5.2 lib/y_support/core_ext/object/inspection.rb
y_support-2.5.1 lib/y_support/core_ext/object/inspection.rb
y_support-2.4.6 lib/y_support/core_ext/object/inspection.rb
y_support-2.4.5 lib/y_support/core_ext/object/inspection.rb
y_support-2.4.4 lib/y_support/core_ext/object/inspection.rb