public class CodeProjectionChoice extends AbstractProjectionChoice implements SubPrefsOptions
| Modifier and Type | Class and Description |
|---|---|
static class |
CodeProjectionChoice.CodeComparator
Comparator that compares the number part of the code numerically.
|
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
code |
id, name| Constructor and Description |
|---|
CodeProjectionChoice()
Constructs a new
CodeProjectionChoice. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String[] |
allCodes()
Return all projection codes supported by this projection choice.
|
java.lang.String |
getCurrentCode()
Returns current projection code.
|
javax.swing.JPanel |
getPreferencePanel(java.awt.event.ActionListener listener)
Generate and provide the GUI.
|
java.util.Collection<java.lang.String> |
getPreferences(javax.swing.JPanel panel)
Extract preferences from the GUI.
|
java.util.Collection<java.lang.String> |
getPreferencesFromCode(java.lang.String code)
Get Preferences from projection code.
|
Projection |
getProjection()
Get the projection that matches the internal state.
|
java.lang.String |
getProjectionName()
Returns projection name.
|
void |
setPreferences(java.util.Collection<java.lang.String> args)
Set the internal state to match the preferences.
|
boolean |
showProjectionCode() |
boolean |
showProjectionName() |
getId, toStringprivate java.lang.String code
public CodeProjectionChoice()
CodeProjectionChoice.public Projection getProjection()
ProjectionChoicegetProjection in interface ProjectionChoicegetProjection in class AbstractProjectionChoicepublic java.lang.String getCurrentCode()
AbstractProjectionChoicegetCurrentCode in class AbstractProjectionChoicepublic java.lang.String getProjectionName()
AbstractProjectionChoicegetProjectionName in class AbstractProjectionChoicepublic void setPreferences(java.util.Collection<java.lang.String> args)
ProjectionChoicesetPreferences in interface ProjectionChoiceargs - preferences as a list of strings; may be null
to reset everything.public javax.swing.JPanel getPreferencePanel(java.awt.event.ActionListener listener)
ProjectionChoicegetPreferencePanel in interface ProjectionChoicelistener - listener for any change of preferencespublic java.util.Collection<java.lang.String> getPreferences(javax.swing.JPanel panel)
ProjectionChoicegetPreferences in interface ProjectionChoicepanel - projection preferences panelProjectionChoice.setPreferences(java.util.Collection<java.lang.String>)public java.lang.String[] allCodes()
ProjectionChoiceallCodes in interface ProjectionChoicepublic java.util.Collection<java.lang.String> getPreferencesFromCode(java.lang.String code)
ProjectionChoicegetPreferencesFromCode in interface ProjectionChoicecode - projection codepublic boolean showProjectionCode()
showProjectionCode in interface SubPrefsOptionspublic boolean showProjectionName()
showProjectionName in interface SubPrefsOptions