Top Description Fields Constructors Methods
com.dlsc.preferencesfx.model

public Class Group

extends Object
Class Inheritance
Imports
com.dlsc.formsfx.model.structure.DataField, .Element, com.dlsc.preferencesfx.formsfx.view.controls.SimpleControl, com.dlsc.preferencesfx.formsfx.view.renderer.PreferencesFxGroup, com.dlsc.preferencesfx.util.Constants, .VisibilityProperty, java.util.Arrays, .List, javafx.beans.property.SimpleStringProperty, .StringProperty, javafx.event.EventHandler, javafx.scene.input.MouseEvent, org.slf4j.Logger, .LoggerFactory

Represents a group, which is used to structure one to multiple settings in a category.
Authors
François Martin, Marco Sanfratello

Field Summary

Modifier and TypeField and Description
private String
private static final Logger
private boolean
private static final String
private PreferencesFxGroup
private List<Setting<E extends Element<E extends Element<E>>, P extends Property<T>>>
private final EventHandler<MouseEvent>
private VisibilityProperty

Constructor Summary

AccessConstructor and Description
private
Group(String description, VisibilityProperty visibilityProperty, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

Method Summary

Modifier and TypeMethod and Description
public void
addToBreadcrumb(String
the breadcrumb to add to this group's breadcrumb
breadCrumb
)

Adds the breadCrumb to this breadcrumb and updates all of its settings accordingly.

private void
public Group

Returns:

this object for chaining with the fluent API
description
(String
the title of this group
description
)

Sets a description for this group.

public String
public String

Returns:

the description
getDescription
()

Returns the description of this group or if i18n is used, it will return the translated description in the current locale.

public PreferencesFxGroup
public List<Setting<E extends Element<E extends Element<E>>, P extends Property<T>>>
public VisibilityProperty
public void
mark()

Marks this group in the GUI.

public static Group

Returns:

this object for chaining with the fluent API
of
(String
the title of this group
description
,
Setting<E extends Element<E extends Element<E>>, P extends Property<T>>...
the settings that belong to this group
settings
)

Constructs a new group with a description and settings.

public static Group
of(String description, VisibilityProperty visibilityProperty, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

public static Group

Returns:

this object for chaining with the fluent API
of
(Setting<E extends Element<E extends Element<E>>, P extends Property<T>>...
the settings that belong to this group
settings
)

Constructs a new group with settings, without a description.

public static Group

Returns:

this object for chaining with the fluent API
of
(VisibilityProperty
visibility condition for Group
visibilityProperty
,
Setting<E extends Element<E extends Element<E>>, P extends Property<T>>...
the settings that belong to this group
settings
)

Constructs a new group with settings, without a description.

public void
setBreadcrumb(String breadcrumb)

public void
public void
public void
unmark()

Unmarks this group in the GUI.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

descriptionback to summary
private String description
LOGGERback to summary
private static final Logger LOGGER
markedback to summary
private boolean marked
MARKED_STYLE_CLASSback to summary
private static final String MARKED_STYLE_CLASS
preferencesGroupback to summary
private PreferencesFxGroup preferencesGroup
settingsback to summary
private List<Setting<E extends Element<E extends Element<E>>, P extends Property<T>>> settings
unmarkerback to summary
private final EventHandler<MouseEvent> unmarker
visibilityPropertyback to summary
private VisibilityProperty visibilityProperty

Constructor Detail

Groupback to summary
private Group(String description, VisibilityProperty visibilityProperty, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

Method Detail

addToBreadcrumbback to summary
public void addToBreadcrumb(String breadCrumb)

Adds the breadCrumb to this breadcrumb and updates all of its settings accordingly.

Parameters
breadCrumb:String

the breadcrumb to add to this group's breadcrumb

applyVisibilityForSettingsback to summary
private void applyVisibilityForSettings()
descriptionback to summary
public Group description(String description)

Sets a description for this group.

Parameters
description:String

the title of this group

Returns:Group

this object for chaining with the fluent API

getBreadcrumbback to summary
public String getBreadcrumb()
getDescriptionback to summary
public String getDescription()

Returns the description of this group or if i18n is used, it will return the translated description in the current locale.

Returns:String

the description

getPreferencesGroupback to summary
public PreferencesFxGroup getPreferencesGroup()
getSettingsback to summary
public List<Setting<E extends Element<E extends Element<E>>, P extends Property<T>>> getSettings()
getVisibilityPropertyback to summary
public VisibilityProperty getVisibilityProperty()
markback to summary
public void mark()

Marks this group in the GUI. Is used for the search, which marks and unmarks items depending on the match as a form of visual feedback.

ofback to summary
public static Group of(String description, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

Constructs a new group with a description and settings.

Parameters
description:String

the title of this group

settings:Setting<E extends Element<E extends Element<E>>, P extends Property<T>>[]

the settings that belong to this group

Returns:Group

this object for chaining with the fluent API

ofback to summary
public static Group of(String description, VisibilityProperty visibilityProperty, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)
ofback to summary
public static Group of(Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

Constructs a new group with settings, without a description.

Parameters
settings:Setting<E extends Element<E extends Element<E>>, P extends Property<T>>[]

the settings that belong to this group

Returns:Group

this object for chaining with the fluent API

ofback to summary
public static Group of(VisibilityProperty visibilityProperty, Setting<E extends Element<E extends Element<E>>, P extends Property<T>>... settings)

Constructs a new group with settings, without a description.

Parameters
visibilityProperty:VisibilityProperty

visibility condition for Group

settings:Setting<E extends Element<E extends Element<E>>, P extends Property<T>>[]

the settings that belong to this group

Returns:Group

this object for chaining with the fluent API

setBreadcrumbback to summary
public void setBreadcrumb(String breadcrumb)
setPreferencesGroupback to summary
public void setPreferencesGroup(PreferencesFxGroup preferencesGroup)
setVisibilityPropertyback to summary
public void setVisibilityProperty(VisibilityProperty visibilityProperty)
unmarkback to summary
public void unmark()

Unmarks this group in the GUI. Is used for the search, which marks and unmarks items depending on the match as a form of visual feedback.