Top Inners Constructors Methods
com.github.javaparser.printer.lexicalpreservation

pack-priv Class TextElementIteratorsFactory

extends Object
Class Inheritance
Imports
java.util.Iterator, .LinkedList, .List

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
pack-priv static class
pack-priv static class
private static class

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public static Iterator<TokenTextElement>
partialReverseIterator(NodeText nodeText, int fromIndex)

private static Iterator<TokenTextElement>
reverseIterator(NodeText nodeText, int index)

public static Iterator<TokenTextElement>
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

TextElementIteratorsFactoryback to summary
pack-priv TextElementIteratorsFactory()

Method Detail

partialReverseIteratorback to summary
public static Iterator<TokenTextElement> partialReverseIterator(NodeText nodeText, int fromIndex)
reverseIteratorback to summary
private static Iterator<TokenTextElement> reverseIterator(NodeText nodeText, int index)
reverseIteratorback to summary
public static Iterator<TokenTextElement> reverseIterator(NodeText nodeText)
com.github.javaparser.printer.lexicalpreservation back to summary

pack-priv Class TextElementIteratorsFactory.CascadingIterator<E>

extends Object
implements Iterator<E>
Class Inheritance
  • java.lang.Object
  • com.github.javaparser.printer.lexicalpreservation.TextElementIteratorsFactory.CascadingIterator
All Implemented Interfaces
java.util.Iterator

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static interface

Field Summary

Modifier and TypeField and Description
private Iterator<E>
private boolean
private boolean
private Iterator<E>
private final TextElementIteratorsFactory.CascadingIterator.Provider<E>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public boolean
hasNext()

Implements java.util.Iterator.hasNext.

Returns true if the iteration has more elements.
public E
next()

Implements java.util.Iterator.next.

Returns the next element in the iteration.
public void
remove()

Overrides default java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation).
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

currentback to summary
private Iterator<E> current
lastReturnedFromCurrentback to summary
private boolean lastReturnedFromCurrent
lastReturnedFromNextback to summary
private boolean lastReturnedFromNext
nextback to summary
private Iterator<E> next
nextProviderback to summary
private final TextElementIteratorsFactory.CascadingIterator.Provider<E> nextProvider

Constructor Detail

CascadingIteratorback to summary
public CascadingIterator(Iterator<E> current, TextElementIteratorsFactory.CascadingIterator.Provider<E> nextProvider)

Method Detail

hasNextback to summary
public boolean hasNext()

Implements java.util.Iterator.hasNext.

Doc from java.util.Iterator.hasNext.

Returns true if the iteration has more elements. (In other words, returns true if next would return an element rather than throwing an exception.)

Returns:boolean

true if the iteration has more elements

Annotations
@Override
nextback to summary
public E next()

Implements java.util.Iterator.next.

Doc from java.util.Iterator.next.

Returns the next element in the iteration.

Returns:E

the next element in the iteration

Annotations
@Override
removeback to summary
public void remove()

Overrides default java.util.Iterator.remove.

Doc from java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation). This method can be called only once per call to next.

The behavior of an iterator is unspecified if the underlying collection is modified while the iteration is in progress in any way other than by calling this method, unless an overriding class has specified a concurrent modification policy.

The behavior of an iterator is unspecified if this method is called after a call to the forEachRemaining method.

Annotations
@Override
com.github.javaparser.printer.lexicalpreservation back to summary

pack-priv Interface TextElementIteratorsFactory.CascadingIterator.Provider<E>


Method Summary

Modifier and TypeMethod and Description
public Iterator<E>

Method Detail

provideback to summary
public Iterator<E> provide()
com.github.javaparser.printer.lexicalpreservation back to summary

pack-priv Class TextElementIteratorsFactory.ComposedIterator<E>

extends Object
implements Iterator<E>
Class Inheritance
  • java.lang.Object
  • com.github.javaparser.printer.lexicalpreservation.TextElementIteratorsFactory.ComposedIterator
All Implemented Interfaces
java.util.Iterator

Field Summary

Modifier and TypeField and Description
private int
private final List<Iterator<E>>

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public boolean
hasNext()

Implements java.util.Iterator.hasNext.

Returns true if the iteration has more elements.
public E
next()

Implements java.util.Iterator.next.

