Skip to content

Commit

Permalink
Merge pull request #8 from gocanto/rename-ns
Browse files Browse the repository at this point in the history
Replace namespace
  • Loading branch information
gocanto authored Apr 19, 2020
2 parents 8b8ed10 + 401bf00 commit baa931f
Show file tree
Hide file tree
Showing 37 changed files with 142 additions and 140 deletions.
20 changes: 11 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
{
"name": "gocanto/attributes",
"name": "gocanto/relay",
"type": "php-bundle",
"description": "Framework agnostic attributes bag with validations rules.",
"description": "Unify data transfer object that is framework agnostic.",
"keywords": [
"php",
"attributes",
"bag"
"data",
"bag",
"transfer",
"object"
],
"homepage": "https://github.com/gocanto/attributes",
"homepage": "https://github.com/gocanto/relay",
"license": "MIT",
"authors": [
{
Expand Down Expand Up @@ -35,12 +37,12 @@
},
"autoload": {
"psr-4": {
"Gocanto\\Attributes\\": "src"
"Gocanto\\Relay\\": "src"
}
},
"autoload-dev": {
"psr-4": {
"Gocanto\\Attributes\\Tests\\": "tests"
"Gocanto\\Relay\\Tests\\": "tests"
}
},
"minimum-stability": "dev",
Expand All @@ -60,7 +62,7 @@
]
},
"support": {
"issues": "https://github.com/gocanto/attributes/issues",
"source": "https://github.com/gocanto/attributes"
"issues": "https://github.com/gocanto/relay/issues",
"source": "https://github.com/gocanto/relay"
}
}
8 changes: 4 additions & 4 deletions src/Attributes.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
* file that was distributed with this source code.
*/

namespace Gocanto\Attributes;
namespace Gocanto\Relay;

use Gocanto\Attributes\Support\AttributesCollection;
use Gocanto\Attributes\Types\Any;
use Gocanto\Attributes\Support\PromotersCollection;
use Gocanto\Relay\Support\AttributesCollection;
use Gocanto\Relay\Types\Any;
use Gocanto\Relay\Support\PromotersCollection;

