public class UTMProjectionChoice extends ListProjectionChoice
| Modifier and Type | Class and Description |
|---|---|
static class |
UTMProjectionChoice.Hemisphere |
private class |
UTMProjectionChoice.UTMPanel |
ListProjectionChoice.CBPanel| Modifier and Type | Field and Description |
|---|---|
private static List<String> |
cbEntries |
private static UTMProjectionChoice.Hemisphere |
DEFAULT_HEMISPHERE |
private UTMProjectionChoice.Hemisphere |
hemisphere |
defaultIndex, entries, index, labelcacheDir, id, name| Constructor and Description |
|---|
UTMProjectionChoice()
Constructs a new
UTMProjectionChoice. |
| Modifier and Type | Method and Description |
|---|---|
String[] |
allCodes()
Return all projection codes supported by this projection choice.
|
String |
getCurrentCode() |
JPanel |
getPreferencePanel(ActionListener listener)
Generate and provide the GUI.
|
Collection<String> |
getPreferences(JPanel panel)
Extract preferences from the GUI.
|
Collection<String> |
getPreferencesFromCode(String code)
Get Preferences from projection code.
|
String |
getProjectionName() |
protected String |
indexToZone(int index)
Convert 0-based index to preference value.
|
void |
setPreferences(Collection<String> args)
Set the internal state to match the preferences.
|
protected int |
zoneToIndex(String zone)
Convert preference value to 0-based index.
|
getCacheDir, getId, getProjection, toStringprivate static final UTMProjectionChoice.Hemisphere DEFAULT_HEMISPHERE
private UTMProjectionChoice.Hemisphere hemisphere
public UTMProjectionChoice()
UTMProjectionChoice.public JPanel getPreferencePanel(ActionListener listener)
ProjectionChoicegetPreferencePanel in interface ProjectionChoicegetPreferencePanel in class ListProjectionChoicelistener - listener for any change of preferencespublic String getCurrentCode()
getCurrentCode in class AbstractProjectionChoicepublic String getProjectionName()
getProjectionName in class AbstractProjectionChoicepublic Collection<String> getPreferences(JPanel panel)
ProjectionChoicegetPreferences in interface ProjectionChoicegetPreferences in class ListProjectionChoicepublic String[] allCodes()
ProjectionChoicepublic Collection<String> getPreferencesFromCode(String code)
ProjectionChoicepublic void setPreferences(Collection<String> args)
ProjectionChoicesetPreferences in interface ProjectionChoicesetPreferences in class ListProjectionChoiceargs - preferences as a list of strings; may be null
to reset everything.protected String indexToZone(int index)
ListProjectionChoiceindexToZone in class ListProjectionChoiceprotected int zoneToIndex(String zone)
ListProjectionChoicezoneToIndex in class ListProjectionChoice