TableBorder
in package
implements
JsonSerializable
FinalYes
Border configuration for tables.
Tags
Table of Contents
Interfaces
- JsonSerializable
Properties
- $all : TableStrokeStyle|null
- The border for all sides.
- $bottom : TableStrokeStyle|null
- The bottom border.
- $left : TableStrokeStyle|null
- The left border.
- $right : TableStrokeStyle|null
- The right border.
- $top : TableStrokeStyle|null
- The top border.
Methods
- jsonSerialize() : array<string, mixed>
- {@inheritdoc}
- setAll() : $this
- Set all borders.
- setBottom() : $this
- Set the bottom border.
- setLeft() : $this
- Set the left border.
- setRight() : $this
- Set the right border.
- setTop() : $this
- Set the top border.
- uniform() : self
- Create a uniform border.
Properties
$all
The border for all sides.
private
TableStrokeStyle|null
$all
= null
$bottom
The bottom border.
private
TableStrokeStyle|null
$bottom
= null
$left
The left border.
private
TableStrokeStyle|null
$left
= null
$right
The right border.
private
TableStrokeStyle|null
$right
= null
$top
The top border.
private
TableStrokeStyle|null
$top
= null
Methods
jsonSerialize()
{@inheritdoc}
public
jsonSerialize() : array<string, mixed>
Return values
array<string, mixed>setAll()
Set all borders.
public
setAll(TableStrokeStyle $stroke) : $this
Parameters
- $stroke : TableStrokeStyle
-
The stroke style.
Return values
$thissetBottom()
Set the bottom border.
public
setBottom(TableStrokeStyle $stroke) : $this
Parameters
- $stroke : TableStrokeStyle
-
The stroke style.
Return values
$thissetLeft()
Set the left border.
public
setLeft(TableStrokeStyle $stroke) : $this
Parameters
- $stroke : TableStrokeStyle
-
The stroke style.
Return values
$thissetRight()
Set the right border.
public
setRight(TableStrokeStyle $stroke) : $this
Parameters
- $stroke : TableStrokeStyle
-
The stroke style.
Return values
$thissetTop()
Set the top border.
public
setTop(TableStrokeStyle $stroke) : $this
Parameters
- $stroke : TableStrokeStyle
-
The stroke style.
Return values
$thisuniform()
Create a uniform border.
public
static uniform(string $color[, int $width = 1 ]) : self
Parameters
- $color : string
-
The border color.
- $width : int = 1
-
The border width.
Return values
self —A new instance.