20250330#1

This commit is contained in:
User
2025-03-30 13:28:30 +03:00
parent 96ee46476c
commit fd996d40c8
9 changed files with 193 additions and 39 deletions

14
src/Attribute/Entity.php Normal file
View File

@@ -0,0 +1,14 @@
<?php
namespace Rmphp\Storage\Attribute;
use Attribute;
#[Attribute(Attribute::TARGET_CLASS)]
class Entity {
public function __construct(
public bool $withoutEmpty = false,
) {}
}

View File

@@ -0,0 +1,16 @@
<?php
namespace Rmphp\Storage\Attribute;
use Attribute;
#[Attribute(Attribute::TARGET_PROPERTY)]
class GetProperty {
public function __construct(
public ?string $keyName = null,
public bool $empty = false,
public bool $emptyIfNull = false,
) {}
}

View File

@@ -0,0 +1,8 @@
<?php
namespace Rmphp\Storage\Attribute;
use Attribute;
#[Attribute(Attribute::TARGET_PROPERTY)]
class GetPropertyEmpty {}

View File

@@ -0,0 +1,8 @@
<?php
namespace Rmphp\Storage\Attribute;
use Attribute;
#[Attribute(Attribute::TARGET_PROPERTY)]
class GetPropertyEmptyIfNull {}

View File

@@ -0,0 +1,14 @@
<?php
namespace Rmphp\Storage\Attribute;
use Attribute;
#[Attribute(Attribute::TARGET_CLASS)]
class ValueObject {
public function __construct(
public ?string $propertyName = null,
) {}
}