public CXXTranslator(TranslateContext translateContext, CXXTranslateOptions options) { this.options = options; this.translateContext = translateContext; Assembly assembly = Assembly.GetAssembly(typeof(ILConverters.IILConverter)); TypeFilter typeNameFilter = new TypeFilter(TypeNameFilter); foreach (var type in assembly.GetTypes()) { Type[] typeInterfaces = type.FindInterfaces(typeNameFilter, typeof(ILConverters.ICXXILConverter)); if (typeInterfaces.Length > 0) { var newConv = System.Activator.CreateInstance(type) as ILConverters.ICXXILConverter; convertersCXX.Add(newConv.TargetOpCode(), newConv); } } }
public CXXTranslator(TranslateContext translateContext, CXXTranslateOptions options) { this.options = options; this.translateContext = translateContext; }