Package com.openhtmltopdf.layout
Enum Breaker.BreakTextResult
- java.lang.Object
-
- java.lang.Enum<Breaker.BreakTextResult>
-
- com.openhtmltopdf.layout.Breaker.BreakTextResult
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<Breaker.BreakTextResult>
- Enclosing class:
- Breaker
public static enum Breaker.BreakTextResult extends java.lang.Enum<Breaker.BreakTextResult>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CHAR_UNBREAKABLE_BUT_CONSUMED
Not a single char fitted, but we consumed one character anyway.CONTINUE_CHAR_BREAKING_ON_NL
In char breaking mode, need a newline before continuing.CONTINUE_WORD_BREAKING_ON_NL
In word breaking mode, need a newline before continuing.DANGER_RECONSUME_CHAR_ON_NL
DANGER: Last char did not fit and we are directing the parent method to reconsume char on a newline.DANGER_RECONSUME_WORD_ON_NL
DANGER: Last word did not fit and we are directing the parent method to reconsume word on a newline.FINISHED
Has completely consumed the string.WORD_UNBREAKABLE_BUT_CONSUMED
Not a single word fitted, but we consumed a word anyway.
-
Constructor Summary
Constructors Modifier Constructor Description private
BreakTextResult()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Breaker.BreakTextResult
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static Breaker.BreakTextResult[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
FINISHED
public static final Breaker.BreakTextResult FINISHED
Has completely consumed the string.
-
CONTINUE_CHAR_BREAKING_ON_NL
public static final Breaker.BreakTextResult CONTINUE_CHAR_BREAKING_ON_NL
In char breaking mode, need a newline before continuing. At least one character has been consumed.
-
CONTINUE_WORD_BREAKING_ON_NL
public static final Breaker.BreakTextResult CONTINUE_WORD_BREAKING_ON_NL
In word breaking mode, need a newline before continuing. At least one word has been consumed.
-
CHAR_UNBREAKABLE_BUT_CONSUMED
public static final Breaker.BreakTextResult CHAR_UNBREAKABLE_BUT_CONSUMED
Not a single char fitted, but we consumed one character anyway.
-
WORD_UNBREAKABLE_BUT_CONSUMED
public static final Breaker.BreakTextResult WORD_UNBREAKABLE_BUT_CONSUMED
Not a single word fitted, but we consumed a word anyway. Only returned when word-wrap is not break-word.
-
DANGER_RECONSUME_CHAR_ON_NL
public static final Breaker.BreakTextResult DANGER_RECONSUME_CHAR_ON_NL
DANGER: Last char did not fit and we are directing the parent method to reconsume char on a newline. Example, below floats.
-
DANGER_RECONSUME_WORD_ON_NL
public static final Breaker.BreakTextResult DANGER_RECONSUME_WORD_ON_NL
DANGER: Last word did not fit and we are directing the parent method to reconsume word on a newline. Example, below floats.
-
-
Method Detail
-
values
public static Breaker.BreakTextResult[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Breaker.BreakTextResult c : Breaker.BreakTextResult.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Breaker.BreakTextResult valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-