public static string RxGetClassText(this object obj, string key)
 {
     if (obj.GetType() == typeof(ClassTextReader))
     {
         throw new InvalidOperationException();
     }
     else
     {
         return(RxGet(ClassTextReaderCache.Acquire(obj.GetType()), key));
     }
 }
示例#2
0
 public static string GetClassText(this Type type, string key)
 {
     return(ClassTextReaderCache.Acquire(type)[key]);
 }
 public static string RxGetClassText <T>(string key)
 {
     return(RxGet(ClassTextReaderCache.Acquire <T>(), key));
 }
 /// <summary>
 /// 根据OpenFx当前的语言环境获取当前对象上加载的对应区域码的类文本值
 /// </summary>
 /// <param name="obj"></param>
 /// <param name="key"></param>
 /// <returns>应得的文本,发生错误时将返回key值</returns>
 /// <returns>应得的文本,发生错误时将返回key值</returns>
 public static string RxGetClassText(this object obj, string key)
 {
     return(RxGet(ClassTextReaderCache.Acquire(obj.GetType()), key));
 }