예제 #1
0
        public AuthService(IDatabaseSettings settings, IEndpointService endpointService)
        {
            var client = new MongoClient(settings.ConnectionString);

            MongoCollection = client.GetDatabase(settings.DatabaseName).GetCollection <Auth>("Auths");
            EndpointService = endpointService;
        }
 public WebhookDebuggerController(
     ILogger <WebhookDebuggerController> logger,
     IEndpointService endpointService)
 {
     _logger          = logger;
     _endpointService = endpointService;
 }
 public PutController(IEndpointService endpointService, IParametersProcessorService parametersProcessorService,
                      ISparqlFactoryService sparqlFactoryService)
 {
     _endpointService            = endpointService;
     _parametersProcessorService = parametersProcessorService;
     _sparqlFactoryService       = sparqlFactoryService;
 }
예제 #4
0
 public DataController(
     IEndpointService endpointService,
     IReportingService reportingService)
 {
     _endpointService  = endpointService;
     _reportingService = reportingService;
 }
예제 #5
0
 public LyricsService(
     IDataApiHttpClient httpClient,
     IEndpointService endpointService)
 {
     _httpClient      = httpClient;
     _endpointService = endpointService;
 }
 public EndpointsController(IEndpointService endpointService,
                            IUserInfoService userInfoService,
                            IOptions <PagingOptions> defaultPagingOptions)
 {
     _endpointService      = endpointService;
     _userInfoService      = userInfoService;
     _defaultPagingOptions = defaultPagingOptions.Value;
 }
예제 #7
0
 public SmartGridHarness(IServiceLocator services, IEndpointService endpointService, IQueryService queryService, ISmartRequest request, IEnumerable <IGridPolicy> globalPolicies)
 {
     _services        = services;
     _endpointService = endpointService;
     _queryService    = queryService;
     _request         = request;
     _globalPolicies  = globalPolicies;
 }
 public Endpoint FindEndpoint(IEndpointService endpoints, ContextualObject target)
 {
     return(new Endpoint()
     {
         IsAuthorized = true,
         Url = Text()
     });
 }
 public PostController(IEndpointService endpointService, IParametersProcessorService parametersProcessorService,
                       ISparqlFactoryService sparqlFactoryService, IMapper mapper)
 {
     _endpointService            = endpointService;
     _parametersProcessorService = parametersProcessorService;
     _sparqlFactoryService       = sparqlFactoryService;
     _mapper = mapper;
 }
예제 #10
0
 public GenericController(IRouteHandlerService routeHandlerService, ILoggingService loggingService,
                          IAsyncRequestService asyncRequestService, IEndpointService endpointService, IFileService fileService)
 {
     RouteHandlerService = routeHandlerService;
     LoggingService      = loggingService;
     AsyncRequestService = asyncRequestService;
     EndpointService     = endpointService;
     FileService         = fileService;
 }
 public GetController(IEndpointService endpointService, IParametersProcessorService parametersProcessorService,
                      ISparqlFactoryService sparqlFactoryService, IResultFormatterService resultFormatterService,
                      INamespaceFactoryService namespaceFactoryService, IMapper mapper)
 {
     _endpointService            = endpointService;
     _parametersProcessorService = parametersProcessorService;
     _sparqlFactoryService       = sparqlFactoryService;
     _resultFormatterService     = resultFormatterService;
     _namespaceFactoryService    = namespaceFactoryService;
     _mapper = mapper;
 }
예제 #12
0
        public RenderPartialExpression(TViewModel model, IFubuPage parentPage, IPartialRenderer renderer, ITagGenerator <TViewModel> tagGenerator, IEndpointService endpointService)
        {
            if (tagGenerator == null)
            {
                throw new ArgumentNullException("tagGenerator");
            }

            _model           = model;
            _renderer        = renderer;
            _tagGenerator    = tagGenerator;
            _endpointService = endpointService;
            _parentPage      = parentPage;
        }
예제 #13
0
 public EndpointLinksController(IUserInfoService userInfoService,
                                IEndpointLinkService linkService,
                                IEndpointService endpointService,
                                INotificationService notificationService,
                                IHubContext <MainHub, IMainHub> hubContext,
                                IOptions <PagingOptions> defaultPagingOptions)
 {
     _userInfoService      = userInfoService;
     _linkService          = linkService;
     _endpointService      = endpointService;
     _notificationService  = notificationService;
     _hubContext           = hubContext;
     _defaultPagingOptions = defaultPagingOptions.Value;
 }
