Method: WitBot::Context#to_hash
- Defined in:
- lib/wit_bot/models/context.rb
#to_hash ⇒ Object
18 19 20 21 22 23 24 25 |
# File 'lib/wit_bot/models/context.rb', line 18 def to_hash h = {} h[:state] = state if state && !state.empty? h[:reference_time] = reference_time.iso8601 if reference_time h[:entities] = entities if @entities h[:location] = location if location h end |