public virtual T registerAsSingleton <T, K>(IInfoContext infoctx, string applicationType, params object[] args) { if (isLoadable(infoctx, applicationType)) { Type clazz = typeof(K); return((T)FunctionCaller.registerAsSingleton <T>(clazz, args)); } return(default(T)); }
public static T RegisterAsSingleton <T, K>(params object[] args) { Type clazz = typeof(K); return(FunctionCaller.registerAsSingleton <T>(clazz, args)); }
public static T RegisterAsSingleton <T, K>() { Type clazz = typeof(K); return(FunctionCaller.registerAsSingleton <T>(clazz)); }
/// <summary> /// Register a Singleton Class /// </summary> /// <typeparam name="T">Generic Type Interface </typeparam> /// <param name="className"> NameSpace and Class Name that Implement T. </param> /// <returns>Interface's implementation</returns> public static T RegisterAsSingleton <T>(string className) { return(FunctionCaller.registerAsSingleton <T>(className)); }
/// <summary> /// Register a Singleton Class with its fields /// </summary> /// <typeparam name="T">Generic Type Interface </typeparam> /// <param name="className"> NameSpace and Class Name that Implement T. </param> /// <param name="args"> fields of this Class. </param> /// <returns>Interface's implementation</returns> public static T RegisterAsSingleton <T>(string className, params object[] args) { return(FunctionCaller.registerAsSingleton <T>(className, args)); }
public static T registerAsSingleton <T>(string className, params object[] args) { Type clazz = GetType(className); return(FunctionCaller.registerAsSingleton <T>(clazz, args)); }