public static string GetRegisteredClassName(string agentInstanceName) { if (Names.ContainsKey(agentInstanceName)) { AgentName_t _t = Names[agentInstanceName]; return(_t.ClassName); } return(null); }
public static bool RegisterStaticClass(System.Type type, string displayName, string desc) { string fullName = type.FullName; if (!Names.ContainsKey(fullName)) { Names[fullName] = new AgentName_t(fullName, fullName, displayName, desc); Utils.AddStaticClass(type); return(true); } return(false); }
public static bool RegisterName <TAGENT>(string agentInstanceName, string displayName, string desc) where TAGENT : Agent { string fullName = agentInstanceName; if (string.IsNullOrEmpty(fullName)) { fullName = typeof(TAGENT).FullName; } if (!Names.ContainsKey(fullName)) { string className = typeof(TAGENT).FullName; Names[fullName] = new AgentName_t(fullName, className, displayName, desc); return(true); } return(false); }