private static IIDConvertor[] GetConvertorInstances() { Assembly source = Assembly.GetAssembly(typeof(IIDConvertor)); if ( source == null ) return new IIDConvertor[] { new Inferis2IDConvertor() }; // Look for IIDConvertor classes ArrayList list = new ArrayList(); IEnumerator iter = source.GetExportedTypes().GetEnumerator(); while ( iter.MoveNext() ) { if ( ((Type)iter.Current).GetInterface( typeof(IIDConvertor).Name ) != null ) { list.Add( System.Activator.CreateInstance(((Type)iter.Current)) ); } } // Assign result IIDConvertor[] result = new IIDConvertor[list.Count]; list.TrimToSize(); list.CopyTo( result, 0 ); return result; }
public MapInfo( int zoom, int x, int y, int width, int height, string origin, string export, IIDConvertor convertor ) { this.signature = 0xE2E1; this.version = 1; this.zoom = zoom; this.x = x; this.y = y; this.width = width; this.height = height; // reserved buffer buffer = new byte[44]; // strings originfile = new char[512]; exportfile = new char[512]; idconvertor = new char[128]; SetString( ref originfile, origin ); SetString( ref exportfile, export ); IDConvertor = convertor.GetType(); }
public IDShader( IIDConvertor idconvertor ) { idc = idconvertor; }
public IDMapShader( IDMap idmap, bool diff ) { this.idmap = idmap; this.diff = diff; this.idc = null; }
public IDMapShader( IDMap idmap, IIDConvertor idconvertor ) { idc = idconvertor; this.idmap = idmap; this.diff = false; }
public MapInfo( int zoom, Point location, Size size, string origin, string export, IIDConvertor convertor ) : this(zoom, location.X, location.Y, size.Width, size.Height, origin, export, convertor) { }