Package org.springframework.shell.table
Class AbsoluteWidthSizeConstraints
java.lang.Object
org.springframework.shell.table.AbsoluteWidthSizeConstraints
- All Implemented Interfaces:
SizeConstraints
A cell sizing strategy that forces a fixed width, expressed in number of characters.
-
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
-
AbsoluteWidthSizeConstraints
public AbsoluteWidthSizeConstraints(int width)
-
-
Method Details
-
width
- Specified by:
width
in interfaceSizeConstraints
- Parameters:
raw
- the raw String representation of the cell contents (may be reformatted later, eg wrapped)previous
- the whole available width for the tabletableWidth
- the number of columns in the table- Returns:
- the minimum and maximum width of the cell, given its raw content.
-