for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* @file ATTENTION!!! The code below was carefully crafted by a mean machine.
* Please consider to NOT put any emotional human-generated modifications as the splendid AI will throw them away with no mercy.
*/
namespace Swaggest\JsonSchema\SwaggerSchema;
use Swaggest\JsonSchema\Constraint\Properties;
use Swaggest\JsonSchema\Schema as JsonBasicSchema;
use Swaggest\JsonSchema\Structure\ClassStructure;
class ExternalDocs extends ClassStructure {
/** @var string */
public $description;
public $url;
* @param Properties|static $properties
* @param JsonBasicSchema $ownerSchema
public static function setUpProperties($properties, JsonBasicSchema $ownerSchema)
{
$properties->description = JsonBasicSchema::string();
$properties->url = JsonBasicSchema::string();
$properties->url->format = 'uri';
$ownerSchema->type = 'object';
'object'
string
array
$type
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..
$ownerSchema->additionalProperties = false;
$ownerSchema->patternProperties['^x-'] = new JsonBasicSchema();
$ownerSchema->patternProperties['^x-']->description = 'Any property starting with x- is valid.';
$ownerSchema->description = 'information about external documentation';
$ownerSchema->required = array (
0 => 'url',
);
}
* @param string $description
* @return $this
public function setDescription($description)
$this->description = $description;
return $this;
* @param string $url
public function setUrl($url)
$this->url = $url;
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..