System.Security.Util.StringExpressionSet.CanonicalizePath C# (CSharp) Method

CanonicalizePath() static private method

static private CanonicalizePath ( String path ) : String
path String
return String
        internal static String CanonicalizePath( String path )
        {
            return CanonicalizePath( path, true );
        }

Same methods

StringExpressionSet::CanonicalizePath ( String path, bool needFullPath ) : String

Usage Example

 public void AddExpressions(string str)
 {
     if (str == null)
     {
         throw new ArgumentNullException("str");
     }
     if (str.Length == 0)
     {
         return;
     }
     str = this.ProcessWholeString(str);
     this.m_expressions      = this.m_expressions != null ? this.m_expressions + StringExpressionSet.m_separators[0].ToString() + str : str;
     this.m_expressionsArray = (string[])null;
     string[] strArray = this.Split(str);
     if (this.m_list == null)
     {
         this.m_list = new ArrayList();
     }
     for (int index = 0; index < strArray.Length; ++index)
     {
         if (strArray[index] != null && !strArray[index].Equals(""))
         {
             string path   = this.ProcessSingleString(strArray[index]);
             int    length = path.IndexOf(char.MinValue);
             if (length != -1)
             {
                 path = path.Substring(0, length);
             }
             if (path != null && !path.Equals(""))
             {
                 if (this.m_throwOnRelative)
                 {
                     if (Path.IsRelative(path))
                     {
                         throw new ArgumentException(Environment.GetResourceString("Argument_AbsolutePathRequired"));
                     }
                     path = StringExpressionSet.CanonicalizePath(path);
                 }
                 this.m_list.Add((object)path);
             }
         }
     }
     this.Reduce();
 }
All Usage Examples Of System.Security.Util.StringExpressionSet::CanonicalizePath