Ejemplo n.º 1
0
        //--------------------------------------------


        public override void StartSend()
        {
#if DEBUG
            //System.Diagnostics.Debug.WriteLine("start send");
            _sendComplete = false;
#endif
            _sendIO.StartSendAsync();///***
        }
Ejemplo n.º 2
0
 void StartSend()
 {
     if (isSend)
     {
         return;
     }
     isSend = true;
     sendIO.StartSendAsync();
 }
Ejemplo n.º 3
0
        public void StartSend(byte[] sendBuffer, int start, int len, Action whenSendCompleted)
        {
            //must be in opened state
            if (_workingState != WorkingState.Rest)
            {
                throw new Exception("sending error: state is not= opened");
            }
            //--------------------------------------------------------------
#if DEBUG
            if (this.whenSendCompleted != null)
            {
                //must be null
                throw new Exception("sending something?...");
            }
#endif
            this.whenSendCompleted = whenSendCompleted;
            this._workingState     = WorkingState.Sending;
            sendIO.EnqueueOutputData(sendBuffer, len);
            sendIO.StartSendAsync();
        }
Ejemplo n.º 4
0
 public void Write(string content)
 {
     byte[] dataToSend = CreateSendBuffer(content);
     sendIO.EnqueueOutputData(dataToSend, dataToSend.Length);
     sendIO.StartSendAsync();
 }
Ejemplo n.º 5
0
 public void SendIOStartSend() => _sendIO.StartSendAsync();
Ejemplo n.º 6
0
 internal void SendExternalRaw(byte[] data)
 {
     sendIO.EnqueueOutputData(data, data.Length);
     sendIO.StartSendAsync();
 }