c#.net 内存中 动态创建类型以及程序集
using System;
using System.Collections.Generic;
using System.Text;
using System.Reflection;
using System.Reflection.Emit;
namespace Com.Frzeng.Arch.Common.Data.AR
{
public class TypeCreator
{
public static Type Creator(string ClassName, int PropertiesCount)
{
IDictionary<string, Type> Properties = new Dictionary<string, Type>();
Type t = typeof(string);
Properties.Add(new KeyValuePair<string, Type>("ID", typeof(int)));
for (int i = 0; i < PropertiesCount; i++)
{
Properties.Add(new KeyValuePair<string, Type>("FF" + i, t));
}
return Creator(ClassName, Properties);
}
public static