mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-10-15 18:55:07 +08:00
-
This commit is contained in:
@@ -45,7 +45,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
public virtual void InitTables(string entitiesNamespace)
|
public virtual void InitTables(string entitiesNamespace)
|
||||||
{
|
{
|
||||||
var types = Assembly.Load(entitiesNamespace).GetTypes();
|
var types = ReflectionCore.Load(entitiesNamespace).GetTypes();
|
||||||
InitTables(types);
|
InitTables(types);
|
||||||
}
|
}
|
||||||
public virtual void InitTables(params string[] entitiesNamespaces)
|
public virtual void InitTables(params string[] entitiesNamespaces)
|
||||||
|
@@ -80,4 +80,12 @@ namespace SqlSugar
|
|||||||
return method.ReflectedType;
|
return method.ReflectedType;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static class ReflectionCore
|
||||||
|
{
|
||||||
|
public static Assembly Load(string name)
|
||||||
|
{
|
||||||
|
return Assembly.Load(name);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -8,7 +8,7 @@ namespace SqlSugar
|
|||||||
{
|
{
|
||||||
public class InstanceFactory
|
public class InstanceFactory
|
||||||
{
|
{
|
||||||
static Assembly assembly = Assembly.Load(PubConst.AssemblyName);
|
static Assembly assembly = ReflectionCore.Load(PubConst.AssemblyName);
|
||||||
static Dictionary<string, Type> typeCache = new Dictionary<string, Type>();
|
static Dictionary<string, Type> typeCache = new Dictionary<string, Type>();
|
||||||
|
|
||||||
#region Queryable
|
#region Queryable
|
||||||
|
Reference in New Issue
Block a user