use Darksparrow\DeegraphInteractions\Attributes\QueryBuilderRequiredField;
use Darksparrow\DeegraphInteractions\Exceptions\QueryBuilderConflictingFieldAlreadyExistsException;
use Darksparrow\DeegraphInteractions\Exceptions\QueryBuilderConflictingFieldAlreadyExistsException;
use Darksparrow\DeegraphInteractions\Exceptions\QueryBuilderInvalidInputException;
use Darksparrow\DeegraphInteractions\Exceptions\QueryBuilderInvalidInputException;
use Darksparrow\DeegraphInteractions\QueryBuilder\DirectoryQuery\DirectoryQueryBuilder;
use Darksparrow\DeegraphInteractions\QueryBuilder\InsertQuery\InsertQuery;
use Darksparrow\DeegraphInteractions\QueryBuilder\InsertQuery\InsertQueryBuilder;
use Darksparrow\DeegraphInteractions\QueryBuilder\PermissionsQuery\PermissionQueryBuilder;
use Darksparrow\DeegraphInteractions\QueryBuilder\PutQuery\PutQueryBuilder;
use Darksparrow\DeegraphInteractions\QueryBuilder\SelectQuery\SelectQueryBuilder;
use ReflectionClass;
trait QueryBuilderTrait
trait QueryBuilderTrait
{
{
@ -22,8 +30,41 @@ trait QueryBuilderTrait
protected function ValidateDeegraphPath(string $target): string
protected function ValidateDeegraphPath(string $target): string
{
{
if (!preg_match(pattern: "(^(\{[0-9a-f]{8}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{12}\})$)|(^\{[0-9a-f]{8}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{12}\}(\/([a-z][a-z0-9]*|[0-9]+|#|\*))+$)|(^(([a-z][a-z0-9]*|[0-9]+|#|\*))(\/([a-z][a-z0-9]*|[0-9]+|#|\*))*$)", subject: $target))
if (!preg_match(pattern: "/(^(\{[0-9a-f]{8}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{12}\})$)|(^\{[0-9a-f]{8}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{4}\b-[0-9a-f]{12}\}(\/([a-z][a-z0-9]*|[0-9]+|#|\*))+$)|(^(([a-z][a-z0-9]*|[0-9]+|#|\*))(\/([a-z][a-z0-9]*|[0-9]+|#|\*))*$)/", subject: $target))