Package cz.vutbr.fit.layout.text
Class TextFlowConcatenator
- java.lang.Object
-
- cz.vutbr.fit.layout.text.TextFlowConcatenator
-
- All Implemented Interfaces:
AreaConcatenator,Concatenator<Area>
public class TextFlowConcatenator extends Object implements AreaConcatenator
A concatenator that considers the changes in the text flow when deciding whether to serarate to contents by spaces or not. Basically, in-flow elements should not be separated, block elements and new lines should be separated.- Author:
- burgetr
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTextFlowConcatenator.TextFlowBoxConcatenator
-
Constructor Summary
Constructors Constructor Description TextFlowConcatenator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringconcat(List<Area> elems)Creates a text string by concatenating the contents of the given elements.BoxConcatenatorgetBoxConcatenator()Gets the box concatenator used for the leaf areas.
-
-
-
Method Detail
-
getBoxConcatenator
public BoxConcatenator getBoxConcatenator()
Description copied from interface:AreaConcatenatorGets the box concatenator used for the leaf areas.- Specified by:
getBoxConcatenatorin interfaceAreaConcatenator- Returns:
- A box concatenator instance.
-
concat
public String concat(List<Area> elems)
Description copied from interface:ConcatenatorCreates a text string by concatenating the contents of the given elements.- Specified by:
concatin interfaceConcatenator<Area>- Parameters:
elems- The list of elements to concatenate.- Returns:
- Resulting text string.
-
-