public abstract class TagsComponent extends Object
Tagger
and TagPropagationComponent
.
All objects returned by methods on TagsComponent
are cacheable.
Constructor and Description |
---|
TagsComponent() |
Modifier and Type | Method and Description |
---|---|
abstract TaggingState |
getState()
Returns the current
TaggingState . |
abstract Tagger |
getTagger()
Returns the
Tagger for this implementation. |
abstract TagPropagationComponent |
getTagPropagationComponent()
Returns the
TagPropagationComponent for this implementation. |
abstract void |
setState(TaggingState state)
Deprecated.
This method is deprecated because other libraries could cache the result of
getState() , use a stale value, and behave incorrectly. It is only safe to call early in
initialization. This method throws IllegalStateException after getState()
has been called, in order to limit changes to the result of getState() . |
public abstract TagPropagationComponent getTagPropagationComponent()
TagPropagationComponent
for this implementation.public abstract TaggingState getState()
TaggingState
.
When no implementation is available, getState
always returns TaggingState.DISABLED
.
Once getState()
is called, subsequent calls to setState(TaggingState)
will
throw an IllegalStateException
.
TaggingState
.@Deprecated public abstract void setState(TaggingState state)
getState()
, use a stale value, and behave incorrectly. It is only safe to call early in
initialization. This method throws IllegalStateException
after getState()
has been called, in order to limit changes to the result of getState()
.TaggingState
.
When no implementation is available, setState
does not change the state.
state
- the new TaggingState
.IllegalStateException
- if getState()
was previously called.