public interface IUnsavedData
This interface represents some unsaved data, associated to one extension. There are methods to get the associated extension, to get info about these data, to get the type of the data and a suitable icon for this type, and a method to save the data.
It is used during the Andami termination process, to construct the dialog of unsaved data, although it can be used at any time.
Normally, it should not be directly implemented, use the convenience UnsavedData class.
IExtensionStatus
,
UnsavedData
,
IExtension
Modifier and Type | Method and Description |
---|---|
String |
getDescription()
Gets a description of this unsaved data.
|
IExtension |
getExtension()
Each IUnsavedData object is associated with one extension, which is
in charge of this data.
|
String |
getIcon()
Gets an icon suitable to represent this type of data.
|
String |
getResourceName()
Gets the resource name of this unsaved data.
|
boolean |
saveData()
Save the existing changes for this resource (for example, save the layer
to disk or to the database, etc).
|
String getResourceName()
String getDescription()
Gets a description of this unsaved data. This would be combined with the resource name to show a coherent information to the user.
Examples of descriptions:
boolean saveData()
Save the existing changes for this resource (for example, save the layer
to disk or to the database, etc). The resource should not be closed at this
point (files, database connections, etc should no be closed), as they may
be still needed by other extensions. Resources should be closed at
IExtension.terminate()
.
IExtension getExtension()
String getIcon()