BF2Statistics.Web.MvcRoute.MvcRoute C# (CSharp) Метод

MvcRoute() публичный Метод

Creates a new instance of MvcRoute
public MvcRoute ( string DocumentPath ) : System
DocumentPath string
Результат System
        public MvcRoute(string DocumentPath)
        {
            // Get the document path into an array
            string[] parts = DocumentPath.Split(SplitChar, StringSplitOptions.RemoveEmptyEntries);

            // Fetch our Controller
            Controller = (parts.Length > 0) ? parts[0] : "index";

            // Fetch our Action
            Action = (parts.Length > 1) ? parts[1] : "index";

            // Fetch our parameters if we have any
            Params = (parts.Length > 2) ? parts.Skip(2).ToArray() : new string[0];
        }
MvcRoute