org.mapfish.print.map.readers
Class TileCacheLayerInfo

java.lang.Object
  extended by org.mapfish.print.map.readers.TileCacheLayerInfo
Direct Known Subclasses:
OsmLayerInfo

public class TileCacheLayerInfo
extends java.lang.Object

Holds the information we need to manage a tilecache layer.


Nested Class Summary
static class TileCacheLayerInfo.ResolutionInfo
           
 
Field Summary
protected  java.lang.String extension
           
protected static java.util.regex.Pattern FORMAT_REGEXP
           
protected  int height
           
protected  float maxX
           
protected  float maxY
           
protected  float minX
           
protected  float minY
           
protected static double RESOLUTION_TOLERANCE
          Tolerance we accept when trying to determine the nearest resolution.
protected  float[] resolutions
           
protected static java.util.regex.Pattern RESOLUTIONS_REGEXP
           
protected  int width
           
 
Constructor Summary
TileCacheLayerInfo(PJsonArray resolutions, int width, int height, float minX, float minY, float maxX, float maxY, java.lang.String extension)
           
TileCacheLayerInfo(java.lang.String resolutions, int width, int height, float minX, float minY, float maxX, float maxY, java.lang.String format)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 java.lang.String getExtension()
           
 int getHeight()
           
 float getMaxY()
           
 float getMinX()
           
 float getMinY()
           
 TileCacheLayerInfo.ResolutionInfo getNearestResolution(float targetResolution)
           
 float[] getResolutions()
           
 int getWidth()
           
 boolean isVisible(float x1, float y1, float x2, float y2)
          Receives the extent of a tile and checks that tilecache has it.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOLUTION_TOLERANCE

protected static final double RESOLUTION_TOLERANCE
Tolerance we accept when trying to determine the nearest resolution.

See Also:
Constant Field Values

FORMAT_REGEXP

protected static final java.util.regex.Pattern FORMAT_REGEXP

RESOLUTIONS_REGEXP

protected static final java.util.regex.Pattern RESOLUTIONS_REGEXP

width

protected final int width

height

protected final int height

resolutions

protected final float[] resolutions

minX

protected final float minX

minY

protected final float minY

maxX

protected final float maxX

maxY

protected final float maxY

extension

protected java.lang.String extension
Constructor Detail

TileCacheLayerInfo

public TileCacheLayerInfo(java.lang.String resolutions,
                          int width,
                          int height,
                          float minX,
                          float minY,
                          float maxX,
                          float maxY,
                          java.lang.String format)

TileCacheLayerInfo

public TileCacheLayerInfo(PJsonArray resolutions,
                          int width,
                          int height,
                          float minX,
                          float minY,
                          float maxX,
                          float maxY,
                          java.lang.String extension)
Method Detail

getWidth

public int getWidth()

getHeight

public int getHeight()

getNearestResolution

public TileCacheLayerInfo.ResolutionInfo getNearestResolution(float targetResolution)

getResolutions

public float[] getResolutions()

getExtension

public java.lang.String getExtension()

getMinX

public float getMinX()

getMinY

public float getMinY()

getMaxY

public float getMaxY()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

isVisible

public boolean isVisible(float x1,
                         float y1,
                         float x2,
                         float y2)
Receives the extent of a tile and checks that tilecache has it.


equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object


Copyright © 2009 Camptocamp SA. All Rights Reserved.