Class: TaskWarrior::AnnotationMapper
- Inherits:
-
Object
- Object
- TaskWarrior::AnnotationMapper
- Defined in:
- lib/taskwarrior/annotation_mapper.rb
Overview
A DataMapper that makes new annotations from a JSON representation
Class Method Summary collapse
Class Method Details
.map(json) ⇒ Object
7 8 9 10 11 |
# File 'lib/taskwarrior/annotation_mapper.rb', line 7 def map(json) Annotation.new(json['description']).tap{|t| t.entry = DateTime.parse(json['entry']) } end |