Object
# File lib/ap/awesome_print.rb, line 14 def initialize(options = {}) @options = { :multiline => true, # Display in multiple lines. :plain => false, # Use colors. :indent => 4, # Indent using 4 spaces. :index => true, # Display array indices. :html => false, # Use ANSI color codes rather than HTML. :sorted_hash_keys => false, # Do not sort hash keys. :color => { :array => :white, :bigdecimal => :blue, :class => :yellow, :date => :greenish, :falseclass => :red, :fixnum => :blue, :float => :blue, :hash => :pale, :struct => :pale, :nilclass => :red, :string => :yellowish, :symbol => :cyanish, :time => :greenish, :trueclass => :green, :method => :purpleish, :args => :pale } } # Merge custom defaults and let explicit options parameter override them. merge_custom_defaults! merge_options!(options) @indentation = @options[:indent].abs Thread.current[AP] ||= [] end
Generated with the Darkfish Rdoc Generator 2.