private void SetClient(IHttpClient client) { this.mGetClient = (IHttpClient) client.Clone(); this.mCmdClient = (IHttpClient) client.Clone(); this.mGetClient.OnSent += new SentEventHandler(this.CallbackOnSent); this.mGetClient.OnReceived += new ReceivedEventHandler(this.CallbackOnGetReceived); this.mGetClient.OnNetworkError += new NetworkErrorEventHandler(this.CallbackOnError); this.mCmdClient.OnSent += new SentEventHandler(this.CallbackOnSent); this.mCmdClient.OnReceived += new ReceivedEventHandler(this.CallbackOnCmdReceived); this.mCmdClient.OnNetworkError += new NetworkErrorEventHandler(this.CallbackOnError); }
public bool SendREP(IHttpClient client, int excutemode, string user, string password) { if (this.IsExcute) { return false; } this.mIsExcute = true; this.mIsExcuteMode = excutemode; this.mIsTTM = false; this.Usersetting(); this.mHttpClient = (IHttpClient) client.Clone(); this.mUser = user; this.mPass = password; this.mHttpClient.OnSent += new SentEventHandler(this.CallbackOnSent); this.mHttpClient.OnReceived += new ReceivedEventHandler(this.CallbackOnReceived); this.mHttpClient.OnNetworkError += new NetworkErrorEventHandler(this.CallbackOnError); this.SendTimerStart(); return true; }
public bool SendTTM(IHttpClient client, string user, string password) { if (this.IsExcute) { return false; } this.mIsExcute = true; this.mIsExcuteMode = 0; this.mIsTTM = true; this.Usersetting(); this.mHttpClient = (IHttpClient) client.Clone(); this.mUser = user; this.mPass = password; this.mHttpClient.OnSent += new SentEventHandler(this.CallbackOnSent); this.mHttpClient.OnReceived += new ReceivedEventHandler(this.CallbackOnReceived); this.mHttpClient.OnNetworkError += new NetworkErrorEventHandler(this.CallbackOnError); this.txTerminal.Text = this.mTxTerminal; this.txAccessKey.Text = this.mTxAccessKey; this.ShowTimerStart(); return true; }
public DialogResult ShowDialog(IHttpClient client, string user, string password, bool post) { if (post) { this.Text = "管理資料再取り出し"; } else { this.Text = "管理資料取り出し"; } this.UserSetting(); this.mHttpClient = (IHttpClient) client.Clone(); this.mUser = user; this.mPass = password; this.mPost = post; this.mHttpClient.OnSent += new SentEventHandler(this.CallbackOnSent); this.mHttpClient.OnReceived += new ReceivedEventHandler(this.CallbackOnReceived); this.mHttpClient.OnNetworkError += new NetworkErrorEventHandler(this.CallbackOnError); return base.ShowDialog(); }