Class: ActivityStreams::Verb
Instance Method Summary collapse
- #as_json(options = {}) ⇒ Object
-
#initialize(attributes = {}) ⇒ Verb
constructor
A new instance of Verb.
Methods inherited from Base
Methods included from Validator
#to_integer, #to_iri, #to_time, #validate_attribute!
Constructor Details
#initialize(attributes = {}) ⇒ Verb
Returns a new instance of Verb.
5 6 7 8 |
# File 'lib/activitystreams/verb.rb', line 5 def initialize(attributes = {}) attributes[:verb] ||= :post super end |
Instance Method Details
#as_json(options = {}) ⇒ Object
10 11 12 |
# File 'lib/activitystreams/verb.rb', line 10 def as_json( = {}) verb.to_s end |