应用反射获取当前类的程序集下某个目录下的类,再执行方法
MethodBase currentMethod = MethodBase.GetCurrentMethod();
string _namespace = currentMethod.DeclaringType.Namespace + ".Processor.";
Assembly assembly = Assembly.GetExecutingAssembly();
Type type = assembly.GetType(_namespace + task.Task_Name);
if (type != null)
{
object _Instance = Activator.CreateInstance(type);
MethodInfo method = type.GetMethod("DoExecute");
method.Invoke(_Instance, new object[] { task });
}