public class WordBreakerFactory extends Object
WordBreaker. This may be used to define a
custom strategy for breaking words. By default the WordBreakers.DefaultWordBreaker
is used. Another predefined word breaker is the
WordBreakers.NonBreakingWordBreaker which may be used to get the legacy behavior.
To switch to a different word breaker, just set the system property
pdfbox.layout.word.breaker to the class
name of the breaker to use.| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_WORD_BREAKER_CLASS_NAME
class name of the default word breaker.
|
static String |
LEGACY_WORD_BREAKER_CLASS_NAME
class name of the (legacy) non-breaking word breaker.
|
static String |
WORD_BREAKER_CLASS_PROPERTY
constant for the system property
pdfbox.layout.word.breaker. |
| Constructor and Description |
|---|
WordBreakerFactory() |
| Modifier and Type | Method and Description |
|---|---|
static WordBreaker |
getWorkBreaker() |
public static final String WORD_BREAKER_CLASS_PROPERTY
pdfbox.layout.word.breaker.public static final String DEFAULT_WORD_BREAKER_CLASS_NAME
public static final String LEGACY_WORD_BREAKER_CLASS_NAME
public static WordBreaker getWorkBreaker()
Copyright © 2022. All rights reserved.