public class CompoundHighlighter extends AbstractHighlighter implements UIDependent
Highlighters.Highlighter| Modifier and Type | Field and Description |
|---|---|
static Highlighter[] |
EMPTY_HIGHLIGHTERS |
protected List<Highlighter> |
highlighters |
listenerList| Constructor and Description |
|---|
CompoundHighlighter(Highlighter... inList)
Instantiates a CompoundHighlighter containing the given
Highlighters. |
CompoundHighlighter(HighlightPredicate predicate,
Highlighter... inList)
Instantiates a CompoundHighlighter with the given predicate containing the given
Highlighters. |
| Modifier and Type | Method and Description |
|---|---|
void |
addHighlighter(Highlighter highlighter)
Appends a highlighter to the pipeline.
|
void |
addHighlighter(Highlighter highlighter,
boolean prepend)
Adds a highlighter to the pipeline.
|
protected ChangeListener |
createHighlighterChangeListener()
Creates and returns the ChangeListener registered to
contained
Highlighters. |
protected Component |
doHighlight(Component stamp,
ComponentAdapter adapter)
Apply the highlights.
|
protected ChangeListener |
getHighlighterChangeListener()
Returns the
ChangeListner to contained
Highlighters. |
Highlighter[] |
getHighlighters()
Returns an array of contained Highlighters.
|
void |
removeHighlighter(Highlighter hl)
Removes a highlighter from the pipeline.
|
void |
setHighlighters(Highlighter... inList)
Sets the given
Highlighters. |
void |
updateUI()
Updates all internal visuals after changing a UI-delegate.
|
addChangeListener, areEqual, canHighlight, fireStateChanged, getChangeListeners, getHighlightPredicate, highlight, removeChangeListener, setHighlightPredicatepublic static final Highlighter[] EMPTY_HIGHLIGHTERS
protected List<Highlighter> highlighters
public CompoundHighlighter(Highlighter... inList)
Highlighters.inList - zero or more not-null Highlighters to manage by this
CompoundHighlighter.NullPointerException - if array is null or array contains null values.public CompoundHighlighter(HighlightPredicate predicate, Highlighter... inList)
Highlighters.predicate - the highlightPredicate to useinList - zero or more not-null Highlighters to manage by this
CompoundHighlighter.NullPointerException - if array is null or array contains null values.public void setHighlighters(Highlighter... inList)
Highlighters.inList - zero or more not-null Highlighters to manage by this
CompoundHighlighter.NullPointerException - if array is null or array contains null values.public void addHighlighter(Highlighter highlighter)
highlighter - highlighter to addNullPointerException - if highlighter is null.public void addHighlighter(Highlighter highlighter, boolean prepend)
highlighter - highlighter to addprepend - prepend the highlighter if true; false will appendNullPointerException - if highlighter is null.public void removeHighlighter(Highlighter hl)
hl - highlighter to removepublic Highlighter[] getHighlighters()
public void updateUI()
Implemented to call updateUI on contained Highlighters.
updateUI in interface UIDependentJComponent.updateUI()protected ChangeListener getHighlighterChangeListener()
ChangeListner to contained
Highlighters. The listener is lazily created.protected ChangeListener createHighlighterChangeListener()
Highlighters. Here: fires a
stateChanged on each notification.protected Component doHighlight(Component stamp, ComponentAdapter adapter)
doHighlight in class AbstractHighlighterstamp - the cell renderer component that is to be decoratedadapter - the ComponentAdapter for this decorate operationAbstractHighlighter.highlight(Component, ComponentAdapter)Copyright © 2017. All Rights Reserved.