private function configureContext(Context $context)
    {
        foreach ($this->attributes as $key => $value) {
            $context->setAttribute($key, $value);
        }
        if (!empty($this->groups)) {
            $context->setGroups($this->groups);
        }

        if (($context instanceof SerializationContext) && $this->serializeNulls !== null) {
            $context->setSerializeNull($this->serializeNulls);
        }

        if ($this->enableMaxDepthChecks === true) {
            $context->enableMaxDepthChecks();
        }

        if ($this->version !== null) {
            $context->setVersion($this->version);
        }

        return $context;
    }
private function configureContext(Context $context)
    {
        foreach ($this->attributes as $key => $value) {
            $context->setAttribute($key, $value);
        }
        if (!empty($this->groups)) {
            $context->setGroups($this->groups);
        }

        if (($context instanceof SerializationContext) && $this->serializeNulls !== null) {
            $context->setSerializeNull($this->serializeNulls);
        }

        if ($this->enableMaxDepthChecks === true) {
            $context->enableMaxDepthChecks();
        }

        if ($this->version !== null) {
            $context->setVersion($this->version);
        }

        return $context;
    }
private function configureContext ( Context $ context ) { foreach ( $ this -> attributes as $ key => $ value ) { $ context -> setAttribute ( $ key , $ value ) ; } if ( ! empty ( $ this -> groups ) ) { $ context -> setGroups ( $ this -> groups ) ; } if ( ( $ context instanceof SerializationContext ) && $ this -> serializeNulls !== null ) { $ context -> setSerializeNull ( $ this -> serializeNulls ) ; } if ( $ this -> enableMaxDepthChecks === true ) { $ context -> enableMaxDepthChecks ( ) ; } if ( $ this -> version !== null ) { $ context -> setVersion ( $ this -> version ) ; } return $ context ; }
Configures context according to configuration

@param Context $context The context

@return Context Given object
Configures context according to configuration