Class: FjordBootCamp::Client

Inherits:
Object
  • Object
show all
Defined in:
lib/fjord_boot_camp/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(configuration = nil) ⇒ Client

Returns a new instance of Client.



10
11
12
# File 'lib/fjord_boot_camp/client.rb', line 10

def initialize(configuration = nil)
  @configuration = configuration || FjordBootCamp.configuration || Configuration.new
end

Instance Attribute Details

#configurationObject (readonly)

Returns the value of attribute configuration.



8
9
10
# File 'lib/fjord_boot_camp/client.rb', line 8

def configuration
  @configuration
end

Instance Method Details

#get(path, params = {}) ⇒ Object



30
31
32
33
# File 'lib/fjord_boot_camp/client.rb', line 30

def get(path, params = {})
  response = connection.get(path, params)
  handle_response(response)
end

#practicesObject



22
23
24
# File 'lib/fjord_boot_camp/client.rb', line 22

def practices
  Resources::Practices.new(self)
end

#reportsObject



14
15
16
# File 'lib/fjord_boot_camp/client.rb', line 14

def reports
  Resources::Reports.new(self)
end

#trainee_progressesObject



26
27
28
# File 'lib/fjord_boot_camp/client.rb', line 26

def trainee_progresses
  Resources::TraineeProgresses.new(self)
end

#usersObject



18
19
20
# File 'lib/fjord_boot_camp/client.rb', line 18

def users
  Resources::Users.new(self)
end