public function create(array $names): JWESerializerManager
    {
        $serializers = [];
        foreach ($names as $name) {
            if (!\array_key_exists($name, $this->serializers)) {
                throw new \InvalidArgumentException(\sprintf('Unsupported serializer "%s".', $name));
            }
            $serializers[] = $this->serializers[$name];
        }

        return JWESerializerManager::create($serializers);
    }
public function create(array $names): JWESerializerManager
    {
        $serializers = [];
        foreach ($names as $name) {
            if (!\array_key_exists($name, $this->serializers)) {
                throw new \InvalidArgumentException(\sprintf('Unsupported serializer "%s".', $name));
            }
            $serializers[] = $this->serializers[$name];
        }

        return JWESerializerManager::create($serializers);
    }
public function create ( array $ names ) : JWESerializerManager { $ serializers = [ ] ; foreach ( $ names as $ name ) { if ( ! \ array_key_exists ( $ name , $ this -> serializers ) ) { throw new \ InvalidArgumentException ( \ sprintf ( 'Unsupported serializer "%s".' , $ name ) ) ; } $ serializers [ ] = $ this -> serializers [ $ name ] ; } return JWESerializerManager :: create ( $ serializers ) ; }
Creates a serializer manager factory using the given serializers.

@param string[] $names
Creates a serializer manager factory using the given serializers .