Package org.openstreetmap.josm.gui.layer
Class NativeScaleLayer.Scale
- java.lang.Object
-
- org.openstreetmap.josm.gui.layer.NativeScaleLayer.Scale
-
- Enclosing interface:
- NativeScaleLayer
public static class NativeScaleLayer.Scale extends java.lang.Object
Represents a scale with native flag, used inNativeScaleLayer.ScaleList
-
-
Field Summary
Fields Modifier and Type Field Description private intindexprivate booleanisNativeTrue if this scale is native resolution for data source.private doublescaleScale factor, same unit as inNavigatableComponent
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetIndex()Get index of this scale in aNativeScaleLayer.ScaleListdoublegetScale()java.lang.StringtoString()
-
-
-
Field Detail
-
scale
private final double scale
Scale factor, same unit as inNavigatableComponent
-
isNative
private final boolean isNative
True if this scale is native resolution for data source.
-
index
private final int index
-
-
Constructor Detail
-
Scale
public Scale(double scale, int index)
Constructs a new Scale with given scale, native defaults to true.- Parameters:
scale- as defined in WMTS (scaleDenominator)index- zoom index for this scale
-
Scale
public Scale(double scale, boolean isNative, int index)
Constructs a new Scale with given scale, native and index values.- Parameters:
scale- as defined in WMTS (scaleDenominator)isNative- is this scale native to the source or notindex- zoom index for this scale
-
-
Method Detail
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getIndex
public int getIndex()
Get index of this scale in aNativeScaleLayer.ScaleList- Returns:
- index
-
getScale
public double getScale()
-
-