Class: Student

Inherits:
Object
  • Object
show all
Defined in:
lib/work_together/student.rb

Constant Summary collapse

@@all =
[]

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeStudent

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_trackObject

Returns the value of attribute active_track.



5
6
7
# File 'lib/work_together/student.rb', line 5

def active_track
  @active_track
end

#completionObject

Returns the value of attribute completion.



5
6
7
# File 'lib/work_together/student.rb', line 5

def completion
  @completion
end

#emailObject

Returns the value of attribute email.



5
6
7
# File 'lib/work_together/student.rb', line 5

def email
  @email
end

#first_nameObject

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_usernameObject

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_nameObject

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

.allObject



11
12
13
# File 'lib/work_together/student.rb', line 11

def self.all
  @@all 
end

Instance Method Details

#nameObject



15
16
17
# File 'lib/work_together/student.rb', line 15

def name
  "#{first_name} #{last_name}"
end

#progressObject



19
20
21
# File 'lib/work_together/student.rb', line 19

def progress
  self.completion
end