public static void RegisterHandler(string typeFullName,HashAlbianObjectHandler<IAlbianObject> splitHandler) { string routingName = string.Empty; if (string.IsNullOrEmpty(routingName)) { routingName = PersistenceParser.DefaultRoutingName; } //Type[] types = splitHandler.GetType().GetGenericArguments(); RegisterHandler(routingName,typeFullName,splitHandler); }
public static void RegisterHandler(string typeFullName, HashAlbianObjectHandler <IAlbianObject> splitHandler) { string routingName = string.Empty; if (string.IsNullOrEmpty(routingName)) { routingName = PersistenceParser.DefaultRoutingName; } //Type[] types = splitHandler.GetType().GetGenericArguments(); RegisterHandler(routingName, typeFullName, splitHandler); }
public static string GetTableFullName(IRoutingAttribute routing, IAlbianObject target) { HashAlbianObjectHandler <IAlbianObject> handler = HashAlbianObjectManager.GetHandler(routing.Name, AssemblyManager.GetFullTypeName(target)); string tableName = null == handler ? routing.TableName : String.Format("{0}{1}", routing.TableName, handler(target)); return("dbo" == routing.Owner || String.IsNullOrEmpty(routing.Owner) ? tableName : String.Format("[{0}].[{1}]", routing.Owner, tableName)); }
public static void RegisterHandler(string routingName,string typeFullName,HashAlbianObjectHandler<IAlbianObject> splitHandler) { if (string.IsNullOrEmpty(routingName)) { throw new ArgumentNullException("routingName"); } //string typeFullName = AssemblyManager.GetFullTypeName<T>(); if (null == splitHandler) return; string key = GetHashTableKey(routingName, typeFullName); if (!_hashAlbianObjectHandlers.ContainsKey(key)) { _hashAlbianObjectHandlers.Add(key, splitHandler); } else { _hashAlbianObjectHandlers[key] = splitHandler; } }
public static void RegisterHandler(string routingName, string typeFullName, HashAlbianObjectHandler <IAlbianObject> splitHandler) { if (string.IsNullOrEmpty(routingName)) { throw new ArgumentNullException("routingName"); } //string typeFullName = AssemblyManager.GetFullTypeName<T>(); if (null == splitHandler) { return; } string key = GetHashTableKey(routingName, typeFullName); if (!_hashAlbianObjectHandlers.ContainsKey(key)) { _hashAlbianObjectHandlers.Add(key, splitHandler); } else { _hashAlbianObjectHandlers[key] = splitHandler; } }