示例#1
0
 public AkinatorClient(Language language, ServerType serverType, AkinatorUserSession existingSession = null)
 {
     m_webClient      = new HttpClient();
     m_usedLanguage   = language;
     m_usedServerType = serverType;
     Attach(existingSession);
 }
 public AkinatorClient(IAkinatorServer server, AkinatorUserSession existingSession = null, bool childMode = false)
 {
     m_webClient = new AkiWebClient();
     m_server    = server;
     m_childMode = childMode;
     Attach(existingSession);
 }
        public AkinatorClient(IAkinatorServer server, IAkinatorLogger logger, AkinatorUserSession existingSession = null, bool childMode = false)
        {
            _logger = logger;

            _mWebClient = new AkiWebClient(_logger);
            _mServer    = server;
            _mChildMode = childMode;
            Attach(existingSession);
        }
示例#4
0
 private void Attach(AkinatorUserSession existingSession)
 {
     if (existingSession != null)
     {
         m_step          = existingSession.Step;
         m_lastGuessStep = existingSession.LastGuessStep;
         m_session       = existingSession.Session;
         m_signature     = existingSession.Signature;
     }
 }
        private void Attach(AkinatorUserSession existingSession)
        {
            if (existingSession == null)
            {
                return;
            }

            _mStep          = existingSession.Step;
            _mLastGuessStep = existingSession.LastGuessStep;
            _mSession       = existingSession.Session;
            _mSignature     = existingSession.Signature;
        }
 public DebugAkinatorClient(IAkinatorServer server, IAkinatorLogger logger, AkinatorUserSession existingSession = null, bool childMode = false)
     : base(server, logger, existingSession, childMode)
 {
     _logger = logger;
 }