|
|
@ -2,12 +2,13 @@ |
|
|
|
|
|
|
|
namespace Darksparrow\DeegraphPHP\QueryBuilder\QueryBuilders; |
|
|
|
|
|
|
|
use Darksparrow\DeegraphPHP\Attributes\QueryBuilderRequiredField; |
|
|
|
use Darksparrow\DeegraphPHP\Exceptions\QueryBuilderConflictingFieldAlreadyExistsException; |
|
|
|
use Darksparrow\DeegraphPHP\Exceptions\QueryBuilderInvalidInputException; |
|
|
|
use Darksparrow\DeegraphPHP\Exceptions\QueryBuilderRequiredFieldIsNotSetException; |
|
|
|
use Darksparrow\DeegraphPHP\QueryBuilder\QueryBuilderTrait; |
|
|
|
|
|
|
|
final class Put |
|
|
|
final class PutQuery |
|
|
|
{ |
|
|
|
use QueryBuilderTrait; |
|
|
|
|
|
|
@ -41,7 +42,7 @@ final class Put |
|
|
|
/** |
|
|
|
* @throws QueryBuilderInvalidInputException |
|
|
|
*/ |
|
|
|
public function Schema(string $uri): Put |
|
|
|
public function Schema(string $uri): PutQuery |
|
|
|
{ |
|
|
|
$this->PutWhat = self::Validate( |
|
|
|
target: "SCHEMA \"$uri\"", |
|
|
@ -53,7 +54,7 @@ final class Put |
|
|
|
/** |
|
|
|
* @throws QueryBuilderInvalidInputException |
|
|
|
*/ |
|
|
|
public function URI(string $uri): Put |
|
|
|
public function URI(string $uri): PutQuery |
|
|
|
{ |
|
|
|
$this->PutWhat = self::Validate( |
|
|
|
target: "URI \"$uri\"", |
|
|
@ -65,7 +66,7 @@ final class Put |
|
|
|
/** |
|
|
|
* @throws QueryBuilderInvalidInputException |
|
|
|
*/ |
|
|
|
public function DataURI(string $mimeType, string $data): Put |
|
|
|
public function DataURI(string $mimeType, string $data): PutQuery |
|
|
|
{ |
|
|
|
$this->PutWhat = self::Validate( |
|
|
|
target: "URI \"data:$mimeType;$data\"", |
|
|
@ -79,7 +80,7 @@ final class Put |
|
|
|
* @throws QueryBuilderInvalidInputException |
|
|
|
* @throws QueryBuilderConflictingFieldAlreadyExistsException |
|
|
|
*/ |
|
|
|
public function At(string $node, string $uwu): Put |
|
|
|
public function At(string $node, string $uwu): PutQuery |
|
|
|
{ |
|
|
|
self::EnsureNotSet($this->PutInto); |
|
|
|
$this->PutAt = self::Validate( |
|
|
@ -94,7 +95,7 @@ final class Put |
|
|
|
* @throws QueryBuilderInvalidInputException |
|
|
|
* @throws QueryBuilderConflictingFieldAlreadyExistsException |
|
|
|
*/ |
|
|
|
public function Into(string $relativePath, string $propertyName): Put |
|
|
|
public function Into(string $relativePath, string $propertyName): PutQuery |
|
|
|
{ |
|
|
|
self::EnsureNotSet($this->PutAt); |
|
|
|
$this->PutInto = self::Validate( |
|
|
@ -105,7 +106,7 @@ final class Put |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public function Safe(): Put |
|
|
|
public function Safe(): PutQuery |
|
|
|
{ |
|
|
|
$this->Safe = true; |
|
|
|
return $this; |