Class FacebookTokenAdapter

  • All Implemented Interfaces:
    ITokenAdapter

    public class FacebookTokenAdapter
    extends Object
    Token adapter for Facebook.
    • Constructor Detail

      • FacebookTokenAdapter

        protected FacebookTokenAdapter()
    • Method Detail

      • renewUserProfile

        public Optional<org.pac4j.core.profile.UserProfile> renewUserProfile​(IAuthWebContext authWebContext)
                                                                      throws org.pac4j.core.exception.TechnicalException
        Throws:
        org.pac4j.core.exception.TechnicalException
      • getAccessToken

        public String getAccessToken​(IAuthWebContext authWebContext)
        Returns:
        The access token
      • getRefreshToken

        public String getRefreshToken​(IAuthWebContext authWebContext)
        Returns:
        The refresh token
      • isExpired

        public boolean isExpired​(org.pac4j.core.profile.UserProfile profile)
        Specified by:
        isExpired in interface ITokenAdapter
        Returns:
        Whether the access_token of the profile is expired
      • getUserProfile

        public Optional<org.pac4j.core.profile.UserProfile> getUserProfile​(IAuthWebContext authWebContext)
        Description copied from interface: ITokenAdapter
        Returns the user profile associated with this token adapter.
        Specified by:
        getUserProfile in interface ITokenAdapter
        Returns:
        An optional containing the user profile if it exists, otherwise empty.