|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectilog.views.maps.format.kml.IlvKMLReader
public class IlvKMLReader
A reader for KML files. Example of use:
IlvKMLReader r = new IlvKMLReader(fileName); IlvCoordinateSystem cs = IlvCoordinateSystemProperty.GetCoordinateSystem(manager); r.setTransformation(IlvCoordinateTransformation.CreateTransformation(cs,IlvGeographicCoordinateSystem.KERNEL));
| Constructor Summary | |
|---|---|
IlvKMLReader(IlvInputStream stream)
Reconstructs a KML reader from parameters read from an input stream. |
|
IlvKMLReader(String fileName)
Creates a new KML reader. |
|
IlvKMLReader(URL url)
Creates a new KML reader. |
|
| Method Summary | |
|---|---|
IlvMapRegionOfInterestIterator |
deriveReader(IlvFeatureClassInformation vfeatureClass,
IlvGeometryClassFilter vgeometryClass)
Builds a specific reader to read filtered features. |
void |
dispose()
Releases the resources allocated by the feature iterator (files, connections, and so on). |
IlvCoordinateSystem |
getCoordinateSystem()
Returns the spatial reference system that describes the coordinate system of geometric coordinates of the map features. |
IlvFeatureRenderer |
getDefaultFeatureRenderer()
Returns a renderer that can be used to translate the map features returned by this iterator into graphic objects. |
Rectangle2D |
getLatLonBounds()
Returns the latitude/longitude bounds for the list of all geometries or null if such is not available. |
IlvCoordinate |
getLowerRightCorner()
Returns the lower right corner of the rectangle containing all the map feature of the list, or null
if the iterator cannot provide this information. |
IlvMapFeature |
getNextFeature()
Returns the next map feature of the iterator or null if the iteration is finished. |
IlvCoordinateTransformation |
getTransformation()
Returns the transformation used to read in images from the KML. |
IlvCoordinate |
getUpperLeftCorner()
Returns the upper left corner of the rectangle containing all the map features of the list, or null
if the iterator cannot provide this information. |
boolean |
isGeoreferenced()
Returns true if the map reader can provide the
source projection of its map features. |
void |
restart()
Rewinds the iterator for a new use. |
void |
setFeatureClassFilter(IlvFeatureClassInformation vfeatureClass)
Sets a filter on the KML folder. |
void |
setGeometryClassFilter(IlvGeometryClassFilter vgeometryClass)
Sets a filter on the geometry class. |
void |
setRegionOfInterest(double minX,
double minY,
double maxX,
double maxY)
Sets the region of interest to return features for. |
void |
write(IlvOutputStream stream)
Writes the attributes of a persistent object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IlvKMLReader(URL url)
url - The path pointing to the KML files (.kml or .kmz).
public IlvKMLReader(String fileName)
throws MalformedURLException
fileName - The path pointing to the KML files (.kml or .kmz).
MalformedURLException - if the fileName is an unrecognized file.public IlvKMLReader(IlvInputStream stream)
stream - The stream to read from.| Method Detail |
|---|
public void write(IlvOutputStream stream)
throws IOException
write in interface IlvPersistentObjectstream - the output stream
IOException - thrown when an exception occurs during
the write operation for this object.IlvPersistentObject.write(ilog.views.io.IlvOutputStream)public void restart()
restart in interface IlvMapReusableFeatureIteratorIlvMapReusableFeatureIterator.restart()public IlvMapFeature getNextFeature()
null if the iteration is finished.
The returned map feature must be considered as volatile and
can be modified by the reader during the next call to its
getNextFeature function.
getNextFeature in interface IlvMapFeatureIteratorIlvMapFeatureIterator.getNextFeature()public IlvCoordinateTransformation getTransformation()
public boolean isGeoreferenced()
true if the map reader can provide the
source projection of its map features.
isGeoreferenced in interface IlvMapFeatureIteratorIlvMapFeatureIterator.isGeoreferenced()public IlvCoordinateSystem getCoordinateSystem()
getCoordinateSystem in interface IlvMapFeatureIteratornull
if the coordinate system is unknown.IlvMapFeatureIterator.getCoordinateSystem()public IlvCoordinate getUpperLeftCorner()
null
if the iterator cannot provide this information.
getUpperLeftCorner in interface IlvMapFeatureIteratorIlvMapFeatureIterator.getUpperLeftCorner()public IlvCoordinate getLowerRightCorner()
null
if the iterator cannot provide this information.
getLowerRightCorner in interface IlvMapFeatureIteratorIlvMapFeatureIterator.getLowerRightCorner()public IlvFeatureRenderer getDefaultFeatureRenderer()
getDefaultFeatureRenderer in interface IlvMapFeatureIteratorIlvMapFeatureIterator.getDefaultFeatureRenderer()public void dispose()
dispose in interface IlvMapFeatureIteratorIlvMapFeatureIterator.dispose()
public IlvMapRegionOfInterestIterator deriveReader(IlvFeatureClassInformation vfeatureClass,
IlvGeometryClassFilter vgeometryClass)
vfeatureClass - The feature type filter.vgeometryClass - The geometry filter.
public void setFeatureClassFilter(IlvFeatureClassInformation vfeatureClass)
vfeatureClass - Information on the feature to filter.public void setGeometryClassFilter(IlvGeometryClassFilter vgeometryClass)
vgeometryClass - Information on the accepted geometries.
public void setRegionOfInterest(double minX,
double minY,
double maxX,
double maxY)
IlvMapFeatureIterator.getNextFeature() method should not return any feature which geometry is outside this area.
setRegionOfInterest in interface IlvMapRegionOfInterestIteratorminX - longitude min in radians.minY - latitude min in radians.maxX - longitude max in radians.maxY - latitude max in radians.IlvMapRegionOfInterestIterator.setRegionOfInterest(double, double, double, double)public Rectangle2D getLatLonBounds()
getLatLonBounds in interface IlvMapRegionOfInterestIteratorIlvMapRegionOfInterestIterator.getLatLonBounds()
|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||