public ControllerInfo(Type type) { string aname = null; try { Type = type; m_Name = TypeToKeyName(type); var groups = new Registry <ActionGroupInfo>(); Groups = groups; var allmi = GetAllActionMethods(); foreach (var mi in allmi) { var iname = GetInvocationName(mi); aname = iname; var agi = groups[iname]; if (agi == null) { agi = new ActionGroupInfo(this, iname); groups.Register(agi); } aname = null; } } catch (Exception error) { throw new WaveException(StringConsts.MVC_CONTROLLER_REFLECTION_ERROR.Args(type.FullName, aname, error.ToMessageWithType()), error); } }
internal ActionInfo(ActionGroupInfo group, MethodInfo method) { Group = group; Method = method; Attribute = method.GetCustomAttribute(typeof(ActionBaseAttribute), false) as ActionBaseAttribute; }
internal ActionInfo(ActionGroupInfo group, MethodInfo method, ActionBaseAttribute atr) { Group = group; Method = method; Attribute = atr; }