Class: IODDoc

Inherits:
Object
  • Object
show all
Defined in:
lib/iodruby.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ IODDoc

Returns a new instance of IODDoc.



352
353
354
355
356
# File 'lib/iodruby.rb', line 352

def initialize(data)
  #@query=query
  @entities=Hash.new
  @data=data
end

Instance Attribute Details

#dataObject

Returns the value of attribute data.



349
350
351
# File 'lib/iodruby.rb', line 349

def data
  @data
end

#entitiesObject

Returns the value of attribute entities.



351
352
353
# File 'lib/iodruby.rb', line 351

def entities
  @entities
end

#sentimentObject

Returns the value of attribute sentiment.



350
351
352
# File 'lib/iodruby.rb', line 350

def sentiment
  @sentiment
end

Instance Method Details

#to_json(options = {}) ⇒ Object



358
359
360
# File 'lib/iodruby.rb', line 358

def to_json(options={})
    return render :json => JSON::dump(@data)
end