Class: Spear::Structure::Job::Retrieve
- Defined in:
- lib/spear/structure/job/retrieve.rb
Instance Attribute Summary collapse
-
#job_categories ⇒ Object
Returns the value of attribute job_categories.
-
#job_description ⇒ Object
Returns the value of attribute job_description.
-
#job_did ⇒ Object
readonly
Returns the value of attribute job_did.
-
#job_requirements ⇒ Object
Returns the value of attribute job_requirements.
-
#job_title ⇒ Object
Returns the value of attribute job_title.
-
#required_experience ⇒ Object
Returns the value of attribute required_experience.
Attributes inherited from Base
#error_message, #response, #root, #status
Instance Method Summary collapse
-
#initialize(response) ⇒ Retrieve
constructor
A new instance of Retrieve.
Methods inherited from Base
Constructor Details
#initialize(response) ⇒ Retrieve
Returns a new instance of Retrieve.
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/spear/structure/job/retrieve.rb', line 8 def initialize(response) super(response) if response.class == HTTParty::Response @job_did = response.request.[:query][:DID] end unless @root["Job"].nil? @job_title = @root["Job"]["JobTitle"] @job_description = @root["Job"]["JobDescription"] @job_requirements = @root["Job"]["JobRequirements"] @experience_required = @root["Job"]["ExperienceRequired"] @job_categories = @root["Job"]["Categories"] end end |
Instance Attribute Details
#job_categories ⇒ Object
Returns the value of attribute job_categories.
6 7 8 |
# File 'lib/spear/structure/job/retrieve.rb', line 6 def job_categories @job_categories end |
#job_description ⇒ Object
Returns the value of attribute job_description.
6 7 8 |
# File 'lib/spear/structure/job/retrieve.rb', line 6 def job_description @job_description end |
#job_did ⇒ Object (readonly)
Returns the value of attribute job_did.
5 6 7 |
# File 'lib/spear/structure/job/retrieve.rb', line 5 def job_did @job_did end |
#job_requirements ⇒ Object
Returns the value of attribute job_requirements.
6 7 8 |
# File 'lib/spear/structure/job/retrieve.rb', line 6 def job_requirements @job_requirements end |
#job_title ⇒ Object
Returns the value of attribute job_title.
6 7 8 |
# File 'lib/spear/structure/job/retrieve.rb', line 6 def job_title @job_title end |
#required_experience ⇒ Object
Returns the value of attribute required_experience.
6 7 8 |
# File 'lib/spear/structure/job/retrieve.rb', line 6 def required_experience @required_experience end |