23 lines
372 B
PHP
23 lines
372 B
PHP
|
<?php
|
||
|
|
||
|
namespace Nest\Database\PostgreSql\Columns;
|
||
|
|
||
|
use Stringable;
|
||
|
|
||
|
/**
|
||
|
* PostgreSQL fixed-length bit string column type.
|
||
|
*/
|
||
|
class Bit implements Stringable
|
||
|
{
|
||
|
/**
|
||
|
* @param int $size Size of the fixed-length bit string column type.
|
||
|
*/
|
||
|
public function __construct(protected int $size)
|
||
|
{}
|
||
|
|
||
|
public function __toString(): string
|
||
|
{
|
||
|
return "bit($this->size)";
|
||
|
}
|
||
|
}
|