Package org.springframework.shell.table
Class AutoSizeConstraints
java.lang.Object
org.springframework.shell.table.AutoSizeConstraints
- All Implemented Interfaces:
SizeConstraints
A SizeConstraints implementation that splits lines at space boundaries
and returns an extent with minimal and maximal width requirements.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.springframework.shell.table.SizeConstraints
SizeConstraints.Extent
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription
-
Constructor Details
-
AutoSizeConstraints
public AutoSizeConstraints()
-
-
Method Details
-
width
- Specified by:
width
in interfaceSizeConstraints
- Parameters:
raw
- the raw String representation of the cell contents (may be reformatted later, eg wrapped)tableWidth
- the whole available width for the tablenbColumns
- the number of columns in the table- Returns:
- the minimum and maximum width of the cell, given its raw content.
-