コード例 #1
0
def getUserEducation(user):
	lc = Linkedin()           # this guys is the linkedin crawler
	educations = []
	profile = lc.getProfile(user)
	pr1 = profile["education"]
	for ed in pr1:
		educations.append(ed["school"])
	return educations
コード例 #2
0
def isUserFromUK(user):
	lc = Linkedin()           # this guys is the linkedin crawler
	profile = lc.getProfile(URLS[0])
	pr1 = profile["locality"]
	list = pr1.split(",", 1)
	if list[1] == ' United Kingdom':
		return True
	else:
		return False
コード例 #3
0
def getEducation(user):
	lc = Linkedin()           # this guys is the linkedin crawler
	profile = lc.getProfile(user)
	if not _isUserFromUK(profile):
		return NONE
	edu = _getUserEducation(profile)
	if _isUserFromUni(edu):
		return EDUCATION_TABLE_INVERTED["High"]
	elif _isUserFromSch(edu):
		return EDUCATION_TABLE_INVERTED["Mid"]
	else:
		return EDUCATION_TABLE_INVERTED["Low"]