Apache.NMS.Util.PrimitiveMapInterceptor.GetString C# (CSharp) Method

GetString() public method

public GetString ( string key ) : string
key string
return string
        public string GetString(string key)
        {
            Object value = GetObjectProperty(key);

            if(value == null)
            {
                return null;
            }
            else if((value is IList) || (value is IDictionary))
            {
                throw new MessageFormatException(" cannot read a boolean from " + value.GetType().Name);
            }

            return value.ToString();
        }