Exemple #1
0
 public FizzClient(IFizzSessionProvider sessionClient)
 {
     _dispatcher       = new FizzActionDispatcher();
     _sessionClient    = sessionClient;
     _chat             = new FizzChatClient(_dispatcher);
     _restClient       = new FizzRestClient(_dispatcher);
     _authClient       = new FizzAuthRestClient(_restClient);
     _ingestionClient  = new FizzIngestionClient(new FizzInMemoryEventLog(), _dispatcher);
     _moderationClient = new FizzModerationClient();
 }
Exemple #2
0
        public FizzClient(string appId, IFizzSessionProvider sessionClient)
        {
            if (string.IsNullOrEmpty(appId))
            {
                throw FizzException.ERROR_INVALID_APP_ID;
            }

            _dispatcher       = new FizzActionDispatcher();
            _sessionClient    = sessionClient;
            _chat             = new FizzChatClient(appId, _dispatcher);
            _restClient       = new FizzRestClient(_dispatcher);
            _authClient       = new FizzAuthRestClient(_restClient);
            _ingestionClient  = new FizzIngestionClient(new FizzInMemoryEventLog(), _dispatcher);
            _moderationClient = new FizzModerationClient();
        }