abstract class Attributes
{
Expand Down
2 changes: 1 addition & 1 deletion src/AttributesException.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* file that was distributed with this source code.
*/

namespace Gocanto\Attributes;
namespace Gocanto\Relay;

use Exception;
use Throwable;
Expand Down
6 changes: 3 additions & 3 deletions src/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes;
namespace Gocanto\Relay;

use Gocanto\Attributes\Support\AttributesCollection;
use Gocanto\Attributes\Support\PromotersCollection;
use Gocanto\Relay\Support\AttributesCollection;
use Gocanto\Relay\Support\PromotersCollection;

class Builder
{
Expand Down
2 changes: 1 addition & 1 deletion src/Promoter.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Gocanto\Attributes;
namespace Gocanto\Relay;

class Promoter
{
Expand Down
2 changes: 1 addition & 1 deletion src/Support/Arr.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Support;
namespace Gocanto\Relay\Support;

use ArrayAccess;

Expand Down
6 changes: 3 additions & 3 deletions src/Support/AttributesCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Support;
namespace Gocanto\Relay\Support;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;

class AttributesCollection
{
Expand Down
10 changes: 5 additions & 5 deletions src/Support/PromotersCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Support;
namespace Gocanto\Relay\Support;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Promoter;
use Gocanto\Attributes\Type;
use Gocanto\Attributes\Types\Any;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Promoter;
use Gocanto\Relay\Type;
use Gocanto\Relay\Types\Any;

class PromotersCollection
{
Expand Down
2 changes: 1 addition & 1 deletion src/Type.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Gocanto\Attributes;
namespace Gocanto\Relay;

interface Type
{
Expand Down
4 changes: 2 additions & 2 deletions src/Types/Any.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\Type;
use Gocanto\Relay\Type;
use JsonException;

class Any implements Type
Expand Down
4 changes: 2 additions & 2 deletions src/Types/Assert.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Relay\AttributesException;
use Symfony\Component\Validator\Validation;

class Assert
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Boolean.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Symfony\Component\Validator\Constraints\Type as TypeValidator;

class Boolean implements Type
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Constraints.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Support\Arr;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Support\Arr;
use Symfony\Component\Validator\Constraint;

class Constraints
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Date.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Carbon\CarbonImmutable;
use Carbon\CarbonInterface;
use DateTimeInterface;
use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Throwable;

class Date implements Type
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Decimal.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;

class Decimal implements Type
{
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Email.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Symfony\Component\Validator\Constraints\Email as EmailConstraint;

class Email implements Type
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Integer.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;

class Integer implements Type
{
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Text.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Symfony\Component\Validator\Constraints\Type as TypeValidator;

class Text implements Type
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Url.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Symfony\Component\Validator\Constraints\Url as UrlConstraint;

class Url implements Type
Expand Down
6 changes: 3 additions & 3 deletions src/Types/Uuid.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Types;
namespace Gocanto\Relay\Types;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Type;
use Symfony\Component\Validator\Constraints\Uuid as UuidConstraint;

class Uuid implements Type
Expand Down
4 changes: 2 additions & 2 deletions tests/AttributesExceptionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests;
namespace Gocanto\Relay\Tests;

use Exception;
use Gocanto\Attributes\AttributesException;
use Gocanto\Relay\AttributesException;
use PHPUnit\Framework\TestCase;

class AttributesExceptionTest extends TestCase
Expand Down
16 changes: 8 additions & 8 deletions tests/AttributesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Promoter;
use Gocanto\Attributes\Tests\Stubs\Payload;
use Gocanto\Attributes\Types\Any;
use Gocanto\Attributes\Types\Text;
use Gocanto\Attributes\Types\Url;
namespace Gocanto\Relay\Tests;

use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Promoter;
use Gocanto\Relay\Tests\Stubs\Payload;
use Gocanto\Relay\Types\Any;
use Gocanto\Relay\Types\Text;
use Gocanto\Relay\Types\Url;
use PHPUnit\Framework\TestCase;

class AttributesTest extends TestCase
Expand Down
10 changes: 5 additions & 5 deletions tests/PromoterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests;
namespace Gocanto\Relay\Tests;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Promoter;
use Gocanto\Attributes\Tests\Stubs\Payload;
use Gocanto\Attributes\Types\Url;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Promoter;
use Gocanto\Relay\Tests\Stubs\Payload;
use Gocanto\Relay\Types\Url;
use PHPUnit\Framework\TestCase;

class PromoterTest extends TestCase
Expand Down
4 changes: 2 additions & 2 deletions tests/Stubs/Payload.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests\Stubs;
namespace Gocanto\Relay\Tests\Stubs;

use Gocanto\Attributes\Attributes;
use Gocanto\Relay\Attributes;

class Payload extends Attributes
{
Expand Down
4 changes: 2 additions & 2 deletions tests/Support/ArrTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests\Support;
namespace Gocanto\Relay\Tests\Support;

use ArrayAccess;
use Gocanto\Attributes\Support\Arr;
use Gocanto\Relay\Support\Arr;
use Mockery;
use PHPUnit\Framework\TestCase;

Expand Down
8 changes: 4 additions & 4 deletions tests/Support/AttributesCollectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

declare(strict_types=1);

namespace Gocanto\Attributes\Tests\Support;
namespace Gocanto\Relay\Tests\Support;

use Gocanto\Attributes\AttributesException;
use Gocanto\Attributes\Support\AttributesCollection;
use Gocanto\Attributes\Type;
use Gocanto\Relay\AttributesException;
use Gocanto\Relay\Support\AttributesCollection;
use Gocanto\Relay\Type;
use Mockery;
use PHPUnit\Framework\TestCase;

Expand Down
Loading

0 comments on commit baa931f

Please sign in to comment.