001/** 002 * Copyright 2014 Tampere University of Technology, Pori Department 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package service.tut.pori.users.facebook; 017 018import com.google.gson.annotations.SerializedName; 019 020import core.tut.pori.users.UserIdentity; 021 022/** 023 * Facebook user credential with user details. 024 * 025 */ 026public class FacebookCredential { 027 private transient UserIdentity _userId = null; 028 @SerializedName(value="id") 029 private String _id = null; 030 @SerializedName(value="name") 031 private String _name = null; 032 @SerializedName(value="first_name") 033 private String _givenName = null; 034 @SerializedName(value="last_name") 035 private String _familyName = null; 036 @SerializedName(value="link") 037 private String _link = null; 038 @SerializedName(value="gender") 039 private String _gender = null; 040 @SerializedName(value="locale") 041 private String _locale = null; 042 @SerializedName(value="email") 043 private String _email = null; 044 045 /** 046 * @param userId the userId to set 047 */ 048 protected void setUserId(UserIdentity userId) { 049 _userId = userId; 050 } 051 052 /** 053 * @return the userId 054 */ 055 public UserIdentity getUserId() { 056 return _userId; 057 } 058 059 /** 060 * @return the id 061 */ 062 public String getId() { 063 return _id; 064 } 065 066 /** 067 * @return the name 068 */ 069 public String getName() { 070 return _name; 071 } 072 073 /** 074 * @return the givenName 075 */ 076 public String getGivenName() { 077 return _givenName; 078 } 079 080 /** 081 * @return the familyName 082 */ 083 public String getFamilyName() { 084 return _familyName; 085 } 086 087 /** 088 * @return the link 089 */ 090 public String getLink() { 091 return _link; 092 } 093 094 /** 095 * @return the gender 096 */ 097 public String getGender() { 098 return _gender; 099 } 100 101 /** 102 * @return the locale 103 */ 104 public String getLocale() { 105 return _locale; 106 } 107 108 /** 109 * @return the email 110 */ 111 public String getEmail() { 112 return _email; 113 } 114}