public class WMTSProvider extends AbstractRasterProvider implements RemoteRasterProvider, TiledRasterProvider
| Modifier and Type | Class and Description |
|---|---|
class |
WMTSProvider.PointInfo
Point information
|
class |
WMTSProvider.RequestThreadManager
This thread manages the number of tiles that have been thrown.
|
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DESCRIPTION |
static int |
LIMITED_THREADS |
static java.lang.String |
METADATA_DEFINITION_NAME |
static java.lang.String |
NAME |
static int |
SEQUENTIAL |
static boolean |
TILED |
static int |
UNLIMITED_THREADS |
ALPHA_BAND, bandCount, BLUE_BAND, bytesReaded, colorTable, externalTransformation, fileSize, fileUtil, geoPointList, GREEN_BAND, histogram, lineCnt, noData, ownTransformation, param, proj, rasterUtil, RED_BAND, rmfBlocksManager, selectedSubdatasetID, serialInfo, stats, storeServices, tileServer, transparency, urimetadata, parameters, store| Constructor and Description |
|---|
WMTSProvider() |
WMTSProvider(java.lang.String params)
Deprecated.
use
WMTSProvider(URI), this constructor will be removed in gvSIG 2.5 |
WMTSProvider(java.net.URI uri)
Constructor.
|
WMTSProvider(WMTSDataParameters params,
DataStoreProviderServices storeServices) |
| Modifier and Type | Method and Description |
|---|---|
void |
addFile(java.io.File file)
Adds a new file.
|
WMTSStatus |
buildWMTSStatus(java.awt.geom.Rectangle2D r,
int bufWidth,
int bufHeight)
Builds the WMTSStatus object using the parameters and the request bounding box.
|
void |
close()
Request to close de source
|
java.awt.geom.AffineTransform |
getAffineTransform()
Obtiene la transformación afin aplicada en las peticiones con coordenadas
reales.
|
int |
getBlockSize() |
Buffer |
getBuffer(Buffer rasterBuf,
BandList bandList,
java.io.File lastFile,
double ulx,
double uly,
double lrx,
double lry)
Assigns the list of bands RGB and read a window of data
|
Buffer |
getBufferLastRequest()
Gets the buffer of the last request.
|
ColorInterpretation |
getColorInterpretation()
Obtiene el objeto que contiene que contiene la interpretación de
color por banda
|
Extent |
getCoordsInLevel(java.awt.geom.Point2D viewCenter,
int level,
int w,
int h)
Calculates the extent of a zoom level using a center.
|
Extent |
getCoordsInTheNearestLevel(Extent extent,
int w,
int h)
Calculates the extent of a zoom level using other extent as a reference.
|
java.lang.Object |
getData(int x,
int y,
int band)
Obtiene el valor del raster en la coordenada que se le pasa.
|
Extent |
getExtent()
Gets the bounding box in world coordinates.
|
Extent[] |
getExtentByResolutionLevel()
When a layer doesn't have grid subsets this will have a different bounding
box by resolution level.
|
java.lang.String |
getFeatureInfo(double wcx,
double wcy,
int level)
Gets the information from a point
|
java.io.File |
getFileLayer()
When the remote layer has fixed size this method downloads the file and return its reference.
|
java.lang.String |
getFileSuffix()
Gets the suffix of the downloaded image
|
double |
getHeight()
Obtiene el ancho de la imagen
|
HistogramComputer |
getHistogramComputer()
Gets the object which computes the histogram
|
java.awt.Image |
getImageLegend()
Gets the legend as a image.
|
java.lang.String |
getInfoByPoint(int x,
int y,
Extent bbox,
int w,
int h,
ICancellable cancellable)
Gets the information in a pixel point.
|
RasterProvider |
getInternalProvider()
Gets the internal provider used to feed the TileProvider
|
java.io.File |
getLastRequest()
Gets the file of the last request.
|
java.awt.geom.Rectangle2D |
getLayerExtent(java.lang.String layerName,
java.lang.String srs)
Gets the bounding box of this layer
|
int |
getLevelFromRealCoords(java.awt.geom.Rectangle2D r,
int width)
Gets the resolution level from the real coordinates
|
int |
getLevelFromScale(double scale,
WMTSTileMatrixSet tileMatrixSet)
Gets the resolution level from the scale
|
java.lang.String |
getName()
Returns the name associated to the provider.
|
int |
getNearestLevel(double pixelSize)
Gets the nearest level to the selected pixel size
|
NoData |
getNoDataValue()
Gets the nodata value.
|
WMTSClient |
getOGCClient()
Gets the connector from the URL
|
int |
getOverviewCount(int band)
Obtiene el número de overviews de una banda
|
int |
getOverviewHeight(int band,
int overview)
Obtiene el alto de una overview de una banda
|
int |
getOverviewWidth(int band,
int overview)
Obtiene el ancho de una overview de una banda
|
WMTSDataParameters |
getParameters() |
double[] |
getPixelSizeByLevel()
Returns a list of pixel sizes by level
|
IProjection |
getProjection()
Sets the provider projection
|
java.lang.String |
getProviderName()
Return the name of the provider.
|
java.lang.String |
getSRSCode()
Gets the srs code
|
Tile |
getTile(SpiRasterQuery q)
Gets a tile
|
WMTSTileMatrixSetLink |
getTileMatrixSetLink()
Get the tile matrix set using the crs
|
TileServer |
getTileServer()
Gets the tile cache data server
|
int[] |
getTileSize(int level)
Returns the tile size in pixels if this providers have tiles
|
Transparency |
getTransparency()
Obtiene el estado de transparencia a partir de los estados de transparencia de todos
los ficheros que lo componen.
|
Extent |
getView()
Obtiene el extent asignado
|
double |
getWidth()
Obtiene el ancho de la imagen
|
Extent |
getZoomLevelCoordinates(int level,
Extent extent,
int w,
int h)
Calculates the extent of a zoom level using other extent as a reference.
|
int |
getZoomLevels()
Returns the number of levels
|
boolean |
hasGridSubsets()
Returns true if this layer has grid subsets
|
void |
init(DataStoreParameters params,
DataStoreProviderServices storeServices)
Crea las referencias al fichero y carga
las estructuras con la información y los metadatos.
|
boolean |
isOpen()
Returns true if this provider is open and false if don't
|
boolean |
isOverviewsSupported()
Informa de si el dataset soporta overviews o no.
|
boolean |
isRasterEnclosed()
Some services neither has limits nor pixel size.
|
boolean |
isReproyectable()
Devuelve si el Dataset es reproyectable
|
boolean |
isTiled()
Returns true if the provider support tiles
|
RasterProvider |
load()
Carga un fichero raster.
|
void |
loadBuffer(SpiRasterQuery q)
Load a buffer with the parameters.
|
java.awt.geom.Point2D |
rasterToWorld(java.awt.geom.Point2D pt)
Convierte un punto desde coordenadas pixel a coordenadas del mundo.
|
java.lang.Object |
readBlock(int pos,
int blockHeight,
double scale)
Reads a complete block of data and returns an tridimensional array of the right type.
|
java.lang.Object |
readCompleteLine(int line,
int band) |
static void |
register() |
void |
removeFile(java.io.File file)
Removes a file.
|
void |
setAffineTransform(java.awt.geom.AffineTransform t)
Asigna una transformación al raster para que se tenga en cuenta en la
asignación del setView.
|
void |
setParam(DataStoreProviderServices storeServices,
DataStoreParameters param)
ASigna el parámetro de inicialización del driver.
|
void |
setStatus(RasterProvider provider)
Sets the status information using other provider of the same type.
|
void |
setView(Extent e)
Asigna un nuevo Extent
|
java.net.URI |
translateURI(java.net.URI uri)
Traduce el nombre del fichero por un alias asignado por el propio driver.
|
java.awt.geom.Point2D |
worldToRaster(java.awt.geom.Point2D pt)
Convierte un punto desde del mundo a coordenadas pixel.
|
cloneProvider, deleteLayerFromCache, doDispose, finalize, getBandCount, getBandCountByProvider, getBandPositionByProvider, getCellSize, getChildren, getChilds, getColorTable, getDataParameters, getDataSet, getDataType, getDefaultBandList, getExplorer, getExtentWithoutRot, getFileSize, getFileSizeByProvider, getFormatList, getFullName, getGeoPointList, getInfoByPoint, getInternalProvider, getInternalProviderCount, getInterval, getMetadata, getOwnAffineTransform, getPixelSizeX, getPixelSizeY, getResource, getResourcesStorage, getRmfBlocksManager, getRMFFile, getRMFFileForRemoteServices, getSourceId, getSourceType, getStatistics, getStoresRepository, getSubdatasetCount, getTime, getTimes, getTimes, getTimeSerials, getURI, getURIByBand, getURIByProvider, getURIOfFirstProvider, getWktProjection, init, isARGB, isGeoreferenced, isInside, isMosaic, isMultiFile, isRGB, isRotated, isTimeSupported, loadFromRmf, loadObjectFromRmf, loadObjectFromRmf, loadObjectFromRmfFile, needEnhanced, newProvider, open, reload, resetAffineTransform, saveObjectToRmf, saveObjectToRmf, selectSubdataset, selectSubdataset, setColorInterpretation, setColorTable, setDataType, setFileSize, setFName, setGeoPointList, setNoDataValue, setProjection, setStatistics, setTileServer, setTimeSerials, singleDatasetInstance, translateFileNameallowWrite, clear, createCoverageSelection, createResource, delegate, getClassName, getDataStoreParameters, getDynClass, getDynValue, getEnvelope, getStoreServices, hasDynMethod, hasDynValue, implement, init, invokeDynMethod, invokeDynMethod, refresh, setDynValue, setMetadatasetTransactiondispose, disposeclone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcloneProvider, deleteLayerFromCache, getBandCount, getBandCountByProvider, getBandPositionByProvider, getCellSize, getColorTable, getDataParameters, getDataSet, getDataType, getExtentWithoutRot, getFileSizeByProvider, getFormatList, getGeoPointList, getInfoByPoint, getInternalProvider, getInternalProviderCount, getMetadata, getOwnAffineTransform, getPixelSizeX, getPixelSizeY, getRMFFile, getSourceType, getStatistics, getSubdatasetCount, getTimeSerials, getURI, getURIByBand, getURIByProvider, getURIOfFirstProvider, getWktProjection, isGeoreferenced, isInside, isMosaic, isMultiFile, isRotated, isTimeSupported, loadObjectFromRmf, needEnhanced, reload, saveObjectToRmf, selectSubdataset, setColorInterpretation, setColorTable, setGeoPointList, setNoDataValue, setProjection, setStatistics, setTimeSerialsallowWrite, getStoreServicesgetChildren, getExplorer, getFullName, getInterval, getResource, getResourcesStorage, getSourceId, getStoresRepository, getTimes, getTimes, open, refresh, setTransactionhasDynMethodclear, clone, delegate, getDynClass, getDynValue, hasDynValue, implement, invokeDynMethod, invokeDynMethod, setDynValuedisposesetTileServerpublic static java.lang.String NAME
public static java.lang.String DESCRIPTION
public static final java.lang.String METADATA_DEFINITION_NAME
public static boolean TILED
public static int SEQUENTIAL
public static int LIMITED_THREADS
public static int UNLIMITED_THREADS
public WMTSProvider()
throws NotSupportedExtensionException
NotSupportedExtensionExceptionpublic WMTSProvider(java.lang.String params)
throws NotSupportedExtensionException,
OpenException
WMTSProvider(URI), this constructor will be removed in gvSIG 2.5proj - ProyecciónfName - Nombre del ficheroNotSupportedExtensionExceptionOpenExceptionpublic WMTSProvider(java.net.URI uri)
throws NotSupportedExtensionException
uri - URI del ficheroNotSupportedExtensionExceptionpublic WMTSProvider(WMTSDataParameters params, DataStoreProviderServices storeServices) throws NotSupportedExtensionException
NotSupportedExtensionExceptionpublic static void register()
public WMTSClient getOGCClient() throws WMTSException
RemoteServiceExceptionWMTSExceptionpublic void init(DataStoreParameters params, DataStoreProviderServices storeServices) throws NotSupportedExtensionException
proj - Proyecciónparam - Parametros de cargaNotSupportedExtensionExceptionpublic boolean hasGridSubsets()
public ColorInterpretation getColorInterpretation()
getColorInterpretation in interface RasterProvidergetColorInterpretation in class AbstractRasterProviderpublic boolean isTiled()
RasterProviderisTiled in interface RasterProviderisTiled in class AbstractRasterProviderpublic java.awt.geom.AffineTransform getAffineTransform()
RasterProvidergetAffineTransform in interface RasterProvidergetAffineTransform in class AbstractRasterProviderpublic Extent getExtent()
Gets the bounding box in world coordinates. If the layer has defined the BoundingBox tag, we will take this bounding box as entire extension of this layer, else we'll see if the tag WGS84BoundingBox is defined (it can be approximated). In this case we'll take WGS84BoundingBox as entire extension.
If the layer has grid subsets (TileMatrixLimits) then this will have a only extent but if the layer doesn't have grid subsets then this will have a different extent in each level resolution. In this case we need to know the extent for each level.
getExtent in interface RasterProvidergetExtent in class AbstractRasterProviderpublic java.lang.String getFileSuffix()
getFileSuffix in interface RasterProvidergetFileSuffix in class AbstractRasterProviderpublic Extent[] getExtentByResolutionLevel()
public java.awt.geom.Rectangle2D getLayerExtent(java.lang.String layerName,
java.lang.String srs)
throws RemoteServiceException
RemoteRasterProvidergetLayerExtent in interface RemoteRasterProviderRemoteServiceExceptionpublic RasterProvider load()
AbstractRasterProviderload in class AbstractRasterProviderpublic boolean isOpen()
RasterProviderisOpen in interface RasterProviderpublic void close()
DataStoreProviderclose in interface RasterProviderclose in class AbstractRasterProviderpublic Transparency getTransparency()
RasterProvidergetTransparency in interface RasterProvidergetTransparency in class AbstractRasterProviderpublic NoData getNoDataValue()
RasterProvidergetNoDataValue in interface RasterProvidergetNoDataValue in class AbstractRasterProviderpublic java.net.URI translateURI(java.net.URI uri)
AbstractRasterProvidertranslateURI in class AbstractRasterProviderpublic void setView(Extent e)
AbstractRasterProvidersetView in class AbstractRasterProvidere - Extentpublic Extent getView()
AbstractRasterProvidergetView in interface RasterProvidergetView in class AbstractRasterProviderpublic double getWidth()
AbstractRasterProvidergetWidth in interface RasterProvidergetWidth in class AbstractRasterProviderpublic double getHeight()
AbstractRasterProvidergetHeight in interface RasterProvidergetHeight in class AbstractRasterProviderpublic java.lang.Object readCompleteLine(int line,
int band)
throws InvalidSetViewException,
FileNotOpenException,
RasterDriverException
public java.io.File getFileLayer()
throws RasterDriverException
getFileLayer in interface RemoteRasterProviderRasterDriverExceptionpublic java.lang.Object readBlock(int pos,
int blockHeight,
double scale)
throws InvalidSetViewException,
FileNotOpenException,
RasterDriverException,
ProcessInterruptedException
readBlock in interface RasterProviderpos - Posición donde se empieza a leerblockHeight - Altura máxima del bloque leidoInvalidSetViewExceptionFileNotOpenExceptionRasterDriverExceptionProcessInterruptedExceptionpublic java.lang.Object getData(int x,
int y,
int band)
throws InvalidSetViewException,
FileNotOpenException,
RasterDriverException
AbstractRasterProvidergetData in interface RasterProvidergetData in class AbstractRasterProviderx - coordenada Xy - coordenada YInvalidSetViewExceptionFileNotOpenExceptionRasterDriverExceptionpublic Buffer getBuffer(Buffer rasterBuf, BandList bandList, java.io.File lastFile, double ulx, double uly, double lrx, double lry) throws RasterDriverException, ProcessInterruptedException
rasterBuf - bandList - lastFile - ulx - uly - lrx - lry - RasterDriverExceptionProcessInterruptedExceptionpublic int getZoomLevels()
getZoomLevels in interface TiledRasterProviderpublic Extent getCoordsInTheNearestLevel(Extent extent, int w, int h)
TiledRasterProvidergetCoordsInTheNearestLevel in interface TiledRasterProviderpublic Extent getCoordsInLevel(java.awt.geom.Point2D viewCenter, int level, int w, int h)
TiledRasterProvidergetCoordsInLevel in interface TiledRasterProviderpublic Extent getZoomLevelCoordinates(int level, Extent extent, int w, int h)
level - extent - w - h - public double[] getPixelSizeByLevel()
public Tile getTile(SpiRasterQuery q) throws TileGettingException
TiledRasterProvidergetTile in interface TiledRasterProviderTileGettingExceptionpublic void loadBuffer(SpiRasterQuery q) throws ProcessInterruptedException, RasterDriverException
AbstractRasterProviderSpiRasterQuery by the RasterDataStore. The other
parameters have been calculated too, all of them adjusted to the raster limits. The provider only
have to read the parameters and load the buffer.loadBuffer in class AbstractRasterProviderProcessInterruptedExceptionRasterDriverExceptionpublic java.lang.String getFeatureInfo(double wcx,
double wcy,
int level)
throws RasterDriverException
wcx - wcy - level - RasterDriverExceptionpublic WMTSStatus buildWMTSStatus(java.awt.geom.Rectangle2D r, int bufWidth, int bufHeight) throws RasterDriverException
r - bufWidth - RasterDriverExceptionpublic int getLevelFromRealCoords(java.awt.geom.Rectangle2D r,
int width)
throws RasterDriverException
r - RasterDriverExceptionpublic int getLevelFromScale(double scale,
WMTSTileMatrixSet tileMatrixSet)
throws RasterDriverException
scale - tileMatrixSet - RasterDriverExceptionpublic WMTSTileMatrixSetLink getTileMatrixSetLink()
srs - public java.awt.Image getImageLegend()
RasterProvidergetImageLegend in interface RasterProvidergetImageLegend in class AbstractRasterProviderpublic int getBlockSize()
getBlockSize in class AbstractRasterProviderpublic void setAffineTransform(java.awt.geom.AffineTransform t)
RasterProvidersetAffineTransform in interface RasterProvidersetAffineTransform in class AbstractRasterProvidert - Transformación afín a aplicarpublic int getOverviewCount(int band)
throws BandAccessException,
RasterDriverException
RasterProvidergetOverviewCount in interface RasterProviderBandAccessExceptionRasterDriverExceptionpublic int getOverviewWidth(int band,
int overview)
throws BandAccessException,
RasterDriverException
RasterProvidergetOverviewWidth in interface RasterProvidergetOverviewWidth in class AbstractRasterProviderBandAccessExceptionRasterDriverExceptionpublic int getOverviewHeight(int band,
int overview)
throws BandAccessException,
RasterDriverException
RasterProvidergetOverviewHeight in interface RasterProvidergetOverviewHeight in class AbstractRasterProviderBandAccessExceptionRasterDriverExceptionpublic boolean isOverviewsSupported()
AbstractRasterProviderisOverviewsSupported in interface RasterProviderisOverviewsSupported in class AbstractRasterProviderpublic boolean isReproyectable()
AbstractRasterProviderisReproyectable in interface RasterProviderisReproyectable in class AbstractRasterProviderpublic java.lang.String getProviderName()
DataStoreProvidergetProviderName in interface CoverageStoreProviderpublic java.lang.String getName()
DataStoreProvidergetName in class AbstractRasterProviderpublic WMTSDataParameters getParameters()
public java.awt.geom.Point2D rasterToWorld(java.awt.geom.Point2D pt)
rasterToWorld in interface RasterProviderrasterToWorld in class AbstractRasterProviderpt - Punto a transformarpublic java.awt.geom.Point2D worldToRaster(java.awt.geom.Point2D pt)
worldToRaster in interface RasterProviderworldToRaster in class AbstractRasterProviderpt - Punto a transformarpublic void setStatus(RasterProvider provider)
RasterProvidersetStatus in interface RasterProviderpublic java.io.File getLastRequest()
RemoteRasterProvidergetLastRequest in interface RemoteRasterProviderpublic void setParam(DataStoreProviderServices storeServices, DataStoreParameters param)
setParam in class AbstractRasterProviderpublic java.lang.String getInfoByPoint(int x,
int y,
Extent bbox,
int w,
int h,
ICancellable cancellable)
throws InfoByPointException
RasterProvidergetInfoByPoint in interface RasterProvidergetInfoByPoint in class AbstractRasterProviderx - X Pixel positiony - Y pixel positionbbox - Bounding box of the windoww - Width in pixels of the windowh - Height in pixels of the windowInfoByPointExceptionpublic int getNearestLevel(double pixelSize)
TiledRasterProvidergetNearestLevel in interface TiledRasterProviderpublic TileServer getTileServer()
RasterProvidergetTileServer in interface RasterProviderpublic int[] getTileSize(int level)
TiledRasterProvidergetTileSize in interface TiledRasterProvidergetTileSize in class AbstractRasterProviderpublic boolean isRasterEnclosed()
RasterProviderisRasterEnclosed in interface RasterProviderisRasterEnclosed in class AbstractRasterProviderpublic Buffer getBufferLastRequest() throws ProcessInterruptedException, RasterDriverException
RemoteRasterProvidergetBufferLastRequest in interface RemoteRasterProviderProcessInterruptedExceptionRasterDriverExceptionpublic java.lang.String getSRSCode()
public RasterProvider getInternalProvider()
TiledRasterProvidergetInternalProvider in interface TiledRasterProviderpublic HistogramComputer getHistogramComputer()
HistogramablegetHistogramComputer in interface HistogramablegetHistogramComputer in class AbstractRasterProviderpublic void addFile(java.io.File file)
throws InvalidSourceException
RasterProvideraddFile in interface RasterProviderInvalidSourceExceptionpublic void removeFile(java.io.File file)
RasterProviderremoveFile in interface RasterProviderpublic IProjection getProjection()
RasterProvidergetProjection in interface RasterProvidergetProjection in class AbstractRasterProvider