NHibernate.Lob.External.FileSystemCasConnection.GetPath C# (CSharp) Method

GetPath() public method

public GetPath ( byte contentIdentifier ) : string
contentIdentifier byte
return string
		public string GetPath(byte[] contentIdentifier)
		{
			if (contentIdentifier == null) throw new NullReferenceException("contentIdentifier cannot be null.");
			System.Text.StringBuilder sb = new System.Text.StringBuilder();
			sb.Append(contentIdentifier[0].ToString("x2"));
			sb.Append(Path.DirectorySeparatorChar);
			sb.Append(contentIdentifier[1].ToString("x2"));
			sb.Append(Path.DirectorySeparatorChar);
			for(int i = 2; i < contentIdentifier.Length; i++)
				sb.Append(contentIdentifier[i].ToString("x2"));
			return Path.Combine(path, sb.ToString());
		}