OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
API
/
vendor
/
zircote
/
swagger-php
/
src
/
Annotations
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/07/2024 04:34:30 AM
rwxr-xr-x
📄
AbstractAnnotation.php
29.5 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
AdditionalProperties.php
806 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Attachable.php
1.72 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Components.php
3.46 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Contact.php
1.13 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
CookieParameter.php
317 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Delete.php
320 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Discriminator.php
1.66 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Examples.php
2.29 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
ExternalDocumentation.php
1.53 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Flow.php
2.12 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Get.php
314 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Head.php
316 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Header.php
2.12 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
HeaderParameter.php
349 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Info.php
2.06 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Items.php
1.48 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
JsonContent.php
825 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
License.php
2.2 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Link.php
3.22 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
MediaType.php
2.26 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
OpenApi.php
8.44 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Operation.php
7.37 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Options.php
322 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Parameter.php
8.53 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Patch.php
318 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
PathItem.php
3.71 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
PathParameter.php
406 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Post.php
316 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Property.php
952 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Put.php
314 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
QueryParameter.php
345 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
RequestBody.php
2.57 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Response.php
3.33 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Schema.php
16.2 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
SecurityScheme.php
3 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Server.php
1.89 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
ServerVariable.php
1.89 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Tag.php
1.22 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
Trace.php
318 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Webhook.php
686 bytes
08/07/2024 04:34:28 AM
rw-r--r--
📄
Xml.php
2.34 KB
08/07/2024 04:34:28 AM
rw-r--r--
📄
XmlContent.php
851 bytes
08/07/2024 04:34:28 AM
rw-r--r--
Editing: Components.php
Close
<?php declare(strict_types=1); /** * @license Apache 2.0 */ namespace OpenApi\Annotations; use OpenApi\Generator; use OpenApi\Util; /** * Holds a set of reusable objects for different aspects of the OA. * * All objects defined within the components object will have no effect on the API unless they are explicitly * referenced from properties outside the components object. * * @see [OAI Components Object](https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#components-object) * * @Annotation */ class Components extends AbstractAnnotation { public const COMPONENTS_PREFIX = '#/components/'; /** * Schema reference. * * @var string */ public const SCHEMA_REF = '#/components/schemas/'; /** * Reusable Schemas. * * @var array<Schema|\OpenApi\Attributes\Schema> */ public $schemas = Generator::UNDEFINED; /** * Reusable Responses. * * @var Response[] */ public $responses = Generator::UNDEFINED; /** * Reusable Parameters. * * @var Parameter[] */ public $parameters = Generator::UNDEFINED; /** * Reusable Examples. * * @var array<Examples> */ public $examples = Generator::UNDEFINED; /** * Reusable Request Bodies. * * @var RequestBody[] */ public $requestBodies = Generator::UNDEFINED; /** * Reusable Headers. * * @var Header[] */ public $headers = Generator::UNDEFINED; /** * Reusable Security Schemes. * * @var SecurityScheme[] */ public $securitySchemes = Generator::UNDEFINED; /** * Reusable Links. * * @var Link[] */ public $links = Generator::UNDEFINED; /** * Reusable Callbacks. * * @var array */ public $callbacks = Generator::UNDEFINED; /** * @inheritdoc */ public static $_parents = [ OpenApi::class, ]; /** * @inheritdoc */ public static $_nested = [ Response::class => ['responses', 'response'], Parameter::class => ['parameters', 'parameter'], PathParameter::class => ['parameters', 'parameter'], RequestBody::class => ['requestBodies', 'request'], Examples::class => ['examples', 'example'], Header::class => ['headers', 'header'], SecurityScheme::class => ['securitySchemes', 'securityScheme'], Link::class => ['links', 'link'], Schema::class => ['schemas', 'schema'], Attachable::class => ['attachables'], ]; /** * Generate a `#/components/...` reference for the given annotation. * * A `string` component value always assumes type `Schema`. * * @param AbstractAnnotation|string $component */ public static function ref($component, bool $encode = true): string { if ($component instanceof AbstractAnnotation) { foreach (Components::$_nested as $type => $nested) { // exclude attachables if (2 == count($nested)) { if ($component instanceof $type) { $type = $nested[0]; $name = $component->{$nested[1]}; break; } } } } else { $type = 'schemas'; $name = $component; } return self::COMPONENTS_PREFIX . $type . '/' . ($encode ? Util::refEncode((string) $name) : $name); } }