예제 #14
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ClientBuilderApiController"/> class.
        /// </summary>
        /// <param name="hostEnvironment"></param>
        /// <param name="pageService"></param>
        /// <param name="endpointService"></param>
        /// <param name="scaffoldModulesProvider"></param>
        public ClientBuilderApiController(
            IHostEnvironment hostEnvironment,
            IPageService pageService,
            IEndpointService endpointService,
            IScaffoldModulesProvider scaffoldModulesProvider)
        {
            if (!hostEnvironment.IsDevelopment())
            {
                throw new DevelopmentOnlyException(ClientBuilderMessages.ProtectedControllerExceptionMessage);
            }

            this.pageService             = pageService;
            this.endpointService         = endpointService;
            this.scaffoldModulesProvider = scaffoldModulesProvider;
        }
        public void SetUp()
        {
            _mocks           = new MockRepository();
            _view            = MockRepository.GenerateStub <IFubuPage>();
            _partialView     = MockRepository.GenerateStub <IFubuPage>();
            _renderer        = MockRepository.GenerateMock <IPartialRenderer>();
            _tagGenerator    = MockRepository.GenerateMock <ITagGenerator <TestModel> >();
            _endpointService = MockRepository.GenerateMock <IEndpointService>();
            _model           = new TestModel();
            _partialModel    = new PartialTestModel();

            _model.PartialModel = _partialModel;

            _expression = new RenderPartialExpression <TestModel>(_model, _view, _renderer, _tagGenerator, _endpointService);
            _expression.Using <IFubuPage>(v => { _wasCalled = true; });
        }
        public void SetUp()
        {
            _mocks = new MockRepository();
            _view = MockRepository.GenerateStub<IFubuPage>();
            _partialView = MockRepository.GenerateStub<IFubuPage>();
            _renderer = MockRepository.GenerateMock<IPartialRenderer>();
            _tagGenerator = MockRepository.GenerateMock<IElementGenerator<TestModel>>();
            _endpointService = MockRepository.GenerateMock<IEndpointService>();
            _model = new TestModel();
            _partialModel = new PartialTestModel();

            _model.PartialModel = _partialModel;

            _expression = new RenderPartialExpression<TestModel>(_model, _view, _renderer,_tagGenerator, _endpointService);
            _expression.Using<IFubuPage>(v => { _wasCalled = true; });
        }
        public void SetUp()
        {
            _resultingTag = null;

            page = MockRepository.GenerateMock<IFubuPage>();
            endpoints = MockRepository.GenerateMock<IEndpointService>();

            page.Expect(x => x.Get<IEndpointService>()).Return(endpoints);

            theFinder = s => s.EndpointForNew<SomeEntity>();

            theEndpoint = new Endpoint(){
                IsAuthorized = false,
                Url = "some url"
            };

            endpoints.Expect(x => x.EndpointForNew<SomeEntity>()).Return(theEndpoint);
        }
예제 #18
0
        public void SetUp()
        {
            _resultingTag = null;

            page      = MockRepository.GenerateMock <IFubuPage>();
            endpoints = MockRepository.GenerateMock <IEndpointService>();

            page.Expect(x => x.Get <IEndpointService>()).Return(endpoints);

            theFinder = s => s.EndpointForNew <SomeEntity>();

            theEndpoint = new Endpoint()
            {
                IsAuthorized = false,
                Url          = "some url"
            };

            endpoints.Expect(x => x.EndpointForNew <SomeEntity>()).Return(theEndpoint);
        }
예제 #19
0
 public FeedbackViewModel(
     IPageDialogService pageDialogService,
     INavigationService navigationService,
     IFeedbackService feedbackService,
     IFeedbackEndpointService feedbackEndpointService,
     IErrorRetryManager errorRetryManager,
     IEndpointService endpointService,
     ICompleteMessageService completeMessageService)
 {
     PageDialogService       = pageDialogService;
     NavigationService       = navigationService;
     FeedbackService         = feedbackService;
     FeedbackEndpointService = feedbackEndpointService;
     ErrorRetryManager       = errorRetryManager;
     EndpointService         = endpointService;
     CompleteMessageService  = completeMessageService;
     Submit    = new DelegateCommand(OnSubmit);
     Questions = new ObservableCollection <SurveyQuestion>();
 }
