예제 #1
0
파일: Port.cs 프로젝트: Dloz/Task3
        public void OutgoingCall(object sender, CallEventArgs e)
        {
            if (State != PortState.Connected)
            {
                return;
            }
            State = PortState.Busy;

            CurrentCallId = Guid.NewGuid();
            e.Id          = CurrentCallId;
            Console.WriteLine(@"Port -> OutgoingCall: id {0}", CurrentCallId);

            PortCallEvent?.Invoke(sender, e);
        }
예제 #2
0
 public void IncomingCall(string number, string incomingNumber)
 {
     PortCallEvent?.Invoke(this, new CallEventArgs(number, incomingNumber));
 }
예제 #3
0
 protected virtual void DoIncomingCallEvent(int number, int objectNumber)
 {
     PortCallEvent?.Invoke(this, new CallArgsEvent(number, objectNumber));
 }