lib/allocation_stats/allocation.rb
# Convert into a JSON string, which can be used in rack-allocation_stats's
# interactive mode.
Convert into a JSON string, which can be used in rack-allocation_stats's
interactive mode.
Convert into a JSON string which can be used in rack - allocation_stats ' s interactive mode .
def as_json
      {
        "memsize"      => @memsize,
        "class_path"   => @class_path,
        "method_id"    => @method_id,
        "file"         => sourcefile_alias,
        "file (raw)"   => @sourcefile,
        "line"         => @sourceline,
        "class"        => @object.class.name,
        "class_plus"   => class_plus
      }
    end
def as_json { "memsize" => @memsize , "class_path" => @class_path , "method_id" => @method_id , "file" => sourcefile_alias , "file (raw)" => @sourcefile , "line" => @sourceline , "class" => @object . class . name , "class_plus" => class_plus } end
Convert into a JSON string, which can be used in rack-allocation_stats's
interactive mode.
Convert into a JSON string which can be used in rack - allocation_stats ' s interactive mode .