Class: TaskWarrior::Dependencies::ProjectPresenter

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

Overview

Presents a project’s attributes suitable for a GraphViz cluster

Instance Method Summary collapse

Constructor Details

#initialize(project) ⇒ ProjectPresenter

Returns a new instance of ProjectPresenter.



7
8
9
# File 'lib/twdeps/project_presenter.rb', line 7

def initialize(project)
  @project = project
end

Instance Method Details

#attributesObject



11
12
13
# File 'lib/twdeps/project_presenter.rb', line 11

def attributes
  {:label => @project.name}
end

#idObject



15
16
17
# File 'lib/twdeps/project_presenter.rb', line 15

def id
  "cluster_#{@project.name}"
end