Class: Torque::Project

Inherits:
Object
  • Object
show all
Defined in:
lib/torque/project/project.rb

Overview

Stores the name and id of a single Pivotal project

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, name, current = false) ⇒ Project

Returns a new instance of Project.

Parameters:

  • id

    The project’s ID

  • name

    The project’s name

  • current (defaults to: false)

    True if this is the current project, else false



23
24
25
26
27
# File 'lib/torque/project/project.rb', line 23

def initialize(id, name, current=false)
  @current = current
  @id = id
  @name = name
end

Instance Attribute Details

#currentObject

True if this is the current project, else false



9
10
11
# File 'lib/torque/project/project.rb', line 9

def current
  @current
end

#idObject (readonly)

The project ID



13
14
15
# File 'lib/torque/project/project.rb', line 13

def id
  @id
end

#nameObject (readonly)

The project name



17
18
19
# File 'lib/torque/project/project.rb', line 17

def name
  @name
end