Package com.helger.pdflayout.spec
Class BorderStyleSpec
java.lang.Object
com.helger.pdflayout.spec.BorderStyleSpec
- All Implemented Interfaces:
Serializable
@Immutable
@MustImplementEqualsAndHashcode
public class BorderStyleSpec
extends Object
implements Serializable
This class contains the styling of a single border part. Currently only the
color, the dash pattern and the line width can be set.
- Author:
- Philip Helger
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PLColorThe default border color: blackstatic final LineDashPatternSpecThe default border style: solidstatic final floatUse the default line width if unspecified.static final BorderStyleSpec -
Constructor Summary
ConstructorsConstructorDescriptionBorderStyleSpec(float fLineWidth) BorderStyleSpec(PLColor aColor) BorderStyleSpec(PLColor aColor, float fLineWidth) BorderStyleSpec(PLColor aColor, LineDashPatternSpec aLineDashPattern) BorderStyleSpec(PLColor aColor, LineDashPatternSpec aLineDashPattern, float fLineWidth) BorderStyleSpec(LineDashPatternSpec aLineDashPattern) -
Method Summary
Modifier and TypeMethodDescriptionbooleangetCloneWithColor(PLColor aNewColor) getCloneWithLineDashPattern(LineDashPatternSpec aNewLineDashPattern) getCloneWithLineWidth(float fNewLineWidth) final PLColorgetColor()final LineDashPatternSpecfinal floatinthashCode()final booleantoString()
-
Field Details
-
DEFAULT_COLOR
The default border color: black -
DEFAULT_LINE_DASH_PATTERN
The default border style: solid -
DEFAULT_LINE_WIDTH
public static final float DEFAULT_LINE_WIDTHUse the default line width if unspecified. A width of 0 is also valid and would create a hair line- See Also:
-
EMPTY
-
-
Constructor Details
-
BorderStyleSpec
public BorderStyleSpec() -
BorderStyleSpec
-
BorderStyleSpec
-
BorderStyleSpec
public BorderStyleSpec(float fLineWidth) -
BorderStyleSpec
-
BorderStyleSpec
-
BorderStyleSpec
public BorderStyleSpec(@Nonnull PLColor aColor, @Nonnull LineDashPatternSpec aLineDashPattern, @Nonnegative float fLineWidth)
-
-
Method Details
-
getColor
- Returns:
- The border color to use. Never
null.
-
getLineDashPattern
- Returns:
- The border line style to use. Never
null.
-
getLineWidth
-
isDefault
public final boolean isDefault()- Returns:
trueif all values are set to default,falseotherwise.
-
getCloneWithColor
-
getCloneWithLineDashPattern
@Nonnull public BorderStyleSpec getCloneWithLineDashPattern(@Nonnull LineDashPatternSpec aNewLineDashPattern) -
getCloneWithLineWidth
-
equals
-
hashCode
public int hashCode() -
toString
-