Last active
February 5, 2017 10:42
-
-
Save jonodrew/5fe1d87ad0a73831239a8cc55ba3bdac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CommonData: | |
"""CommonData is the super class for data that both Applicant and Role contain | |
For example, we require both to give information about skills and location. | |
However there are specifics that we will need from both. They are given in the | |
classes for each.""" | |
def __init__(self, department, anchor, skill1,skill2,location,competency1, | |
competency2,competency3,security,year): | |
self.department = department | |
self.anchor = anchor | |
self.skill1 = skill1 | |
self.skill2 = skill2 | |
self.location = location | |
self.competency1 = competency1 | |
self.competency2 = competency2 | |
self.competency3 = competency3 | |
self.security = security | |
self.year = year | |
class Role(CommonData,object): | |
"""The extra attributes roles have go here.""" | |
def __init__(self, attributes): | |
super(Role, self).__init__(*attributes) | |
class Applicant(CommonData,object): | |
"""The extra attrbutes Applicants have go here.""" | |
def __init__(self,location_restriction, attributes, previous_depts): | |
super(Applicant, self).__init__(*attributes) | |
self.location_restriction = location_restriction # boolean | |
self.previous_depts = previous_depts | |
class Job(object): | |
"""This class holds the combination of applicant, role, and which rotation | |
it was. This gives us the ability to track what worked and what didn't, | |
and give an idea of the progression of the applicant through the | |
program""" | |
def __init__(self, ApplicantID, RoleID, matching_score, rotation): | |
self.ApplicantID = str(ApplicantID) | |
self.RoleID = str(RoleID) | |
self.JobID = "".join([str(ApplicantID), str(RoleID)]) | |
self.matching_score = matching_score | |
self.rotation = rotation |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment