public static IDictionary <string, Controller> GetControllers(this GComponent component, string[] srcs) { var dictionary = new Dictionary <string, Controller>(); for (int i = 0; i < srcs.Length; i++) { if (srcs[i].Contains("/")) { var prefixPath = System.IO.Path.GetDirectoryName(srcs[i]).Replace("\\", "/");; var name = System.IO.Path.GetFileName(srcs[i]); var com = component.GetCompnentInChildren(prefixPath); dictionary.Add(srcs[i], com.asCom.GetController(name)); } else { dictionary.Add(srcs[i], component.GetController(srcs[i])); } } return(dictionary); }