com.partnersoft.maps.nomenclature
Class GridMapNomenclature

java.lang.Object
  extended by com.partnersoft.maps.nomenclature.GridMapNomenclature
All Implemented Interfaces:
Coggable, MapNomenclature

public class GridMapNomenclature
extends java.lang.Object
implements MapNomenclature

Translates map coordinates into grid system coordinates.

Version:
1.0 time to go home, 9/25/97 Copyright 1997 Partner Software, Inc.
Author:
Paul Reavis

Constructor Summary
GridMapNomenclature()
          Create a new, empty GridMapTranslator.
GridMapNomenclature(GridSystem system)
          Create a GridMapTranslator for the given GridSystem.
 
Method Summary
 Point coordFor(java.lang.String locationName)
          Returns the Sheet Pixel Coordinate for the center of the given customer map location.
 java.util.ArrayList getGridToScaleLevel()
           
 java.util.ArrayList getScaleToGridLevel()
           
 Cog getState()
           
 GridSystem getSystem()
          GridSystem used for the translation (shrug).
 java.lang.String nameFor(Point coord)
          Returns the customer's map location name for the given point.
 java.lang.String nameFor(Point coords, int scale)
          Returns the customer's map location name for the given coordinate at the given scale.
 int scaleFor(java.lang.String locationName)
          Returns the scale index for the given customer map location name.
 void setGridToScaleLevel(java.util.ArrayList newMapping)
           
 void setScaleToGridLevel(java.util.ArrayList newMapping)
           
 void setState(Cog newState)
           
 void setSystem(GridSystem newSystem)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GridMapNomenclature

public GridMapNomenclature()
Create a new, empty GridMapTranslator.


GridMapNomenclature

public GridMapNomenclature(GridSystem system)
Create a GridMapTranslator for the given GridSystem.

Method Detail

nameFor

public java.lang.String nameFor(Point coords,
                                int scale)
Returns the customer's map location name for the given coordinate at the given scale.

Specified by:
nameFor in interface MapNomenclature

nameFor

public java.lang.String nameFor(Point coord)
Returns the customer's map location name for the given point.

Specified by:
nameFor in interface MapNomenclature

coordFor

public Point coordFor(java.lang.String locationName)
Returns the Sheet Pixel Coordinate for the center of the given customer map location.

Specified by:
coordFor in interface MapNomenclature

scaleFor

public int scaleFor(java.lang.String locationName)
Description copied from interface: MapNomenclature
Returns the scale index for the given customer map location name.

Specified by:
scaleFor in interface MapNomenclature

getState

public Cog getState()
Specified by:
getState in interface Coggable

setState

public void setState(Cog newState)
Specified by:
setState in interface Coggable

getSystem

public GridSystem getSystem()
GridSystem used for the translation (shrug).


setSystem

public void setSystem(GridSystem newSystem)

getScaleToGridLevel

public java.util.ArrayList getScaleToGridLevel()

setScaleToGridLevel

public void setScaleToGridLevel(java.util.ArrayList newMapping)

getGridToScaleLevel

public java.util.ArrayList getGridToScaleLevel()

setGridToScaleLevel

public void setGridToScaleLevel(java.util.ArrayList newMapping)