Skip to content

Commit

Permalink
update gen
Browse files Browse the repository at this point in the history
  • Loading branch information
chriskapp committed Nov 22, 2024
1 parent 73c2dca commit 6cbbba2
Show file tree
Hide file tree
Showing 27 changed files with 138 additions and 748 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
}
],
"require": {
"psx/schema": "^7.0"
"typeschema/model": "^0.1"
},
"require-dev": {
"vimeo/psalm": "^5.0"
Expand Down
12 changes: 12 additions & 0 deletions sdkgen.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"type": "model-php",
"require": {
"typehub/typeapi": {
"target": "./src",
"namespace": "TypeAPI\\Model",
"mapping": {
"typeschema": "TypeSchema\\Model"
}
}
}
}
13 changes: 0 additions & 13 deletions src/AnyPropertyType.php

This file was deleted.

44 changes: 22 additions & 22 deletions src/Argument.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,30 +9,14 @@
#[Description('')]
class Argument implements \JsonSerializable, \PSX\Record\RecordableInterface
{
#[Description('The location where the value can be found either in the path, query, header or body. If you choose path, then your path must have a fitting variable path fragment')]
protected ?string $in = null;
#[Description('')]
protected ?PropertyType $schema = null;
#[Description('In case the data is not a JSON payload which you can describe with a schema you can select a content type')]
protected ?string $contentType = null;
#[Description('The location where the value can be found either in the path, query, header or body. If you choose path, then your path must have a fitting variable path fragment')]
protected ?string $in = null;
#[Description('Optional the actual path, query or header name. If not provided the key of the argument map is used')]
protected ?string $name = null;
public function setIn(?string $in) : void
{
$this->in = $in;
}
public function getIn() : ?string
{
return $this->in;
}
public function setSchema(?PropertyType $schema) : void
{
$this->schema = $schema;
}
public function getSchema() : ?PropertyType
{
return $this->schema;
}
#[Description('')]
protected ?\TypeSchema\Model\PropertyType $schema = null;
public function setContentType(?string $contentType) : void
{
$this->contentType = $contentType;
Expand All @@ -41,6 +25,14 @@ public function getContentType() : ?string
{
return $this->contentType;
}
public function setIn(?string $in) : void
{
$this->in = $in;
}
public function getIn() : ?string
{
return $this->in;
}
public function setName(?string $name) : void
{
$this->name = $name;
Expand All @@ -49,14 +41,22 @@ public function getName() : ?string
{
return $this->name;
}
public function setSchema(?\TypeSchema\Model\PropertyType $schema) : void
{
$this->schema = $schema;
}
public function getSchema() : ?\TypeSchema\Model\PropertyType
{
return $this->schema;
}
public function toRecord() : \PSX\Record\RecordInterface
{
/** @var \PSX\Record\Record<mixed> $record */
$record = new \PSX\Record\Record();
$record->put('in', $this->in);
$record->put('schema', $this->schema);
$record->put('contentType', $this->contentType);
$record->put('in', $this->in);
$record->put('name', $this->name);
$record->put('schema', $this->schema);
return $record;
}
public function jsonSerialize() : object
Expand Down
13 changes: 0 additions & 13 deletions src/ArrayDefinitionType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/ArrayPropertyType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/BooleanPropertyType.php

This file was deleted.

39 changes: 0 additions & 39 deletions src/CollectionDefinitionType.php

This file was deleted.

34 changes: 0 additions & 34 deletions src/CollectionPropertyType.php

This file was deleted.

59 changes: 0 additions & 59 deletions src/DefinitionType.php

This file was deleted.

34 changes: 0 additions & 34 deletions src/GenericPropertyType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/IntegerPropertyType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/MapDefinitionType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/MapPropertyType.php

This file was deleted.

13 changes: 0 additions & 13 deletions src/NumberPropertyType.php

This file was deleted.

Loading

0 comments on commit 6cbbba2

Please sign in to comment.