-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #39 from sunrise-php/release/v3.12.0
v3.12.0
- Loading branch information
Showing
10 changed files
with
201 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<?php | ||
|
||
/** | ||
* It's free open-source software released under the MIT License. | ||
* | ||
* @author Anatoly Nekhay <[email protected]> | ||
* @copyright Copyright (c) 2021, Anatoly Nekhay | ||
* @license https://github.com/sunrise-php/hydrator/blob/master/LICENSE | ||
* @link https://github.com/sunrise-php/hydrator | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Sunrise\Hydrator\Annotation; | ||
|
||
use Attribute; | ||
|
||
/** | ||
* @Annotation | ||
* @Target({"PROPERTY"}) | ||
* @NamedArgumentConstructor | ||
* | ||
* @Attributes({ | ||
* @Attribute("value", type="mixed", required=true), | ||
* }) | ||
* | ||
* @since 3.12.0 | ||
*/ | ||
#[Attribute(Attribute::TARGET_PROPERTY)] | ||
final class DefaultValue | ||
{ | ||
|
||
/** | ||
* The attribute value | ||
* | ||
* @var mixed | ||
* | ||
* @readonly | ||
*/ | ||
public $value; | ||
|
||
/** | ||
* Constructor of the class | ||
* | ||
* @param mixed $value | ||
*/ | ||
public function __construct($value) | ||
{ | ||
$this->value = $value; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.