public FineApi(
     IRepository<User, UserDataModel, Guid> userRepository,
     IRepository<Payment, PaymentDataModel, Guid> paymentRepository,
     IFineMapper fineMapper,
     IUserMapper userMapper,
     IPaymentMapper paymentMapper,
     IExcelExportService<FineExportModel> excelExportService, 
     IChannelApi channelApi, 
     IUserApi userApi, 
     IGroupsApi groupApi, 
     IChatApi chatApi, 
     IReactionApi reactionApi)
 {
     this.userRepository = userRepository;
     this.paymentRepository = paymentRepository;
     this.fineMapper = fineMapper;
     this.userMapper = userMapper;
     this.paymentMapper = paymentMapper;
     this.excelExportService = excelExportService;
     this.channelApi = channelApi;
     this.userApi = userApi;
     this.groupApi = groupApi;
     this.chatApi = chatApi;
     this.reactionApi = reactionApi;
 }
 public ResponderBase(
     ISupportApi supportApi, IReactionApi reactionApi, IChatApi chatApi)
 {
     this.supportApi = supportApi;
     this.reactionApi = reactionApi;
     this.chatApi = chatApi;
 }
 public QuestionResponder(IChatApi chatApi)
 {
     this.webApi = new WebApi(ConfigurationManager.AppSettings["ServerAddress"],
                              ConfigurationManager.AppSettings["SlackBotApiToken"],
                              ConfigurationManager.AppSettings["ChannelId"]);
     this.chatApi = chatApi;
 }
示例#4
0
        private void Start()
        {
            chatApi = ApiProvider.ProvideChatApi();
            onChatMessageReceived = GetComponent <IOnChatMessageReceived>();

            SubscribeToChatApiEvents();
        }
 public FineCountAllResponder(IFineApi fineApi, 
     ISupportApi supportApi, 
     IReactionApi reactionApi,
     IChatApi chatApi)
     : base(supportApi, reactionApi, chatApi)
 {
     this.fineApi = fineApi;
 }
示例#6
0
        public GameRunner(IQuestionProvider provider, IChatApi chatapi, int secondsToAnswer)
        {
            _provider = provider;
            _controller = new QuizComunicator(chatapi);
            _timer = new Timer(OnTimeout);
            _secondsToAnswer = secondsToAnswer;

            _controller.QuestionAnswered += _controller_QuestionAnswered;
        }
示例#7
0
        public GameRunner(IQuestionProvider provider, IChatApi chatapi, int secondsToAnswer)
        {
            _provider        = provider;
            _controller      = new QuizComunicator(chatapi);
            _timer           = new Timer(OnTimeout);
            _secondsToAnswer = secondsToAnswer;

            _controller.QuestionAnswered += _controller_QuestionAnswered;
        }
 public ShowResponder(
     IUserApi userApi,
     ISupportApi supportApi,
     IReactionApi reactionApi,
     IChatApi chatApi
     )
     : base(supportApi, reactionApi, chatApi)
 {
     this.userApi = userApi;
 }
 public SeconderResponder(
     IFineApi fineApi,
     IUserApi userApi,
     ISupportApi supportApi,
     IReactionApi reactionApi,
     IChatApi chatApi)
     : base(supportApi, reactionApi, chatApi)
 {
     this.fineApi = fineApi;
     this.userApi = userApi;
 }
示例#10
0
 public AppState(IJSRuntime jSRuntime,
                 ILocalStorageService localStorage,
                 IComponentContext componentContext,
                 ILocalisationHelper localisationHelper,
                 IChatApi gitterApi)
 {
     JSRuntime          = jSRuntime;
     LocalStorage       = localStorage;
     ComponentContext   = componentContext;
     LocalisationHelper = localisationHelper;
     GitterApi          = gitterApi;
     //Task.Factory.StartNew(Initialise);
 }
示例#11
0
        static ApiCoordinator()
        {
            userSettings      = Locator.Current.GetService <ISettingsRepository>();
            sharedPreferences = Locator.Current.GetService <ISharedPreferences>();

            Func <long, Task> saveTime = (long time) => {
                return(Task.Run(() => sharedPreferences.SetLong(PreferencesKeys.LAST_REQUEST, time)));
            };

            var httpClient = new HttpClient(new CustomHttpClientHandler(GetToken, saveTime))
            {
                BaseAddress = new Uri(SERVER_URL)
            };

            loginApi   = RestService.For <ILoginApi>(httpClient);
            chatApi    = RestService.For <IChatApi>(httpClient);
            userApi    = RestService.For <IUserApi>(httpClient);
            patientApi = RestService.For <IPatientApi>(httpClient);
        }
 public GreetingJob(IChatApi chatApi, ISupportApi supportApi)
     : base(supportApi)
 {
     this.chatApi = chatApi;
 }
示例#13
0
 public Api(Server server, IAccount account = null, IGarage garage = null, IBannedIPs bannedIps = null, IChatApi chat = null, IServerApi serverApi = null)
 {
     Account  = account ?? new Account();
     Garage   = garage ?? new Garage();
     BannedIP = bannedIps ?? new BannedIPs();
     Chat     = chat ?? new Chat(server.Lobbies, server.Logger, server.Api);
     Server   = serverApi ?? new ServerApi(server);
 }
示例#14
0
 public Application(ILogger <Application> logger, IChatApi chat, IOptions <SlackConfiguration> options)
 {
     _logger  = logger;
     _chat    = chat;
     _options = options;
 }
示例#15
0
 public BotResponder(IChatApi chatApi)
 {
     this.m_ChatApi = chatApi;
 }
示例#16
0
 public QuizComunicator(IChatApi chatapi)
 {
     _view              = chatapi;
     _view.ChatMessage += OnChatMessageReceived;
 }
 public HelloResponder(IChatApi chatApi)
 {
     this.chatApi = chatApi;
 }