Skip to content

Commit 295c651

Browse files
committed
Renaming PropertyAttributes folder to Property
1 parent db9d936 commit 295c651

22 files changed

+39
-39
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Then you can define the properties of the class and their types.
1313

1414
```php
1515
use Nuxtifyts\PhpDto\Data;
16-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Computed;
16+
use Nuxtifyts\PhpDto\Attributes\Property\Computed;
1717

1818
final readonly class UserData extends Data
1919
{

docs/PropertyAttributes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ This can be done using the `Computed` attribute.
1212

1313
```php
1414
use Nuxtifyts\PhpDto\Data;
15-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Computed;
15+
use Nuxtifyts\PhpDto\Attributes\Property\Computed;
1616

1717
final readonly class Person extends Data
1818
{

docs/SupportedTypes.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ Array of scalar type
145145
To declare an array of scalar type, you can use the `ArrayOfScalarType` attribute:
146146

147147
```php
148-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfScalarTypes;use Nuxtifyts\PhpDto\Data;use Nuxtifyts\PhpDto\Enums\Property\Type;
148+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfScalarTypes;use Nuxtifyts\PhpDto\Data;use Nuxtifyts\PhpDto\Enums\Property\Type;
149149

150150
final readonly class Person extends Data
151151
{
@@ -214,7 +214,7 @@ Array of backed enums
214214
Using `ArrayOfBackedEnum` attribute, you can declare an array of `BackedEnum` type:
215215

216216
```php
217-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfBackedEnums;use Nuxtifyts\PhpDto\Data;
217+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfBackedEnums;use Nuxtifyts\PhpDto\Data;
218218

219219
final readonly class User extends Data
220220
{
@@ -235,7 +235,7 @@ Array of DateTime
235235
To declare an array of `DateTime` type, you can use the `ArrayOfDateTimes` attribute:
236236

237237
```php
238-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfDateTimes;
238+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfDateTimes;
239239

240240
final readonly class User extends Data
241241
{
@@ -256,7 +256,7 @@ Array of Data
256256
To declare an array of `Data` type, you can use the `ArrayOfData` attribute:
257257

258258
```php
259-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
259+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
260260

261261
final readonly class UserGroup extends Data
262262
{
@@ -274,7 +274,7 @@ final readonly class UserGroup extends Data
274274
It is possible to use multiple types of data objects in the array:
275275

276276
```php
277-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
277+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
278278

279279
final readonly class UserGroup extends Data
280280
{
@@ -313,7 +313,7 @@ Array keys
313313
Array keys are kept where hydrating the data object, or when serializing:
314314

315315
```php
316-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
316+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfData;use Nuxtifyts\PhpDto\Data;
317317

318318
final readonly class UserGroup extends Data
319319
{
@@ -398,7 +398,7 @@ final readonly class Person extends Data
398398
The exact same rules apply for array as well:
399399

400400
```php
401-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfData;use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfScalarTypes;use Nuxtifyts\PhpDto\Data;use Nuxtifyts\PhpDto\Enums\Property\Type;
401+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfData;use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfScalarTypes;use Nuxtifyts\PhpDto\Data;use Nuxtifyts\PhpDto\Enums\Property\Type;
402402

403403
final readonly class UserGroup extends Data
404404
{

src/Attributes/PropertyAttributes/Computed.php renamed to src/Attributes/Property/Computed.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Nuxtifyts\PhpDto\Attributes\PropertyAttributes;
3+
namespace Nuxtifyts\PhpDto\Attributes\Property;
44

55
use Attribute;
66

src/Attributes/PropertyAttributes/Types/ArrayOfBackedEnums.php renamed to src/Attributes/Property/Types/ArrayOfBackedEnums.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types;
3+
namespace Nuxtifyts\PhpDto\Attributes\Property\Types;
44

55
use Attribute;
66
use BackedEnum;

src/Attributes/PropertyAttributes/Types/ArrayOfData.php renamed to src/Attributes/Property/Types/ArrayOfData.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types;
3+
namespace Nuxtifyts\PhpDto\Attributes\Property\Types;
44

55
use Attribute;
66
use Exception;

src/Attributes/PropertyAttributes/Types/ArrayOfDateTimes.php renamed to src/Attributes/Property/Types/ArrayOfDateTimes.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types;
3+
namespace Nuxtifyts\PhpDto\Attributes\Property\Types;
44

55
use Attribute;
66
use DateTime;

src/Attributes/PropertyAttributes/Types/ArrayOfScalarTypes.php renamed to src/Attributes/Property/Types/ArrayOfScalarTypes.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types;
3+
namespace Nuxtifyts\PhpDto\Attributes\Property\Types;
44

55
use Attribute;
66
use InvalidArgumentException;

src/Contexts/PropertyContext.php

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

33
namespace Nuxtifyts\PhpDto\Contexts;
44

5-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Computed;
5+
use Nuxtifyts\PhpDto\Attributes\Property\Computed;
66
use Nuxtifyts\PhpDto\Enums\Property\Type;
77
use Nuxtifyts\PhpDto\Exceptions\DeserializeException;
88
use Nuxtifyts\PhpDto\Exceptions\SerializeException;

src/Contexts/TypeContext/ResolvesArraySubContexts.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
namespace Nuxtifyts\PhpDto\Contexts\TypeContext;
44

55
use InvalidArgumentException;
6-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfBackedEnums;
7-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfData;
8-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfDateTimes;
9-
use Nuxtifyts\PhpDto\Attributes\PropertyAttributes\Types\ArrayOfScalarTypes;
6+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfBackedEnums;
7+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfData;
8+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfDateTimes;
9+
use Nuxtifyts\PhpDto\Attributes\Property\Types\ArrayOfScalarTypes;
1010
use Nuxtifyts\PhpDto\Contexts\TypeContext;
1111
use Nuxtifyts\PhpDto\Enums\Property\Type;
1212
use ReflectionProperty;

0 commit comments

Comments
 (0)