Class: Student
- Inherits:
-
Object
- Object
- Student
- Defined in:
- lib/work_together/student.rb
Constant Summary collapse
- @@all =
[]
Instance Attribute Summary collapse
-
#active_track ⇒ Object
Returns the value of attribute active_track.
-
#completion ⇒ Object
Returns the value of attribute completion.
-
#email ⇒ Object
Returns the value of attribute email.
-
#first_name ⇒ Object
Returns the value of attribute first_name.
-
#github_username ⇒ Object
Returns the value of attribute github_username.
-
#last_name ⇒ Object
Returns the value of attribute last_name.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ Student
constructor
A new instance of Student.
- #name ⇒ Object
- #progress ⇒ Object
Constructor Details
#initialize ⇒ Student
Returns a new instance of Student.
7 8 9 |
# File 'lib/work_together/student.rb', line 7 def initialize @@all << self end |
Instance Attribute Details
#active_track ⇒ Object
Returns the value of attribute active_track.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def active_track @active_track end |
#completion ⇒ Object
Returns the value of attribute completion.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def completion @completion end |
#email ⇒ Object
Returns the value of attribute email.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def email @email end |
#first_name ⇒ Object
Returns the value of attribute first_name.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def first_name @first_name end |
#github_username ⇒ Object
Returns the value of attribute github_username.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def github_username @github_username end |
#last_name ⇒ Object
Returns the value of attribute last_name.
5 6 7 |
# File 'lib/work_together/student.rb', line 5 def last_name @last_name end |
Class Method Details
.all ⇒ Object
11 12 13 |
# File 'lib/work_together/student.rb', line 11 def self.all @@all end |
Instance Method Details
#name ⇒ Object
15 16 17 |
# File 'lib/work_together/student.rb', line 15 def name "#{first_name} #{last_name}" end |
#progress ⇒ Object
19 20 21 |
# File 'lib/work_together/student.rb', line 19 def progress self.completion end |