?iť?

Your IP : 3.129.195.209


Current Path : /home/scgforma/www/cloud/3rdparty/aws/aws-sdk-php/src/Api/Serializer/
Upload File :
Current File : /home/scgforma/www/cloud/3rdparty/aws/aws-sdk-php/src/Api/Serializer/Ec2ParamBuilder.php

<?php
namespace Aws\Api\Serializer;

use Aws\Api\Shape;
use Aws\Api\ListShape;

/**
 * @internal
 */
class Ec2ParamBuilder extends QueryParamBuilder
{
    protected function queryName(Shape $shape, $default = null)
    {
        return ($shape['queryName']
            ?: ucfirst($shape['locationName']))
                ?: $default;
    }

    protected function isFlat(Shape $shape)
    {
        return false;
    }

    protected function format_list(
        ListShape $shape,
        array $value,
        $prefix,
        &$query
    ) {
        // Handle empty list serialization
        if (!$value) {
            $query[$prefix] = false;
        } else {
            $items = $shape->getMember();
            foreach ($value as $k => $v) {
                $this->format($items, $v, $prefix . '.' . ($k + 1), $query);
            }
        }
    }
}