This commit is contained in:
2023-04-15 23:31:16 +08:00
parent 2d9ac93a7a
commit 41a53200b3
69 changed files with 1678 additions and 749 deletions
+5 -3
View File
@@ -1,7 +1,8 @@
<?php
namespace Kiri\Inject\Validator\Inject;
namespace Kiri\Router\Validator\Inject;
use Kiri\Router\Interface\ValidatorInterface;
#[\Attribute(\Attribute::TARGET_PROPERTY)]
class Max implements ValidatorInterface
@@ -17,12 +18,13 @@ class Max implements ValidatorInterface
/**
* @param object $class
* @param string $name
* @return bool
*/
public function dispatch(string $name): bool
public function dispatch(object $class, string $name): bool
{
// TODO: Implement dispatch() method.
return true;
return $class->{$name} <= $this->value;
}
}