Skip to content

Commit a8a22be

Browse files
committed
Replace value objects
1 parent 549cd14 commit a8a22be

24 files changed

+211
-203
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@
3636
"fiunchinho/phpunit-randomizer": "~2.0",
3737
"seld/jsonlint": "1.3.*",
3838
"bruli/ignore-files": "~1.0",
39-
"beberlei/assert": "^2.5"
39+
"beberlei/assert": "^2.5",
40+
"bruli/php-value-objects": "^0.1.0"
4041
},
4142
"require-dev": {
4243
"composer/composer": "^1.0@dev",

composer.lock

Lines changed: 183 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/PhpGitHooks/Module/Configuration/Domain/Enabled.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\BooleanValueObject;
5+
use PhpValueObjects\Tests\Scalar\BooleanValueObject;
66

77
class Enabled extends BooleanValueObject
88
{

src/PhpGitHooks/Module/Configuration/Domain/Level.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\BooleanValueObject;
5+
use PhpValueObjects\Scalar\BooleanValueObject;
66

77
class Level extends BooleanValueObject
88
{

src/PhpGitHooks/Module/Configuration/Domain/Message.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\StringLiteralValueObject;
6-
use PhpGitHooks\Module\Shared\Model\NullableInterface;
5+
use PhpValueObjects\NullableInterface;
6+
use PhpValueObjects\Scalar\StringLiteral;
77

8-
class Message extends StringLiteralValueObject implements NullableInterface
8+
class Message extends StringLiteral implements NullableInterface
99
{
1010
}

src/PhpGitHooks/Module/Configuration/Domain/MinimumStrictCoverage.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\FloatValueObject;
6-
use PhpGitHooks\Module\Shared\Model\NullableInterface;
5+
use PhpValueObjects\NullableInterface;
6+
use PhpValueObjects\Scalar\FloatValueObject;
77

88
class MinimumStrictCoverage extends FloatValueObject implements NullableInterface
99
{

src/PhpGitHooks/Module/Configuration/Domain/PhpCsStandard.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,17 @@
33
namespace PhpGitHooks\Module\Configuration\Domain;
44

55
use PhpGitHooks\Module\Configuration\Contract\Exception\InvalidPhpCsStandardException;
6-
use PhpGitHooks\Module\Shared\Domain\StringLiteralValueObject;
7-
use PhpGitHooks\Module\Shared\Model\NullableInterface;
6+
use PhpValueObjects\NullableInterface;
7+
use PhpValueObjects\Scalar\StringLiteral;
88

9-
class PhpCsStandard extends StringLiteralValueObject implements NullableInterface
9+
class PhpCsStandard extends StringLiteral implements NullableInterface
1010
{
1111
/**
1212
* @param string $value
1313
*
1414
* @return bool|void
1515
*
1616
* @throws InvalidPhpCsStandardException
17-
* @throws \Module\Shared\Contract\Exception\InvalidStringException
1817
*/
1918
protected function guard($value)
2019
{

src/PhpGitHooks/Module/Configuration/Domain/PhpMdOptions.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\StringLiteralValueObject;
6-
use PhpGitHooks\Module\Shared\Model\NullableInterface;
5+
use PhpValueObjects\NullableInterface;
6+
use PhpValueObjects\Scalar\StringLiteral;
77

8-
class PhpMdOptions extends StringLiteralValueObject implements NullableInterface
8+
class PhpMdOptions extends StringLiteral implements NullableInterface
99
{
1010
}

src/PhpGitHooks/Module/Configuration/Domain/PhpUnitOptions.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\StringLiteralValueObject;
6-
use PhpGitHooks\Module\Shared\Model\NullableInterface;
5+
use PhpValueObjects\NullableInterface;
6+
use PhpValueObjects\Scalar\StringLiteral;
77

8-
class PhpUnitOptions extends StringLiteralValueObject implements NullableInterface
8+
class PhpUnitOptions extends StringLiteral implements NullableInterface
99
{
1010
}

src/PhpGitHooks/Module/Configuration/Domain/PhpUnitRandomMode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace PhpGitHooks\Module\Configuration\Domain;
44

5-
use PhpGitHooks\Module\Shared\Domain\BooleanValueObject;
5+
use PhpValueObjects\Scalar\BooleanValueObject;
66

77
class PhpUnitRandomMode extends BooleanValueObject
88
{

0 commit comments

Comments
 (0)