ListProperty for a
list change and in a ObjectProperty for regular changes as well
Implementation Note
There are two types: List changes and regular changes. Internally, all changes are
saved into a ListProperty for the old and the new value, regardless of the
type of change. However, if two ObservableList are used to create a change, a
boolean flags the change as a list change. In case of a regular change, a binding will
also set an ObjectProperty for easier handling.
| Modifier and Type | Field and Description |
|---|---|
| private final BooleanProperty | |
| private static final Logger | |
| private final ListProperty | |
| private final ObjectProperty | |
| private final ListProperty | |
| private final ObjectProperty | |
| protected final Setting | |
| private final LocalDateTime |
| Access | Constructor and Description |
|---|---|
| protected | |
| public | Change(Setting<E extends Element<E extends Element<E>>, P extends Property<T>>
the setting that was changed setting, ObservableList<P> the "before" value(s) of the change oldList, ObservableList<P> the "after" value(s) of the change newList)Constructs a list change. |
| public |
| Modifier and Type | Method and Description |
|---|---|
| private Callable | Returns: Callable function, which binds a list to an object property.to be bound to the object property listProperty)Creates a function, which handles binding between a ListProperty and an ObjectProperty. |
| public ObservableList | |
| public P | |
| public ObservableList | |
| public P | |
| public Setting | |
| public String | |
| public boolean | |
| public boolean | Returns: true if redundant, else if otherwise.Compares newValue and oldValue to see if they are the same. |
| public ReadOnlyBooleanProperty | |
| public ReadOnlyListProperty | |
| public ReadOnlyObjectProperty | |
| public ReadOnlyListProperty | |
| public ReadOnlyObjectProperty | |
| public void | |
| public void | |
| public void | |
| private void | |
| public void |
| listChange | back to summary |
|---|---|
| private final BooleanProperty listChange | |
| LOGGER | back to summary |
|---|---|
| private static final Logger LOGGER | |
| newList | back to summary |
|---|---|
| private final ListProperty<P> newList | |
| newValue | back to summary |
|---|---|
| private final ObjectProperty<P> newValue | |
| oldList | back to summary |
|---|---|
| private final ListProperty<P> oldList | |
| oldValue | back to summary |
|---|---|
| private final ObjectProperty<P> oldValue | |
| setting | back to summary |
|---|---|
| protected final Setting<E extends Element<E extends Element<E>>, P extends Property<T>> setting | |
| timestamp | back to summary |
|---|---|
| private final LocalDateTime timestamp | |
| Change | back to summary |
|---|---|
| protected Change(Setting<E extends Element<E extends Element<E>>, P extends Property<T>> setting, boolean listChange) Constructs a generalized change. | |
| Change | back to summary |
|---|---|
| public Change(Setting<E extends Element<E extends Element<E>>, P extends Property<T>> setting, ObservableList<P> oldList, ObservableList<P> newList) Constructs a list change.
| |
| Change | back to summary |
|---|---|
| public Change(Setting<E extends Element<E extends Element<E>>, P extends Property<T>> setting, P oldValue, P newValue) Constructs a regular object change. | |
| createListToObjectBinding | back to summary |
|---|---|
| private Callable Creates a function, which handles binding between a ListProperty and an ObjectProperty. If this change isn't a list change, oldValue and newValue properties will have the single element inside of the list, for easier usage.
| |
| getNewList | back to summary |
|---|---|
| public ObservableList | |
| getNewValue | back to summary |
|---|---|
| public P getNewValue() | |
| getOldList | back to summary |
|---|---|
| public ObservableList | |
| getOldValue | back to summary |
|---|---|
| public P getOldValue() | |
| getSetting | back to summary |
|---|---|
| public Setting | |
| getTimestamp | back to summary |
|---|---|
| public String getTimestamp() | |
| isListChange | back to summary |
|---|---|
| public boolean isListChange() | |
| isRedundant | back to summary |
|---|---|
| public boolean isRedundant() Compares newValue and oldValue to see if they are the same. If this is the case, this change is redundant, since it doesn't represent a true change. This can happen on compounded changes.
| |
| listChangeProperty | back to summary |
|---|---|
| public ReadOnlyBooleanProperty listChangeProperty() | |
| newListProperty | back to summary |
|---|---|
| public ReadOnlyListProperty | |
| newValueProperty | back to summary |
|---|---|
| public ReadOnlyObjectProperty | |
| oldListProperty | back to summary |
|---|---|
| public ReadOnlyListProperty | |
| oldValueProperty | back to summary |
|---|---|
| public ReadOnlyObjectProperty | |
| redo | back to summary |
|---|---|
| public void redo() Redos a change.
Does this by setting the corresponding value of the | |
| setNewList | back to summary |
|---|---|
| public void setNewList(ObservableList<P> newList) | |
| setNewValue | back to summary |
|---|---|
| public void setNewValue(P newValue) | |
| setupBindings | back to summary |
|---|---|
| private void setupBindings() | |
| undo | back to summary |
|---|---|
| public void undo() Undos a change.
Does this by setting the corresponding value of the | |