public class TextPropCollection extends java.lang.Object implements GenericRecord, Duplicatable
Modifier and Type | Class and Description |
---|---|
static class |
TextPropCollection.TextPropType |
Constructor and Description |
---|
TextPropCollection(int charactersCovered,
TextPropCollection.TextPropType textPropType)
Create a new collection of text properties (be they paragraph
or character) which will be groked via a subsequent call to
buildTextPropList().
|
TextPropCollection(TextPropCollection other) |
Modifier and Type | Method and Description |
---|---|
void |
addProp(TextProp textProp)
Add the property at the correct position.
|
<T extends TextProp> |
addWithName(java.lang.String name)
Add the TextProp with this name to the list
|
int |
buildTextPropList(int containsField,
byte[] data,
int dataOffset)
For an existing set of text properties, build the list of
properties coded for in a given run of properties.
|
TextPropCollection |
copy()
Clones the given text properties
|
boolean |
equals(java.lang.Object other)
compares most properties apart of the covered characters length
|
<T extends TextProp> |
findByName(java.lang.String textPropName)
Fetch the TextProp with this name, or null if it isn't present
|
int |
getCharactersCovered()
Fetch the number of characters this styling applies to
|
java.util.Map<java.lang.String,java.util.function.Supplier<?>> |
getGenericProperties() |
short |
getIndentLevel() |
int |
getSpecialMask() |
java.util.List<TextProp> |
getTextPropList()
Fetch the TextProps that define this styling in the record order
|
TextPropCollection.TextPropType |
getTextPropType() |
int |
hashCode() |
<T extends TextProp> |
removeByName(java.lang.String name) |
void |
setIndentLevel(short indentLevel) |
java.lang.String |
toString() |
void |
updateTextSize(int textSize)
Update the size of the text that this set of properties
applies to
|
void |
writeOut(java.io.OutputStream o)
Writes out to disk the header, and then all the properties
|
void |
writeOut(java.io.OutputStream o,
boolean isMasterStyle)
Writes out to disk the header, and then all the properties
|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getGenericChildren, getGenericRecordType
public TextPropCollection(int charactersCovered, TextPropCollection.TextPropType textPropType)
public TextPropCollection(TextPropCollection other)
public int getSpecialMask()
public int getCharactersCovered()
public java.util.List<TextProp> getTextPropList()
public final <T extends TextProp> T findByName(java.lang.String textPropName)
public final <T extends TextProp> T removeByName(java.lang.String name)
public final TextPropCollection.TextPropType getTextPropType()
public final <T extends TextProp> T addWithName(java.lang.String name)
public final void addProp(TextProp textProp)
textProp
- the property to be addedpublic int buildTextPropList(int containsField, byte[] data, int dataOffset)
public TextPropCollection copy()
copy
in interface Duplicatable
public void updateTextSize(int textSize)
public void writeOut(java.io.OutputStream o) throws java.io.IOException
java.io.IOException
public void writeOut(java.io.OutputStream o, boolean isMasterStyle) throws java.io.IOException
java.io.IOException
public short getIndentLevel()
public void setIndentLevel(short indentLevel)
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public java.util.Map<java.lang.String,java.util.function.Supplier<?>> getGenericProperties()
getGenericProperties
in interface GenericRecord
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.