OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
aws-ses
/
vendor
/
aws
/
aws-sdk-php
/
src
/
Api
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/14/2024 10:55:35 AM
rwxr-xr-x
📄
AbstractModel.php
2.04 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
ApiProvider.php
7.71 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
DateTimeResult.php
3.77 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
DocModel.php
3.52 KB
08/14/2024 10:51:44 AM
rw-r--r--
📁
ErrorParser
-
08/14/2024 10:54:03 AM
rwxr-xr-x
📄
ListShape.php
821 bytes
08/14/2024 10:51:44 AM
rw-r--r--
📄
MapShape.php
1.2 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
Operation.php
3.51 KB
08/14/2024 10:51:44 AM
rw-r--r--
📁
Parser
-
08/14/2024 10:56:10 AM
rwxr-xr-x
📁
Serializer
-
08/14/2024 10:54:11 AM
rwxr-xr-x
📄
Service.php
14.05 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
Shape.php
1.89 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
ShapeMap.php
1.53 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
StructureShape.php
1.72 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
TimestampShape.php
1.49 KB
08/14/2024 10:51:44 AM
rw-r--r--
📄
Validator.php
10.38 KB
08/14/2024 10:51:44 AM
rw-r--r--
Editing: Shape.php
Close
<?php namespace Aws\Api; /** * Base class representing a modeled shape. */ class Shape extends AbstractModel { /** * Get a concrete shape for the given definition. * * @param array $definition * @param ShapeMap $shapeMap * * @return mixed * @throws \RuntimeException if the type is invalid */ public static function create(array $definition, ShapeMap $shapeMap) { static $map = [ 'structure' => StructureShape::class, 'map' => MapShape::class, 'list' => ListShape::class, 'timestamp' => TimestampShape::class, 'integer' => Shape::class, 'double' => Shape::class, 'float' => Shape::class, 'long' => Shape::class, 'string' => Shape::class, 'byte' => Shape::class, 'character' => Shape::class, 'blob' => Shape::class, 'boolean' => Shape::class ]; if (isset($definition['shape'])) { return $shapeMap->resolve($definition); } if (!isset($map[$definition['type']])) { throw new \RuntimeException('Invalid type: ' . print_r($definition, true)); } $type = $map[$definition['type']]; return new $type($definition, $shapeMap); } /** * Get the type of the shape * * @return string */ public function getType() { return $this->definition['type']; } /** * Get the name of the shape * * @return string */ public function getName() { return $this->definition['name']; } /** * Get a context param definition. */ public function getContextParam() { return $this->contextParam; } }