Class: Ohmage::Annotation

Inherits:
Object
  • Object
show all
Defined in:
lib/ohmage/entity/annotation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attrs = {}) ⇒ Annotation

Returns a new instance of Annotation.



8
9
10
11
12
# File 'lib/ohmage/entity/annotation.rb', line 8

def initialize(attrs = {})
  attrs.keys[0].each do |k, v|
    instance_variable_set("@#{k}", v)
  end
end

Instance Attribute Details

#annotation_idString (readonly) Also known as: id, urn

Returns:

  • (String)


4
5
6
# File 'lib/ohmage/entity/annotation.rb', line 4

def annotation_id
  @annotation_id
end

#authorString (readonly)

Returns:

  • (String)


4
5
6
# File 'lib/ohmage/entity/annotation.rb', line 4

def author
  @author
end

#textString (readonly)

Returns:

  • (String)


4
5
6
# File 'lib/ohmage/entity/annotation.rb', line 4

def text
  @text
end

#timeString (readonly)

Returns:

  • (String)


4
5
6
# File 'lib/ohmage/entity/annotation.rb', line 4

def time
  @time
end

#timezoneString (readonly)

Returns:

  • (String)


4
5
6
# File 'lib/ohmage/entity/annotation.rb', line 4

def timezone
  @timezone
end