public abstract class ParticleApplication
extends javafx.application.Application
For these reasons, it is highly recommended that developers choose to
build their software by extending from this class. An alternative approach is
to create a JavaFX application the usual way (by extending Application
),
and then creating a Particle
instance and setting that inside the application
Scene
(refer to the Particle
class for more detail on this
approach).
Particle
Type | Property and Description |
---|---|
javafx.beans.property.BooleanProperty |
showCloseConfirmation |
javafx.beans.property.StringProperty |
title |
Modifier | Constructor and Description |
---|---|
protected |
ParticleApplication()
Creates a new instance of ParticleApplication with no name (which is not
encouraged).
|
protected |
ParticleApplication(java.lang.String appName)
Creates a new instance of ParticleApplication with the given name - this
is the recommended approach as the name is used elsewhere in Particle to
allow for automatic configuration (by scanning for files with this name,
for example).
|
Modifier and Type | Method and Description |
---|---|
void |
exit()
It is highly recommended that all attempts to exit Particle be done
through this method, as it ensure that the user is prompted that they
do indeed wish to exit.
|
Particle |
getParticle()
Returns the inner
Particle instance that has been instantiated
for use inside this ParticleApplication. |
javafx.stage.Stage |
getPrimaryStage()
Returns the primary stage used within this Particle application.
|
java.lang.String |
getTitle()
Gets the value of the property title.
|
boolean |
isShowCloseConfirmation()
Gets the value of the property showCloseConfirmation.
|
void |
postInit(javafx.scene.Scene scene)
This method is called after the application is initialized but before the
primary stage is shown to the user.
|
void |
setShowCloseConfirmation(boolean value)
Sets the value of the property showCloseConfirmation.
|
void |
setTitle(java.lang.String title)
Sets the value of the property title.
|
javafx.beans.property.BooleanProperty |
showCloseConfirmationProperty() |
void |
start(javafx.stage.Stage primaryStage) |
void |
stop() |
javafx.beans.property.StringProperty |
titleProperty() |
public final javafx.beans.property.StringProperty titleProperty
getTitle()
,
setTitle(String)
public final javafx.beans.property.BooleanProperty showCloseConfirmationProperty
protected ParticleApplication()
protected ParticleApplication(java.lang.String appName)
public final void start(javafx.stage.Stage primaryStage) throws java.lang.Exception
start
in class javafx.application.Application
java.lang.Exception
public void postInit(javafx.scene.Scene scene)
public void stop() throws java.lang.Exception
stop
in class javafx.application.Application
java.lang.Exception
public final javafx.beans.property.StringProperty titleProperty()
getTitle()
,
setTitle(String)
public final void setTitle(java.lang.String title)
public final java.lang.String getTitle()
public final javafx.beans.property.BooleanProperty showCloseConfirmationProperty()
public final void setShowCloseConfirmation(boolean value)
public final boolean isShowCloseConfirmation()
public final Particle getParticle()
Particle
instance that has been instantiated
for use inside this ParticleApplication.public final void exit()
public final javafx.stage.Stage getPrimaryStage()