22 lines
623 B
PHP

<?php
namespace Ulmus\Attribute\Property\Field;
#[\Attribute(\Attribute::TARGET_PROPERTY)]
class Id extends \Ulmus\Attribute\Property\Field {
public function __construct(
public ? string $name = null,
public ? string $type = 'bigint',
public null|int|string $length = null,
public ? int $precision = null,
public array $attributes = [
'unsigned' => true,
'auto_increment' => true,
'primary_key' => true,
],
public bool $nullable = false,
public mixed $default = null,
public bool $readonly = true,
) {}
}