Class Login


  • public class Login
    extends java.lang.Object

    Package Starting Point - This class is used by client to make API calls to the Login service provided by User framework.



    Login is single point of contact for application for session related services. Login class should be used for authenticating the user. Once authenticated, other user services supported by the SDK can be used.
    • Field Detail

      • SDK_VERSION

        public static final java.lang.String SDK_VERSION
        For internal use
    • Method Detail

      • initService

        public static void initService​(Context context,
                                       IInFlightCallback inFlightCallback,
                                       InFlight inFlight)
        This API is the starting point for Login -- Initializes the service object and returns the object with the IInFlightCallback.
        Parameters:
        context - Provides access to resources and classes to initialize the object.
        inFlightCallback - IInFlightCallback Returns the instance or error message.
        inFlight - Initializes an InFlight instance.
        Example:
         AnalyticsV1.initService(context, inflightCallbackListener);
         

        public void onInitServiceComplete(Object serviceObj,String serviceName) { if(serviceName.equals(InFlightServices.USER_LOGIN_V1_SERVICE.getServiceName()}) { mSessionV1 = (Login) serviceObj; } }

      • logout

        public void logout​(Login.LogoutCompleteListener listener)
        Logs out the user.
        Parameters:
        listener - callback invoked upon logout completion.