Class: Ppson::JsonArgument
- Inherits:
-
Object
- Object
- Ppson::JsonArgument
- Defined in:
- lib/ppjson/json_argument.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(data, options) ⇒ JsonArgument
constructor
A new instance of JsonArgument.
- #process ⇒ Object
Constructor Details
#initialize(data, options) ⇒ JsonArgument
Returns a new instance of JsonArgument.
5 6 7 8 |
# File 'lib/ppjson/json_argument.rb', line 5 def initialize(data, ) @data = data @options = end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
3 4 5 |
# File 'lib/ppjson/json_argument.rb', line 3 def data @data end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
3 4 5 |
# File 'lib/ppjson/json_argument.rb', line 3 def @options end |
Instance Method Details
#process ⇒ Object
10 11 12 |
# File 'lib/ppjson/json_argument.rb', line 10 def process Ppjson::StreamJsonWriter.new.write(data, :pretty => true) end |