Beispiel #1
0
        internal static string GetMSMQName(this PipeName pipeName)
        {
            var typeName = pipeName.GetType().Name;

            Debug.Assert(typeName.EndsWith(TypeSuffix),
                         "PipeName subclass " + typeName + " does not end with mandatory suffix " + TypeSuffix);
            // TODO: Remove "PipeName" type suffix and lowercase the string.
            typeName = typeName.Substring(0, typeName.Length - TypeSuffix.Length).ToLowerInvariant();
            var msmqName = Privacy + '\\' + Badge + Delimiter + typeName;

            msmqName += Delimiter + pipeName.LongName;
            return(msmqName);
        }