IlvMapDXFReader
class
reads DXF features from a specified DXF file or catalog. It implements
the IlvMapFeatureIterator interface to iterate over the read features.lvMapDXFReader
instance
from the path of the DXF file:String DXFpath = " C:/maps/DXF/map.dxf"; IlvMapDXFReader reader = new IlvMapDXFReader(DXFpath);
reader.setDestinationBounds(new Rectangle2D.Double (lonMinRad,latMinRad,lonMaxRad,latMaxRad));
IlvFeatureRenderer renderer = reader. getDefaultFeatureRenderer ();
IlvMapFeature feature = reader.getNextFeature(); while(feature != null) { // Render map feature into graphic object IlvGraphic graphic = renderer.makeGraphic(feature,null); // Add this object on the first layer of the manager manager.addObject(graphic, 0, false); feature = reader.getNextFeature(); }
IlvDXFDataSource
:String DXFpath = " C:/maps/DXF_0606_ed8/DXFT"; IlvDXFDataSource source = new IlvDXFDataSource(DXFpath);
source.setManager(manager);
source.setDestinationBounds(lonMinRad,latMinRad,lonMaxRad,latMaxRad);
source.start();