public ProducedRequest(BaseTransactionUser transactionUser)
 {
     TransactionUser  = transactionUser;
     IncomingResponse = None;
     TransportError   = None;
     ProduceAck       = None;
 }
		public ProducedRequest(BaseTransactionUser transactionUser)
		{
			TransactionUser = transactionUser;
			IncomingResponse = None;
			TransportError = None;
			ProduceAck = None;
		}
 public AcceptedRequest(BaseTransactionUser transactionUser)
 {
     //Index = -1;
     TransportError = None;
     //IsAthorizationRequred = true;
     AuthorizationMode = AuthorizationMode.Enabled;
     TransactionUser   = transactionUser;
 }
		public AcceptedRequest(BaseTransactionUser transactionUser)
		{
			//Index = -1;
			TransportError = None;
			//IsAthorizationRequred = true;
			AuthorizationMode = AuthorizationMode.Enabled;
			TransactionUser = transactionUser;
		}
Exemple #5
0
        public void RegisterTransactionUser(BaseTransactionUser transactionUser)
        {
            foreach (var acceptedRequest in transactionUser.GetAcceptedRequests())
            {
                acceptedRequest.ValidateTransactionUserSettings();

                int index = acceptedRequests.Length;

                Array.Resize <AcceptedRequest>(ref acceptedRequests, index + 1);
                acceptedRequests[index] = acceptedRequest;

                int length = acceptedRequestIndexes[(int)acceptedRequest.Method].Length;
                Array.Resize <int>(ref acceptedRequestIndexes[(int)acceptedRequest.Method], length + 1);
                acceptedRequestIndexes[(int)acceptedRequest.Method][length] = index;

                //acceptedRequest.Index = index;
            }

            foreach (var producedRequest in transactionUser.GetProducedRequests())
            {
                int index = producedRequests.Length;

                Array.Resize <ProducedRequest>(ref producedRequests, index + 1);
                producedRequests[index] = producedRequest;

                producedRequest.Index = index;
            }

            transactionUser.SendNonTransactionMessage = SendNonTransactionMessage;
            transactionUser.SendResponseExternal      = SendResponse;
            transactionUser.SendRequest      = SendRequest;
            transactionUser.GetWriter        = GetSipResponseWriter;
            transactionUser.GetTransactionId = GetTransactionId;
            transactionUser.IsLocalAddress   = IsLocalAddress;
            transactionUser.Authentication   = authentication;
        }
		private void RegisterTransactionUser(BaseTransactionUser transactionUser)
		{
			acceptedRequests = new List<AcceptedRequest>();
			producedRequests = new List<ProducedRequest>();

			foreach (var acceptedRequest in transactionUser.GetAcceptedRequests())
			{
				acceptedRequest.ValidateTransactionUserSettings();
				acceptedRequests.Add(acceptedRequest);
			}

			foreach (var producedRequest in transactionUser.GetProducedRequests())
			{
				int index = producedRequests.Count;
				producedRequests.Add(producedRequest);
				producedRequest.Index = index;
			}

			transactionUser.SendNonTransactionMessage = SendNonTransactionMessage;
			transactionUser.SendResponseExternal = SendResponse;
			transactionUser.SendRequest = SendRequest;
			transactionUser.GetWriter = GetSipResponseWriter;
			transactionUser.GetTransactionId = GetTransactionId;
			transactionUser.IsLocalAddress = IsLocalAddress;
			transactionUser.Authentication = new AuthenticationX();
		}