Top Inners Fields Constructors Methods
org.fxmisc.undo.impl

public Class UnlimitedChangeQueue<C>

extends Object
implements ChangeQueue<C>
Class Inheritance
All Implemented Interfaces
org.fxmisc.undo.impl.ChangeQueue
Imports
java.util.ArrayList

Nested and Inner Type Summary

Modifier and TypeClass and Description
private class

Field Summary

Modifier and TypeField and Description
private final ArrayList<RevisionedChange<C>>
private int
private int
private long
private long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
public ChangeQueue.QueuePosition
public final boolean
public final boolean
public final C
next()

Implements org.fxmisc.undo.impl.ChangeQueue.next.

Returns the next item and increases the current position by 1.

public final C
peekNext()

Implements org.fxmisc.undo.impl.ChangeQueue.peekNext.

Returns the next item.

public final C
peekPrev()

Implements org.fxmisc.undo.impl.ChangeQueue.peekPrev.

Returns the previous item.

public final C
prev()

Implements org.fxmisc.undo.impl.ChangeQueue.prev.

Returns the previous item and decreases the current position by 1.

public final void
private long
revisionForPosition(int position)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

changesback to summary
private final ArrayList<RevisionedChange<C>> changes
currentPositionback to summary
private int currentPosition
forgottenCountback to summary
private int forgottenCount
revisionback to summary
private long revision
zeroPositionRevisionback to summary
private long zeroPositionRevision

Constructor Detail

UnlimitedChangeQueueback to summary
public UnlimitedChangeQueue()

Method Detail

forgetHistoryback to summary
public void forgetHistory()

Implements org.fxmisc.undo.impl.ChangeQueue.forgetHistory.

Annotations
@Override
getCurrentPositionback to summary
public ChangeQueue.QueuePosition getCurrentPosition()

Implements org.fxmisc.undo.impl.ChangeQueue.getCurrentPosition.

Annotations
@Override
hasNextback to summary
public final boolean hasNext()

Implements org.fxmisc.undo.impl.ChangeQueue.hasNext.

Annotations
@Override
hasPrevback to summary
public final boolean hasPrev()

Implements org.fxmisc.undo.impl.ChangeQueue.hasPrev.

Annotations
@Override
nextback to summary
public final C next()

Implements org.fxmisc.undo.impl.ChangeQueue.next.

Doc from org.fxmisc.undo.impl.ChangeQueue.next.

Returns the next item and increases the current position by 1.

Annotations
@Override
peekNextback to summary
public final C peekNext()

Implements org.fxmisc.undo.impl.ChangeQueue.peekNext.

Doc from org.fxmisc.undo.impl.ChangeQueue.peekNext.

Returns the next item. Current position stays unchanged.

Annotations
@Override
peekPrevback to summary
public final C peekPrev()

Implements org.fxmisc.undo.impl.ChangeQueue.peekPrev.

Doc from org.fxmisc.undo.impl.ChangeQueue.peekPrev.

Returns the previous item. Current position stays unchanged.

Annotations
@Override
prevback to summary
public final C prev()

Implements org.fxmisc.undo.impl.ChangeQueue.prev.

Doc from org.fxmisc.undo.impl.ChangeQueue.prev.

Returns the previous item and decreases the current position by 1.

Annotations
@Override
pushback to summary
public final void push(C... changes)

Implements org.fxmisc.undo.impl.ChangeQueue.push.

Annotations
@Override
@SafeVarargs
revisionForPositionback to summary
private long revisionForPosition(int position)
org.fxmisc.undo.impl back to summary

private Class UnlimitedChangeQueue.QueuePositionImpl

extends Object
implements QueuePosition
Class Inheritance
All Implemented Interfaces
org.fxmisc.undo.impl.ChangeQueue.QueuePosition

Field Summary

Modifier and TypeField and Description
private final int
private final long

Constructor Summary

AccessConstructor and Description
pack-priv
QueuePositionImpl(int allTimePos, long rev)

Method Summary

Modifier and TypeMethod and Description
public boolean
equals(Object other)

Overrides java.lang.Object.equals.

Indicates whether some other object is "equal to" this one.

private UnlimitedChangeQueue<C>
public boolean
Inherited from java.lang.Object:
clonefinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

allTimePosback to summary
private final int allTimePos
revback to summary
private final long rev

Constructor Detail

QueuePositionImplback to summary
pack-priv QueuePositionImpl(int allTimePos, long rev)

Method Detail

equalsback to summary
public boolean equals(Object other)

Overrides java.lang.Object.equals.

Doc from java.lang.Object.equals.

Indicates whether some other object is "equal to" this one.

The equals method implements an equivalence relation on non-null object references:

  • It is reflexive: for any non-null reference value x, x.equals(x) should return true.
  • It is symmetric: for any non-null reference values x and y, x.equals(y) should return true if and only if y.equals(x) returns true.
  • It is transitive: for any non-null reference values x, y, and z, if x.equals(y) returns true and y.equals(z) returns true, then x.equals(z) should return true.
  • It is consistent: for any non-null reference values x and y, multiple invocations of x.equals(y) consistently return true or consistently return false, provided no information used in equals comparisons on the objects is modified.
  • For any non-null reference value x, x.equals(null) should return false.

An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes.

Annotations
@Override
getQueueback to summary
private UnlimitedChangeQueue<C> getQueue()
isValidback to summary
public boolean isValid()

Implements org.fxmisc.undo.impl.ChangeQueue.QueuePosition.isValid.

Annotations
@Override