public abstract class AbstractModifiableLayer extends Layer
Layer.LayerAction, Layer.LayerGpxExportAction, Layer.LayerSaveAction, Layer.LayerSaveAsAction, Layer.MultiLayerAction, Layer.SeparatorLayerAction
ICON_SIZE, NAME_PROP, OPACITY_PROP, propertyChangeSupport, VISIBLE_PROP
Constructor and Description |
---|
AbstractModifiableLayer(java.lang.String name)
Constructs a new
ModifiableLayer . |
Modifier and Type | Method and Description |
---|---|
AbstractIOTask |
createUploadTask(ProgressMonitor monitor)
Creates a new
AbstractIOTask for uploading data. |
AbstractUploadDialog |
getUploadDialog()
Returns the upload dialog for this layer.
|
abstract boolean |
isModified()
Determines if data managed by this layer has been modified.
|
boolean |
isUploadDiscouraged()
Determines if upload of data managed by this layer is discouraged.
|
void |
onPostSaveToFile()
Initializes the layer after a successful save of data to a file.
|
void |
onPostUploadToServer()
Initializes the layer after a successful upload to the server.
|
boolean |
requiresSaveToFile()
Determines if the data managed by this layer needs to be saved to
a file.
|
boolean |
requiresUploadToServer()
Determines if the data managed by this layer needs to be uploaded to
the server because it contains modified data.
|
addPropertyChangeListener, checkSaveConditions, createAndOpenSaveFileChooser, destroy, fireOpacityChanged, fireVisibleChanged, getAssociatedFile, getColor, getIcon, getInfoComponent, getMenuEntries, getName, getOpacity, getToolTipText, hookUpMapView, isBackgroundLayer, isChanged, isInfoResizable, isMergable, isProjectionSupported, isSavable, isVisible, mergeFrom, nameSupportedProjections, onPostLoadFromFile, paint, projectionChanged, removePropertyChangeListener, setAssociatedFile, setBackgroundLayer, setName, setOpacity, setVisible, toggleVisible, visitBoundingBox
public AbstractModifiableLayer(java.lang.String name)
ModifiableLayer
.name
- Layer namepublic boolean requiresUploadToServer()
public boolean requiresSaveToFile()
public boolean isUploadDiscouraged()
public abstract boolean isModified()
public void onPostSaveToFile()
public void onPostUploadToServer()
public AbstractIOTask createUploadTask(ProgressMonitor monitor)
AbstractIOTask
for uploading data.monitor
- The progress monitorAbstractIOTask
for uploading data, or null
if not applicablepublic AbstractUploadDialog getUploadDialog()
null
if not applicable