ÿØÿà JFIF    ÿÛ „  ( %!1"%)+...383-7(-.+  -%%--------+------------/----------------------------ÿÀ  ¶" ÿÄ     ÿÄ @    !1AQaq‘¡"±ÁÑð2’BRráS‚ñ3b¢CT²Ò #cÿÄ    ÿÄ '   1!AQ2a"‘±#ÿÚ   ? ò(/p‘—–¢·,M|¯G»R£üešT. ôŸEoCFñ‡ 4ÔkåóxR|µÁ¨ÓDà!Ç´µ˜‡p ÍQ‹§!þž^õWsŒy  åÁ§$á«%ºq˜™JyyË0y«^Ϗ -3ÃÏËÈ£Æ\P’ä„s&•‹Üs üô'àWt¹pñCp$bÚF`·7.^)¾!)ÒÙ˜–ÅÏš^h¾ø³·ìe±ŒaeÖ—Í,e=B}Jéߦ$$½—šÙÜCC¯¶è8β–Åkèwx LÉngT±æ¹£Ócœ¿Í/©Éÿ ‰ÚCÒ­mq;Tt¶–}0"zÖPcd1š­¤tˆ„ÐÓâqú[™öUCŠ2޿د­É(¸ßúçšmW,Ò ºf‹Ån™ÄLêÁ8üÁkÁ€L¥ÍuJ1œôrÂSŒÓöt!7EUíïb)AËi¬â-ÙHk8òÁiXYwÅ)O^"ÇØriÛô{»wRUKÙÏÚlÓ¬€‚’שT ] ªb—ÊîKC^×M“xùäñz¬zJ× {4[¹M'IÆeH1LCWÕ]œûº WDæà°OÅ‚¹c²ÞuA–rL`HšpCez‡V’— Ž‚Ë„–ñ­'µR0ÕÖ=À:±G»C\nÆÉ5*¢ †3šhQ4ýÒi$Õ1"Ü]¢p-q3zcQ$ªö¨¥æf›‘»´ÝÚHá„e²JÇ–iÊ:·à¬Øc5Åk»Laª*wi [0Ówk ¦a¦0Õ²ÅÅ‚T¸’³q:Æ<¹ú Ò˜Æ}2VE•Ѐp¡Ô3Úº …h³^LJºçì¥Ánó|˜ÖˆÎˆ+« ¦dø‘Mº–d\ªDðÛ„Ì×LÝ——Ð9Ç|•FèçVm™¨€™3õS–9Äå¢<̉Ìm¢±`·º˜&Z²ž Ë®D«¶»6™‰©­HÈ Àá«h­i³04æ’hxœi3ï¨(ÓL·†‹¶ËpŒ ƒÜÒ? :õdsÀ –3æÓ·Üjâ¬9—]8n¼&]I F£¼…ì–—Œ0v°LǐÅfÛ2TÖ’aµ˜N@ÖBSÏ^à´4-±°b×nÈÈœÆD=KdŒø…ÄÈK,›ÖR§fjü$^ÔÎ!„6^ s:Üun\ôkCÞò÷<—Lúl Í›G¹ÀPá¼Nc¡šÒ…ÙWͳœ±vÊáЄ×9‹P‰cEØ‘™›µŸP<×g1 º©Ø¬wiÁ^l5× I/';Ë+´Z‡ÓÄFÕp[Èð’ HÄ ó 9¬Dl4“é±Ï”V=^Hð;žLädÉa‚°Ë,#/Ž~²BÔÛ QãñQtIeórVB,ÏÂf‹4#Μc‹É3ZIÖ Œ¢¥·üxa‡Ãçè„jŠ[5 Ä!U?,3žÎ×…ðdÓ÷háŠA‰ìÄ4÷ÃÜZÃE{‰®+W\ZÍE[‰»µk»MÝ­`¢©†˜ÃV‹-f¢¡†¢a«eŠ%«Y¨©q%jâd,Ôq`) ¤¦…šˆ ¦E>0Ùb²t–Ÿ  ÷jsςҒKÈcø(é›;k(’#ôŒQ ™C> õ³M9óºÆµ¤çâ;uÀ)5>RÔ¸fÓ~Ȧ—’-$fe«"FâUˆÊwµPÏu w+"åÉó¨6s™Û9(À¨ù©hE°½†n`m~“@©›p!Vkhµ Á1šbEqqÊ@ºèl›2 –Yã%‘‚hÛ{a¶‡ÅÞM²¬çL34®Çl]®‹ŽØŒm'RÜe35æöˆ­Á­ cP9šeÁköo´L³Ì=p8]”‡B¶,šº|ɏdzXˆØk*ÇÚ{#ñ‰pã(€¶‡9ý'šÜ³½¯kƒ†Â’ëSOƒ•Å®H6+a¢µˆ‹Y¨b˜b+XˆÖ!°u!¢"µˆˆn2ˆ Å0Ä`Å Ô®c(ÓÜGº•Ä»Œ âWî%q.áÐÄ÷î%umÍ£+ÜQ,Vn¦-GphU¸¢X­&,Gt ·K¢ÅÅ·¥RÄÊÉbKn N­R2g$VµÕó Qr#–ÓZUÏð0ÎtÙÀœz ëöo“Îk¯n„T°"SÞ+³/…€½"ižãO%Í%&Δâ‘ËØ´IˆÓ°Ë‰ÞM3.™yçÁzit›`4C`k¢¼á!álÄï sÂ[×!¤l¾æo"ƒIÔ'@ªu)3›ô®“@Z à¾] üœ'‡4¸PÞkÁ-qÄH‰ÓÍBd´ÿ —¹°ÄA&ÊUC„öz‚‚RæŠtf¬>˜ÑidšEçÑL÷áý¡V±h§­c¿¥¨ƒ@g¼…Ýö^ÞËc.ž„æ“I[ ª+·zÐÒÚ,½Ð»¶€C›7jk$๖€Ž¾ÅÙpp¶ÍþéΤ ½ØÎŒq ñpæžÅ¥#Øâ49ÃÂK^MYV“,¶Éz_òæ:…;Õ«¦I3âJ£¤û5$7Èxün\â]Êe¯(Ÿ&Ž‹¶2<6Ćf× æ¢ƱqWı[(ÙÂŽç‚T7¨@ÈÉÍß‚ïÙ"&3TYlGށ†)†#5ŠA©^T2ÆÁ†)©†©†¤yGXÁ†©"†)©¼ÅV WS†#©]R–r‹q5ÕbâWþBh¯u+ªÅÄ×ü„nÑ^êkªÁj‰jeœWˆÕÕ`µDµ2Ì+Ä µDµµ5Ô{¤Þ0RF’H÷AÛ<ÊÁ§ ƈæ0Ñ£ê4 öÚµ[¬/1²€â<-¬šö²r×0o×w ´xÐÒË„ g01¬„åEM蛇Ã\6µE›‘fÙO k÷CºnÓ1`iîÒ² áÂ!ÑLÄÿ ³¬\õ*:M=Ç»c‹2[‰ØsÕLò\ŒK L^™üÄN\¶#» Ç\……ßïIœÉ$¸ÎñÍ®ÔHÇ Ûí/´>Li”„†g^$ 7NÍÑÑ2M2ªNg=k½Ð}Ÿl6‡ —JWˆ”ÞéT·+µ¦üÂFè¢Vs6ýÆ4»2+2IÝ9ô9®ÇGÙÇ1+Ä8;*Õ§ž½D*îÑWÚçá3Ma¤·ˆ¥t}š²Ü…Q+Æüµ8HíS”üxGéÁˆ¦Ël„éÈ 5 µÄƒ6äÜ(kIš¯S†fÖ&¸®×v|Äyˆ*禌Éù@7-®Ä[]ÎÖ¿ê`º…=:…žJVnݳvðÖKE¼‚ »mà ÷f®:Ë ™–4rð¡4` ܹçž~‹C=œ…¾Ïj|VDtK.ƒ"9 Ï ­–éXá³6WÒïIL-Ї Ç PK \n~.QuerySerializer.phpnu[api = $api; $this->endpoint = $endpoint; $this->paramBuilder = $paramBuilder ?: new QueryParamBuilder(); } /** * When invoked with an AWS command, returns a serialization array * containing "method", "uri", "headers", and "body" key value pairs. * * @param CommandInterface $command Command to serialize into a request. * @param $endpointProvider Provider used for dynamic endpoint resolution. * @param $clientArgs Client arguments used for dynamic endpoint resolution. * * @return RequestInterface */ public function __invoke( CommandInterface $command, $endpoint = null ) { $operation = $this->api->getOperation($command->getName()); $body = [ 'Action' => $command->getName(), 'Version' => $this->api->getMetadata('apiVersion') ]; $commandArgs = $command->toArray(); // Only build up the parameters when there are parameters to build if ($commandArgs) { $body += call_user_func( $this->paramBuilder, $operation->getInput(), $commandArgs ); } $body = http_build_query($body, '', '&', PHP_QUERY_RFC3986); $headers = [ 'Content-Length' => strlen($body), 'Content-Type' => 'application/x-www-form-urlencoded' ]; if ($endpoint instanceof RulesetEndpoint) { $this->setEndpointV2RequestOptions($endpoint, $headers); } return new Request( 'POST', $this->endpoint, $headers, $body ); } } PK \uo)o)RestSerializer.phpnu[api = $api; $this->endpoint = Psr7\Utils::uriFor($endpoint); } /** * @param CommandInterface $command Command to serialize into a request. * @param $clientArgs Client arguments used for dynamic endpoint resolution. * * @return RequestInterface */ public function __invoke( CommandInterface $command, $endpoint = null ) { $operation = $this->api->getOperation($command->getName()); $commandArgs = $command->toArray(); $opts = $this->serialize($operation, $commandArgs); $headers = isset($opts['headers']) ? $opts['headers'] : []; if ($endpoint instanceof RulesetEndpoint) { $this->setEndpointV2RequestOptions($endpoint, $headers); } $uri = $this->buildEndpoint($operation, $commandArgs, $opts); return new Request( $operation['http']['method'], $uri, $headers, isset($opts['body']) ? $opts['body'] : null ); } /** * Modifies a hash of request options for a payload body. * * @param StructureShape $member Member to serialize * @param array $value Value to serialize * @param array $opts Request options to modify. */ abstract protected function payload( StructureShape $member, array $value, array &$opts ); private function serialize(Operation $operation, array $args) { $opts = []; $input = $operation->getInput(); // Apply the payload trait if present if ($payload = $input['payload']) { $this->applyPayload($input, $payload, $args, $opts); } foreach ($args as $name => $value) { if ($input->hasMember($name)) { $member = $input->getMember($name); $location = $member['location']; if (!$payload && !$location) { $bodyMembers[$name] = $value; } elseif ($location == 'header') { $this->applyHeader($name, $member, $value, $opts); } elseif ($location == 'querystring') { $this->applyQuery($name, $member, $value, $opts); } elseif ($location == 'headers') { $this->applyHeaderMap($name, $member, $value, $opts); } } } if (isset($bodyMembers)) { $this->payload($operation->getInput(), $bodyMembers, $opts); } else if (!isset($opts['body']) && $this->hasPayloadParam($input, $payload)) { $this->payload($operation->getInput(), [], $opts); } return $opts; } private function applyPayload(StructureShape $input, $name, array $args, array &$opts) { if (!isset($args[$name])) { return; } $m = $input->getMember($name); if ($m['streaming'] || ($m['type'] == 'string' || $m['type'] == 'blob') ) { // Streaming bodies or payloads that are strings are // always just a stream of data. $opts['body'] = Psr7\Utils::streamFor($args[$name]); return; } $this->payload($m, $args[$name], $opts); } private function applyHeader($name, Shape $member, $value, array &$opts) { if ($member->getType() === 'timestamp') { $timestampFormat = !empty($member['timestampFormat']) ? $member['timestampFormat'] : 'rfc822'; $value = TimestampShape::format($value, $timestampFormat); } elseif ($member->getType() === 'boolean') { $value = $value ? 'true' : 'false'; } if ($member['jsonvalue']) { $value = json_encode($value); if (empty($value) && JSON_ERROR_NONE !== json_last_error()) { throw new \InvalidArgumentException('Unable to encode the provided value' . ' with \'json_encode\'. ' . json_last_error_msg()); } $value = base64_encode($value); } $opts['headers'][$member['locationName'] ?: $name] = $value; } /** * Note: This is currently only present in the Amazon S3 model. */ private function applyHeaderMap($name, Shape $member, array $value, array &$opts) { $prefix = $member['locationName']; foreach ($value as $k => $v) { $opts['headers'][$prefix . $k] = $v; } } private function applyQuery($name, Shape $member, $value, array &$opts) { if ($member instanceof MapShape) { $opts['query'] = isset($opts['query']) && is_array($opts['query']) ? $opts['query'] + $value : $value; } elseif ($value !== null) { $type = $member->getType(); if ($type === 'boolean') { $value = $value ? 'true' : 'false'; } elseif ($type === 'timestamp') { $timestampFormat = !empty($member['timestampFormat']) ? $member['timestampFormat'] : 'iso8601'; $value = TimestampShape::format($value, $timestampFormat); } $opts['query'][$member['locationName'] ?: $name] = $value; } } private function buildEndpoint(Operation $operation, array $args, array $opts) { $isModifiedModel = $this->api->isModifiedModel(); $serviceName = $this->api->getServiceName(); // Create an associative array of variable definitions used in expansions $varDefinitions = $this->getVarDefinitions($operation, $args); $relative = preg_replace_callback( '/\{([^\}]+)\}/', function (array $matches) use ($varDefinitions) { $isGreedy = substr($matches[1], -1, 1) == '+'; $k = $isGreedy ? substr($matches[1], 0, -1) : $matches[1]; if (!isset($varDefinitions[$k])) { return ''; } if ($isGreedy) { return str_replace('%2F', '/', rawurlencode($varDefinitions[$k])); } return rawurlencode($varDefinitions[$k]); }, $operation['http']['requestUri'] ); // Add the query string variables or appending to one if needed. if (!empty($opts['query'])) { $relative = $this->appendQuery($opts['query'], $relative); } $path = $this->endpoint->getPath(); if ($isModifiedModel && $serviceName === 's3') { if (substr($path, -1) === '/' && $relative[0] === '/') { $path = rtrim($path, '/'); } $relative = $path . $relative; if (strpos($relative, '../') !== false || substr($relative, -2) === '..' ) { if ($relative[0] !== '/') { $relative = '/' . $relative; } return new Uri($this->endpoint->withPath('') . $relative); } } if ((!empty($relative) && $relative !== '/') && !$isModifiedModel && $serviceName !== 's3' ) { $this->normalizePath($path); } // If endpoint has path, remove leading '/' to preserve URI resolution. if ($path && $relative[0] === '/') { $relative = substr($relative, 1); } //Append path to endpoint when leading '//...' // present as uri cannot be properly resolved if ($isModifiedModel && strpos($relative, '//') === 0) { return new Uri($this->endpoint . $relative); } // Expand path place holders using Amazon's slightly different URI // template syntax. return UriResolver::resolve($this->endpoint, new Uri($relative)); } /** * @param StructureShape $input */ private function hasPayloadParam(StructureShape $input, $payload) { if ($payload) { $potentiallyEmptyTypes = ['blob','string']; if ($this->api->getMetadata('protocol') == 'rest-xml') { $potentiallyEmptyTypes[] = 'structure'; } $payloadMember = $input->getMember($payload); if (in_array($payloadMember['type'], $potentiallyEmptyTypes)) { return false; } } foreach ($input->getMembers() as $member) { if (!isset($member['location'])) { return true; } } return false; } private function appendQuery($query, $endpoint) { $append = Psr7\Query::build($query); return $endpoint .= strpos($endpoint, '?') !== false ? "&{$append}" : "?{$append}"; } private function getVarDefinitions($command, $args) { $varDefinitions = []; foreach ($command->getInput()->getMembers() as $name => $member) { if ($member['location'] == 'uri') { $varDefinitions[$member['locationName'] ?: $name] = isset($args[$name]) ? $args[$name] : null; } } return $varDefinitions; } /** * Appends trailing slash to non-empty paths with at least one segment * to ensure proper URI resolution * * @param string $path * * @return void */ private function normalizePath(string $path): void { if (!empty($path) && $path !== '/' && substr($path, -1) !== '/') { $this->endpoint = $this->endpoint->withPath($path . '/'); } } } PK \&5]33Ec2ParamBuilder.phpnu[getMember(); foreach ($value as $k => $v) { $this->format($items, $v, $prefix . '.' . ($k + 1), $query); } } } } PK \S"Z JsonBody.phpnu[api = $api; } /** * Gets the JSON Content-Type header for a service API * * @param Service $service * * @return string */ public static function getContentType(Service $service) { if ($service->getMetadata('protocol') === 'rest-json') { return 'application/json'; } $jsonVersion = $service->getMetadata('jsonVersion'); if (empty($jsonVersion)) { throw new \InvalidArgumentException('invalid json'); } else { return 'application/x-amz-json-' . @number_format($service->getMetadata('jsonVersion'), 1); } } /** * Builds the JSON body based on an array of arguments. * * @param Shape $shape Operation being constructed * @param array $args Associative array of arguments * * @return string */ public function build(Shape $shape, array $args) { $result = json_encode($this->format($shape, $args)); return $result == '[]' ? '{}' : $result; } private function format(Shape $shape, $value) { switch ($shape['type']) { case 'structure': $data = []; if (isset($shape['document']) && $shape['document']) { return $value; } foreach ($value as $k => $v) { if ($v !== null && $shape->hasMember($k)) { $valueShape = $shape->getMember($k); $data[$valueShape['locationName'] ?: $k] = $this->format($valueShape, $v); } } if (empty($data)) { return new \stdClass; } return $data; case 'list': $items = $shape->getMember(); foreach ($value as $k => $v) { $value[$k] = $this->format($items, $v); } return $value; case 'map': if (empty($value)) { return new \stdClass; } $values = $shape->getValue(); foreach ($value as $k => $v) { $value[$k] = $this->format($values, $v); } return $value; case 'blob': return base64_encode($value); case 'timestamp': $timestampFormat = !empty($shape['timestampFormat']) ? $shape['timestampFormat'] : 'unixTimestamp'; return TimestampShape::format($value, $timestampFormat); default: return $value; } } } PK \-qqRestJsonSerializer.phpnu[contentType = JsonBody::getContentType($api); $this->jsonFormatter = $jsonFormatter ?: new JsonBody($api); } protected function payload(StructureShape $member, array $value, array &$opts) { $body = isset($value) ? ((string) $this->jsonFormatter->build($member, $value)) : "{}"; $opts['headers']['Content-Type'] = $this->contentType; $opts['body'] = $body; } } PK \@RestXmlSerializer.phpnu[xmlBody = $xmlBody ?: new XmlBody($api); } protected function payload(StructureShape $member, array $value, array &$opts) { $opts['headers']['Content-Type'] = 'application/xml'; $opts['body'] = $this->getXmlBody($member, $value); } /** * @param StructureShape $member * @param array $value * @return string */ private function getXmlBody(StructureShape $member, array $value) { $xmlBody = (string)$this->xmlBody->build($member, $value); $xmlBody = str_replace("'", "'", $xmlBody); $xmlBody = str_replace('\r', " ", $xmlBody); $xmlBody = str_replace('\n', " ", $xmlBody); return $xmlBody; } } PK \ XmlBody.phpnu[api = $api; } /** * Builds the XML body based on an array of arguments. * * @param Shape $shape Operation being constructed * @param array $args Associative array of arguments * * @return string */ public function build(Shape $shape, array $args) { $xml = new XMLWriter(); $xml->openMemory(); $xml->startDocument('1.0', 'UTF-8'); $this->format($shape, $shape['locationName'] ?: $shape['name'], $args, $xml); $xml->endDocument(); return $xml->outputMemory(); } private function startElement(Shape $shape, $name, XMLWriter $xml) { $xml->startElement($name); if ($ns = $shape['xmlNamespace']) { $xml->writeAttribute( isset($ns['prefix']) ? "xmlns:{$ns['prefix']}" : 'xmlns', $shape['xmlNamespace']['uri'] ); } } private function format(Shape $shape, $name, $value, XMLWriter $xml) { // Any method mentioned here has a custom serialization handler. static $methods = [ 'add_structure' => true, 'add_list' => true, 'add_blob' => true, 'add_timestamp' => true, 'add_boolean' => true, 'add_map' => true, 'add_string' => true ]; $type = 'add_' . $shape['type']; if (isset($methods[$type])) { $this->{$type}($shape, $name, $value, $xml); } else { $this->defaultShape($shape, $name, $value, $xml); } } private function defaultShape(Shape $shape, $name, $value, XMLWriter $xml) { $this->startElement($shape, $name, $xml); $xml->text($value); $xml->endElement(); } private function add_structure( StructureShape $shape, $name, array $value, \XMLWriter $xml ) { $this->startElement($shape, $name, $xml); foreach ($this->getStructureMembers($shape, $value) as $k => $definition) { $this->format( $definition['member'], $definition['member']['locationName'] ?: $k, $definition['value'], $xml ); } $xml->endElement(); } private function getStructureMembers(StructureShape $shape, array $value) { $members = []; foreach ($value as $k => $v) { if ($v !== null && $shape->hasMember($k)) { $definition = [ 'member' => $shape->getMember($k), 'value' => $v, ]; if ($definition['member']['xmlAttribute']) { // array_unshift_associative $members = [$k => $definition] + $members; } else { $members[$k] = $definition; } } } return $members; } private function add_list( ListShape $shape, $name, array $value, XMLWriter $xml ) { $items = $shape->getMember(); if ($shape['flattened']) { $elementName = $name; } else { $this->startElement($shape, $name, $xml); $elementName = $items['locationName'] ?: 'member'; } foreach ($value as $v) { $this->format($items, $elementName, $v, $xml); } if (!$shape['flattened']) { $xml->endElement(); } } private function add_map( MapShape $shape, $name, array $value, XMLWriter $xml ) { $xmlEntry = $shape['flattened'] ? $shape['locationName'] : 'entry'; $xmlKey = $shape->getKey()['locationName'] ?: 'key'; $xmlValue = $shape->getValue()['locationName'] ?: 'value'; $this->startElement($shape, $name, $xml); foreach ($value as $key => $v) { $this->startElement($shape, $xmlEntry, $xml); $this->format($shape->getKey(), $xmlKey, $key, $xml); $this->format($shape->getValue(), $xmlValue, $v, $xml); $xml->endElement(); } $xml->endElement(); } private function add_blob(Shape $shape, $name, $value, XMLWriter $xml) { $this->startElement($shape, $name, $xml); $xml->writeRaw(base64_encode($value)); $xml->endElement(); } private function add_timestamp( TimestampShape $shape, $name, $value, XMLWriter $xml ) { $this->startElement($shape, $name, $xml); $timestampFormat = !empty($shape['timestampFormat']) ? $shape['timestampFormat'] : 'iso8601'; $xml->writeRaw(TimestampShape::format($value, $timestampFormat)); $xml->endElement(); } private function add_boolean( Shape $shape, $name, $value, XMLWriter $xml ) { $this->startElement($shape, $name, $xml); $xml->writeRaw($value ? 'true' : 'false'); $xml->endElement(); } private function add_string( Shape $shape, $name, $value, XMLWriter $xml ) { if ($shape['xmlAttribute']) { $xml->writeAttribute($shape['locationName'] ?: $name, $value); } else { $this->defaultShape($shape, $name, $value, $xml); } } } PK \@#QueryParamBuilder.phpnu[isFlat($shape) && !empty($shape['member']['locationName'])) { return $shape['member']['locationName']; } return $default; } protected function isFlat(Shape $shape) { return $shape['flattened'] === true; } public function __invoke(StructureShape $shape, array $params) { if (!$this->methods) { $this->methods = array_fill_keys(get_class_methods($this), true); } $query = []; $this->format_structure($shape, $params, '', $query); return $query; } protected function format(Shape $shape, $value, $prefix, array &$query) { $type = 'format_' . $shape['type']; if (isset($this->methods[$type])) { $this->{$type}($shape, $value, $prefix, $query); } else { $query[$prefix] = (string) $value; } } protected function format_structure( StructureShape $shape, array $value, $prefix, &$query ) { if ($prefix) { $prefix .= '.'; } foreach ($value as $k => $v) { if ($shape->hasMember($k)) { $member = $shape->getMember($k); $this->format( $member, $v, $prefix . $this->queryName($member, $k), $query ); } } } protected function format_list( ListShape $shape, array $value, $prefix, &$query ) { // Handle empty list serialization if (!$value) { $query[$prefix] = ''; return; } $items = $shape->getMember(); if (!$this->isFlat($shape)) { $locationName = $shape->getMember()['locationName'] ?: 'member'; $prefix .= ".$locationName"; } elseif ($name = $this->queryName($items)) { $parts = explode('.', $prefix); $parts[count($parts) - 1] = $name; $prefix = implode('.', $parts); } foreach ($value as $k => $v) { $this->format($items, $v, $prefix . '.' . ($k + 1), $query); } } protected function format_map( MapShape $shape, array $value, $prefix, array &$query ) { $vals = $shape->getValue(); $keys = $shape->getKey(); if (!$this->isFlat($shape)) { $prefix .= '.entry'; } $i = 0; $keyName = '%s.%d.' . $this->queryName($keys, 'key'); $valueName = '%s.%s.' . $this->queryName($vals, 'value'); foreach ($value as $k => $v) { $i++; $this->format($keys, $k, sprintf($keyName, $prefix, $i), $query); $this->format($vals, $v, sprintf($valueName, $prefix, $i), $query); } } protected function format_blob(Shape $shape, $value, $prefix, array &$query) { $query[$prefix] = base64_encode($value); } protected function format_timestamp( TimestampShape $shape, $value, $prefix, array &$query ) { $timestampFormat = !empty($shape['timestampFormat']) ? $shape['timestampFormat'] : 'iso8601'; $query[$prefix] = TimestampShape::format($value, $timestampFormat); } protected function format_boolean(Shape $shape, $value, $prefix, array &$query) { $query[$prefix] = ($value) ? 'true' : 'false'; } } PK \kpM M JsonRpcSerializer.phpnu[endpoint = $endpoint; $this->api = $api; $this->jsonFormatter = $jsonFormatter ?: new JsonBody($this->api); $this->contentType = JsonBody::getContentType($api); } /** * When invoked with an AWS command, returns a serialization array * containing "method", "uri", "headers", and "body" key value pairs. * * @param CommandInterface $command Command to serialize into a request. * @param $endpointProvider Provider used for dynamic endpoint resolution. * @param $clientArgs Client arguments used for dynamic endpoint resolution. * * @return RequestInterface */ public function __invoke( CommandInterface $command, $endpoint = null ) { $operationName = $command->getName(); $operation = $this->api->getOperation($operationName); $commandArgs = $command->toArray(); $headers = [ 'X-Amz-Target' => $this->api->getMetadata('targetPrefix') . '.' . $operationName, 'Content-Type' => $this->contentType ]; if ($endpoint instanceof RulesetEndpoint) { $this->setEndpointV2RequestOptions($endpoint, $headers); } return new Request( $operation['http']['method'], $this->endpoint, $headers, $this->jsonFormatter->build( $operation->getInput(), $commandArgs ) ); } } PK \n~.QuerySerializer.phpnu[PK \uo)o)4 RestSerializer.phpnu[PK \&5]332Ec2ParamBuilder.phpnu[PK \S"Z [6JsonBody.phpnu[PK \-qqBRestJsonSerializer.phpnu[PK \@ZGRestXmlSerializer.phpnu[PK \ LXmlBody.phpnu[PK \@#cQueryParamBuilder.phpnu[PK \kpM M sJsonRpcSerializer.phpnu[PK }