我正在使用链接的 j 库。我可以连接到链接,但是当我查看当前用户的个人资料的详细信息时,我会得到整个 Person 对象,但这个对象只包含名字、姓氏和标题的值。其他值为空。但是当我访问我链接的公共个人资料时,我可以看到他们的技能、大学等。我的应用程序具有完全访问权限。
问问题
169 次
1 回答
0
我认为您从未在枚举中设置 ProfileField 请尝试这样,
Set<ProfileField> propertiesToFetch = EnumSet.of(ProfileField.ID,
ProfileField.FIRST_NAME, ProfileField.LAST_NAME,
ProfileField.HEADLINE, ProfileField.PICTURE_URL,
ProfileField.DATE_OF_BIRTH, ProfileField.PHONE_NUMBERS,
ProfileField.MAIN_ADDRESS, ProfileField.INDUSTRY,
ProfileField.EDUCATIONS, ProfileField.LANGUAGES_LANGUAGE_NAME,
ProfileField.SKILLS_SKILL_NAME,
ProfileField.CERTIFICATIONS_NAME, ProfileField.POSITIONS_TITLE,
ProfileField.POSITIONS_COMPANY_NAME,
ProfileField.POSITIONS_COMPANY);
Person profile = client.getProfileForCurrentUser(propertiesToFetch);
于 2014-03-27T12:50:21.543 回答