Class: Dotloop::Profile

Inherits:
Object
  • Object
show all
Defined in:
lib/dotloop/profile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Profile

Returns a new instance of Profile.



5
6
7
# File 'lib/dotloop/profile.rb', line 5

def initialize(client:)
  @client = client
end

Instance Attribute Details

#clientObject

Returns the value of attribute client.



3
4
5
# File 'lib/dotloop/profile.rb', line 3

def client
  @client
end

Instance Method Details

#allObject



9
10
11
12
13
14
15
# File 'lib/dotloop/profile.rb', line 9

def all
  @client.get('/profile').map do |profile_attrs|
    profile = Dotloop::Models::Profile.new(profile_attrs)
    profile.client = client
    profile
  end
end