Package org.scijava.app
Interface App
-
- All Superinterfaces:
Comparable<Prioritized>,Contextual,HasPluginInfo,Identifiable,Locatable,Logged,Prioritized,RichPlugin,SciJavaPlugin,SingletonPlugin,Versioned
- All Known Implementing Classes:
AbstractApp,SciJavaApp
public interface App extends RichPlugin, SingletonPlugin
Metadata about a SciJava-based application, used by theAppService.Applications discoverable at runtime must implement this interface and be annotated with @
Pluginwith attributePlugin.type()=App.class. While it possible to create an application merely by implementing this interface, it is encouraged to instead extendAbstractApp, for convenience.- Author:
- Curtis Rueden
- See Also:
Plugin,AppService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidabout()Displays information about the application.StringgetArtifactId()The MavenartifactIdof the application.default FilegetBaseDirectory()Gets the application's root directory.StringgetGroupId()The MavengroupIdof the application.default StringgetInfo(boolean mem)Gets a string with information about the application.ManifestgetManifest()Gets the manifest containing metadata about the application.POMgetPOM()Gets the Maven POM containing metadata about the application.default StringgetSystemProperty()A system property which, if set, overrides the base directory of the application.default StringgetTitle()Gets the title of the application.default StringgetVersion()Gets the version of the application.default voidprefs()Displays application preferences.default voidquit()Quits the application.-
Methods inherited from interface org.scijava.Contextual
context, getContext, setContext
-
Methods inherited from interface org.scijava.plugin.HasPluginInfo
getInfo, setInfo
-
Methods inherited from interface org.scijava.Locatable
getLocation
-
Methods inherited from interface org.scijava.Prioritized
compareTo, getPriority, setPriority
-
Methods inherited from interface org.scijava.plugin.RichPlugin
getIdentifier, log
-
-
-
-
Method Detail
-
getTitle
default String getTitle()
Gets the title of the application.
-
getGroupId
String getGroupId()
The MavengroupIdof the application.
-
getArtifactId
String getArtifactId()
The MavenartifactIdof the application.
-
getPOM
POM getPOM()
Gets the Maven POM containing metadata about the application.
-
getManifest
Manifest getManifest()
Gets the manifest containing metadata about the application.NB: This metadata may be null if run in a development environment.
-
getInfo
default String getInfo(boolean mem)
Gets a string with information about the application.- Parameters:
mem- If true, memory usage information is included.
-
getSystemProperty
default String getSystemProperty()
A system property which, if set, overrides the base directory of the application.
-
getBaseDirectory
default File getBaseDirectory()
Gets the application's root directory. If the application's system property is set, it is used. Otherwise, we scan up the tree from this class for a suitable directory.
-
about
void about()
Displays information about the application. Typically this action takes the form as About dialog in the UI, and/or a message on the console.
-
prefs
default void prefs()
Displays application preferences. The behavior is application-specific, but typically a preferences dialog will be shown onscreen.
-
quit
default void quit()
Quits the application. Typically this action will prompt the user about any unsaved work first.
-
getVersion
default String getVersion()
Gets the version of the application.SciJava conforms to the Semantic Versioning specification.
- Specified by:
getVersionin interfaceVersioned- Returns:
- The application version, in
major.minor.microformat.
-
-