Returns the next element in the iteration.
public void
remove()

Overrides default java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation).
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

currIndexback to summary
private int currIndex
elementsback to summary
private final List<Iterator<E>> elements

Constructor Detail

ComposedIteratorback to summary
pack-priv ComposedIterator(List<Iterator<E>> elements)

Method Detail

hasNextback to summary
public boolean hasNext()

Implements java.util.Iterator.hasNext.

Doc from java.util.Iterator.hasNext.

Returns true if the iteration has more elements. (In other words, returns true if next would return an element rather than throwing an exception.)

Returns:boolean

true if the iteration has more elements

Annotations
@Override
nextback to summary
public E next()

Implements java.util.Iterator.next.

Doc from java.util.Iterator.next.

Returns the next element in the iteration.

Returns:E

the next element in the iteration

Annotations
@Override
removeback to summary
public void remove()

Overrides default java.util.Iterator.remove.

Doc from java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation). This method can be called only once per call to next.

The behavior of an iterator is unspecified if the underlying collection is modified while the iteration is in progress in any way other than by calling this method, unless an overriding class has specified a concurrent modification policy.

The behavior of an iterator is unspecified if this method is called after a call to the forEachRemaining method.

Annotations
@Override
com.github.javaparser.printer.lexicalpreservation back to summary

pack-priv Class TextElementIteratorsFactory.EmptyIterator<E>

extends Object
implements Iterator<E>
Class Inheritance
  • java.lang.Object
  • com.github.javaparser.printer.lexicalpreservation.TextElementIteratorsFactory.EmptyIterator
All Implemented Interfaces
java.util.Iterator

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public boolean
hasNext()

Implements java.util.Iterator.hasNext.

Returns true if the iteration has more elements.
public E
next()

Implements java.util.Iterator.next.

Returns the next element in the iteration.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

EmptyIteratorback to summary
pack-priv EmptyIterator()

Method Detail

hasNextback to summary
public boolean hasNext()

Implements java.util.Iterator.hasNext.

Doc from java.util.Iterator.hasNext.

Returns true if the iteration has more elements. (In other words, returns true if next would return an element rather than throwing an exception.)

Returns:boolean

true if the iteration has more elements

Annotations
@Override
nextback to summary
public E next()

Implements java.util.Iterator.next.

Doc from java.util.Iterator.next.

Returns the next element in the iteration.

Returns:E

the next element in the iteration

Annotations
@Override
com.github.javaparser.printer.lexicalpreservation back to summary

private Class TextElementIteratorsFactory.SingleElementIterator<E>

extends Object
implements Iterator<E>
Class Inheritance
  • java.lang.Object
  • com.github.javaparser.printer.lexicalpreservation.TextElementIteratorsFactory.SingleElementIterator
All Implemented Interfaces
java.util.Iterator

Field Summary

Modifier and TypeField and Description
private final E
private boolean

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public boolean
hasNext()

Implements java.util.Iterator.hasNext.

Returns true if the iteration has more elements.
public E
next()

Implements java.util.Iterator.next.

Returns the next element in the iteration.
public void
remove()

Overrides default java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation).
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

elementback to summary
private final E element
returnedback to summary
private boolean returned

Constructor Detail

SingleElementIteratorback to summary
pack-priv SingleElementIterator(E element)

Method Detail

hasNextback to summary
public boolean hasNext()

Implements java.util.Iterator.hasNext.

Doc from java.util.Iterator.hasNext.

Returns true if the iteration has more elements. (In other words, returns true if next would return an element rather than throwing an exception.)

Returns:boolean

true if the iteration has more elements

Annotations
@Override
nextback to summary
public E next()

Implements java.util.Iterator.next.

Doc from java.util.Iterator.next.

Returns the next element in the iteration.

Returns:E

the next element in the iteration

Annotations
@Override
removeback to summary
public void remove()

Overrides default java.util.Iterator.remove.

Doc from java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation). This method can be called only once per call to next.

The behavior of an iterator is unspecified if the underlying collection is modified while the iteration is in progress in any way other than by calling this method, unless an overriding class has specified a concurrent modification policy.

The behavior of an iterator is unspecified if this method is called after a call to the forEachRemaining method.

Annotations
@Override