public IEnumerable <string> GetDoc() { int cmdCount = cmdAttrs.Length; int hostCount = commandHostAttrs.Length; yield return(commandObject.IntanceType.Name); for (int i = 0; i < hostCount; i++) { if (commandHosts[i].GetValue(commandObject.TargetInstance) is CommandObject cmdobj) { foreach (string j in new DocGen(cmdobj).GetDoc()) { yield return($" {j}"); } } } for (int i = 0; i < cmdCount; i++) { CommandAttribute _cmdAttr = cmdAttrs[i]; CommandArguAttribute[] _paramInfos = paramAttrs[i]; } }
} // not root public static bool CanInvoke(CommandAttribute attribute, CommandArguAttribute[] paramInfos, string methodName, IArgument[] args) { return(CanInvoke(attribute, paramInfos, methodName, args, StringComparison.Ordinal)); }
} // not root public static object Invoke(MethodInfo method, CommandAttribute attribute, CommandArguAttribute[] paramInfos, object instance, IArgument[] args) { return(Invoke(method, attribute, paramInfos, instance, args, StringComparison.Ordinal)); } // not root
public static bool TryInvoke(MethodInfo method, CommandAttribute attribute, CommandArguAttribute[] paramInfos, object instance, IArgument[] args, out object result) { return(TryInvoke(method, attribute, paramInfos, instance, args, StringComparison.Ordinal, out result)); } // not root