예제 #20
0
        public async Task <APIGatewayProxyResponse> RegisterHandler(APIGatewayProxyRequest request, ILambdaContext context)
        {
            var resp = new APIGatewayProxyResponse()
            {
                StatusCode = 200
            };

            try
            {
                var endpoint = JsonConvert.DeserializeObject <Endpoint>(request.Body);
                IEndpointService endpointService = _ServiceProvider.GetService <IEndpointService>();
                await endpointService.SaveEndpoint(endpoint);
            }
            catch (Exception ex)
            {
                resp.StatusCode = 500;
                resp.Body       = ex.ToString();
            }

            return(resp);
        }
예제 #21
0
        private async Task <SkillResponse> HandleIntentRequest(SkillRequest input)
        {
            IntentRequest request  = input.Request as IntentRequest;
            var           response = CreateBasicSkillResponse();

            // get endpoint values
            IEndpointService endpointService = _ServiceProvider.GetService <IEndpointService>();
            var endpoint = await endpointService.GetEndpoint(input.Context.System.User.UserId);

            if (endpoint == null)
            {
                response.Response.OutputSpeech = new PlainTextOutputSpeech("Endpoint is not setup");
                return(response);
            }

            // get garage service
            var    garageService = GetGarageService(endpoint);
            string result        = null;

            switch (request.Intent.Name)
            {
            case "GetStatus":
                result = await GetStatus(garageService, request.Intent);

                break;

            case "Move":
                result = await MoveGarage(garageService, request.Intent);

                break;
            }

            if (result != null)
            {
                response.Response.OutputSpeech = new PlainTextOutputSpeech(result);
            }

            return(response);
        }
 public RouteHandlerService(IEndpointService endpointService, IFileService fileService)
 {
     EndpointService = endpointService;
     FileService     = fileService;
 }
예제 #23
0
 public void SetUp()
 {
     endpoints    = MockRepository.GenerateMock <IEndpointService>();
     request      = new InMemorySmartRequest();
     queryService = new QueryService(new IFilterHandler[0]);
 }
예제 #24
0
 protected NavigationItemCaseBase(BehaviorGraph graph, IEndpointService endpointService)
 {
     _graph = graph;
     _endpointService = endpointService;
     _actionCall = new Lazy<ActionCall>(() => _graph.Behaviors.SingleOrDefault(chain => chain.InputType() == inputModel().GetType()).FirstCall());
 }
예제 #25
0
 public HtmlConventionsAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #26
0
 public PackageDiagnosticsAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #27
0
 public EndpointController(IEndpointService endpointService)
 {
     EndpointService = endpointService;
 }
예제 #28
0
 public DashboardAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #29
0
 public RouteAuthorizationAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #30
0
 protected NavigationItemCaseBase(BehaviorGraph graph, IEndpointService endpointService)
 {
     _graph           = graph;
     _endpointService = endpointService;
     _actionCall      = new Lazy <ActionCall>(() => _graph.Behaviors.SingleOrDefault(chain => chain.InputType() == inputModel().GetType()).FirstCall());
 }
예제 #31
0
 public GettingStartedNavigationItem(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #32
0
 public AuthorizedContextualMenu(IEndpointService endpoints, IEnumerable <IContextualAction <T> > actions)
 {
     _endpoints = endpoints;
     _actions   = actions;
 }
예제 #33
0
 public RouteExplorerAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #34
0
 public SparqlFactoryService(INamespaceFactoryService namespaceFactoryService, IEndpointService endpointService)
 {
     _namespaceFactoryService = namespaceFactoryService;
     _endpointService         = endpointService;
 }
예제 #35
0
 public SignalR(IRequestProcessor requestProcessor, IEndpointService endpointService, ILogger <SignalR> log)
 {
     _requestProcessor = requestProcessor;
     _endpointService  = endpointService;
     _log = log;
 }
예제 #36
0
 public RouteAuthorizationAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #37
0
 public DashboardAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #38
0
 public PackageDiagnosticsAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }
예제 #39
0
 public RouteExplorerAction(BehaviorGraph graph, IEndpointService endpointService)
     : base(graph, endpointService)
 {
 }