Class: CareerBuilder::Resume

Inherits:
BasicObject
Defined in:
lib/career_builder/resume.rb

Defined Under Namespace

Classes: LazyCollection

Instance Method Summary collapse

Constructor Details

#initialize(client, partial_resume) ⇒ Resume

Returns a new instance of Resume.



5
6
7
8
# File 'lib/career_builder/resume.rb', line 5

def initialize(client, partial_resume)
  @client = client
  @partial_resume = partial_resume
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(meth, *args, &block) ⇒ Object (private)



24
25
26
27
28
29
30
31
32
33
34
# File 'lib/career_builder/resume.rb', line 24

def method_missing(meth, *args, &block)
  if @partial_resume.respond_to?(meth)
    @partial_resume.send(meth, *args, &block)
  else
    if full_resume.respond_to?(meth)
      full_resume.send(meth, *args, &block)
    else
      super
    end
  end
end

Instance Method Details

#full_resumeObject



18
19
20
# File 'lib/career_builder/resume.rb', line 18

def full_resume
  @full_resume ||= fetch_full_resume
end

#home_locationObject



14
15
16
# File 'lib/career_builder/resume.rb', line 14

def home_location
  full_resume.home_location
end

#real_contact_emailObject



10
11
12
# File 'lib/career_builder/resume.rb', line 10

def real_contact_email
  full_resume.contact_email
end