Exemple #1
0
        private static string NormalizeName(Address address)
        {
            string name;

            if (!DefaultQueueNamePolicy.names.TryGetValue(address.Queue, out name))
            {
                name = DefaultQueueNamePolicy.NameTransformation(address.Queue);

                DefaultQueueNamePolicy.names.TryAdd(address.Queue, name);
            }

            return(name);
        }
Exemple #2
0
 /// <summary>
 /// Gets queue table name in database based on address.
 /// </summary>
 /// <param name="address">Address for which queue table name must be returned.</param>
 /// <returns>Queue table name for provided address.</returns>
 /// <remarks>
 /// It returns the same name as <see cref="GetQueueName"/> but with prefix <i>AQ_</i>.
 /// </remarks>
 public string GetQueueTableName(Address address)
 {
     return(string.Format("AQ_{0}", DefaultQueueNamePolicy.NormalizeName(address)));
 }
Exemple #3
0
 /// <summary>
 /// Gets queue name in database based on address.
 /// </summary>
 /// <param name="address">Address for which queue name must be returned.</param>
 /// <returns>Queue name for provided address.</returns>
 public string GetQueueName(Address address)
 {
     return(DefaultQueueNamePolicy.NormalizeName(address));
 }