IAuthenticationResult IApplicationSync.AuthenticateAccount(IAuthenticationRequest request, Action<IRetrievalOptions<IAuthenticationResult>> responseOptions)
        {
            var options = new DefaultRetrievalOptions<IAuthenticationResult>();
            responseOptions(options);

            var dispatcher = new AuthenticationRequestDispatcher();

            return dispatcher.Authenticate(this.GetInternalSyncDataStore(), this, request, options);
        }
        Task<IAuthenticationResult> IApplication.AuthenticateAccountAsync(IAuthenticationRequest request, Action<IRetrievalOptions<IAuthenticationResult>> responseOptions, CancellationToken cancellationToken)
        {
            var options = new DefaultRetrievalOptions<IAuthenticationResult>();
            responseOptions(options);

            var dispatcher = new AuthenticationRequestDispatcher();

            return dispatcher.AuthenticateAsync(this.GetInternalAsyncDataStore(), this, request, options, cancellationToken);
        }
Ejemplo n.º 3
0
        IAuthenticationResult IApplicationSync.AuthenticateAccount(IAuthenticationRequest request, Action <IRetrievalOptions <IAuthenticationResult> > responseOptions)
        {
            var options = new DefaultRetrievalOptions <IAuthenticationResult>();

            responseOptions(options);

            var dispatcher = new AuthenticationRequestDispatcher();

            return(dispatcher.Authenticate(this.GetInternalSyncDataStore(), this, request, options));
        }
        Task <IAuthenticationResult> IApplication.AuthenticateAccountAsync(IAuthenticationRequest request, Action <IRetrievalOptions <IAuthenticationResult> > responseOptions, CancellationToken cancellationToken)
        {
            var options = new DefaultRetrievalOptions <IAuthenticationResult>();

            responseOptions(options);

            var dispatcher = new AuthenticationRequestDispatcher();

            return(dispatcher.AuthenticateAsync(this.GetInternalAsyncDataStore(), this, request, options, cancellationToken));
        }
Ejemplo n.º 5
0
        T IDataStoreSync.GetResource <T>(string href, Action <IRetrievalOptions <T> > options)
        {
            var optionsInstance = new DefaultRetrievalOptions <T>();

            options(optionsInstance);

            var queryString = optionsInstance.ToString();

            if (!string.IsNullOrEmpty(queryString))
            {
                href = $"{href}?{queryString}";
            }

            return(this.AsSyncInterface.GetResource <T>(href));
        }
Ejemplo n.º 6
0
        Task <T> IDataStore.GetResourceAsync <T>(string href, Action <IRetrievalOptions <T> > options, CancellationToken cancellationToken)
        {
            var optionsInstance = new DefaultRetrievalOptions <T>();

            options(optionsInstance);

            var queryString = optionsInstance.ToString();

            if (!string.IsNullOrEmpty(queryString))
            {
                href = $"{href}?{queryString}";
            }

            return(this.AsAsyncInterface.GetResourceAsync <T>(href, cancellationToken));
        }