public MsmqEndpointAddress(Uri uri) : base(uri) { PublicQueuesNotAllowed(); InboundFormatName = uri.GetInboundFormatName(); InboundUri = uri.GetInboundUri(); OutboundFormatName = uri.GetOutboundFormatName(); IsTransactional = CheckForTransactionalHint(uri); MulticastAddress = uri.GetMulticastAddress(); if(MulticastAddress != null) { IsTransactional = false; LocalName = uri.GetLocalName(); } else if (IsLocal) { IsTransactional = IsLocalQueueTransactional(); LocalName = uri.GetLocalName(); Uri = SetUriHostToLocalMachineName(); } }
public S3V4URI(string path) { m_Path = path;//.TrimEnd('/'); m_Uri = new Uri(path); S3V4URLHelpers.Parse(m_Uri, out m_Bucket, out m_Region, out m_LocalPath, out m_QueryParams); m_LocalName = m_Uri.GetLocalName(); m_ParentPath = m_Uri.GetParentURL(); }
public void LocalNameEmpty() { { Uri uri = new Uri("https://dxw.s3-us-west-2.amazonaws.com/"); string parent = uri.GetLocalName(); Assert.AreEqual(string.Empty, parent); } { Uri uri = new Uri("https://dxw.s3-us-west-2.amazonaws.com"); string parent = uri.GetLocalName(); Assert.AreEqual(string.Empty, parent); } }
public void LocalNameFolderFile() { Uri uri = new Uri("https://dxw.s3-us-west-2.amazonaws.com/MyFolder/MyFile1.txt"); string parent = uri.GetLocalName(); Assert.AreEqual("MyFile1.txt", parent); }