Hydrate $object with the provided $data.
@param  array $data
@param  object $object
@return TicketSubject
@throws \InvalidArgumentException
179683
public function hydrate(array $data, $object)
    {
        if (!$object instanceof TicketSubject) {
            throw new \InvalidArgumentException('$object must be an instance of TicketSubject');
        }

        return parent::hydrate($data, $object);
    }
626993
public function hydrate(array $data, $object)
    {
        $this->prepare($object);

        if ($this->byValue) {
            return $this->hydrateByValue($data, $object);
        }

        return $this->hydrateByReference($data, $object);
    }
1321723
public function hydrate(array $data, $object)
    {
        parent::hydrate($data, $object);

        foreach ($this->getFreeValuesKeys() as $key) {
            if (isset($data[$key])) {
                $object->set($key, $data[$key]);
            }
        }

        return $object;
    }
1229253
public function hydrate(array $data, $object)
    {
        $methods = array_flip(get_class_methods(get_class($object)));
        $class = get_class($object);

        foreach ($data as $key => $value) {
            $method = StringUtil::camel('set_' . $key);

            if (!isset($methods[$method])) {
                continue;
            }

            $object->$method($this->getValue($class, $method, $value));
        }

        return $object;
    }
536213
public function hydrate( array $data, $object )
    {
        if ( isset( $data['properties'] ) &&
             is_array( $data['properties'] ) )
        {
            foreach ( $data['properties'] as $key => $value )
            {
                $newKey = String::decamelize( $key );

                if ( $newKey != $key )
                {
                    $data['properties'][$newKey] = $value;
                    unset( $data['properties'][$key] );
                }
            }
        }

        return $this->getMapper()
                    ->hydrate( $data, $object );
    }
319179
protected function doHydrate(array $data, $object)
    {
        $previousHydrationContext = $this->currentHydrationContext;
        $this->currentHydrationContext = new CurrentHydrationContext($data, $object);

        foreach ($this->metadata->getMappedFieldNames() as $mappedFieldName) {
            $defaultValue = $this->metadata->getFieldDefaultValue($mappedFieldName);

            if (null !== $defaultValue) {
                $this->resolveValue($defaultValue, $object);
                $this->memberAccessStrategy->setValue($defaultValue, $object, $mappedFieldName);   
            }
        }

        if (! $this->metadata->hasCustomHydrator()) {

            $this->executeMethods($object, $this->metadata->getPreHydrateListeners());

            foreach ($data as $originalFieldName => $value) {
                $mappedFieldName = $this->metadata->getMappedFieldName($originalFieldName);
                if (null === $mappedFieldName) {

                    //It's possible that a raw field name has no corresponding field name
                    //because a raw field can be a value object part.
                    continue;
                }

                if (! $this->metadata->hasSource($mappedFieldName)) {
                    //Classical hydration.
                    $this->walkHydration($mappedFieldName, $object, $value, $data);
                }
            }
        } else {
            list($customHydratorClass, $customHydrateMethod) = $this->metadata->getCustomHydratorInfo();
            $this->executeMethod($object, new ClassMetadata\Model\Method($customHydratorClass, $customHydrateMethod, [$data, $object]));
        }

        //DataSources hydration.
        foreach ($this->metadata->getFieldsWithDataSources() as $mappedFieldName) {

            if ($this->metadata->hasDataSource($mappedFieldName)) {//<= Is this test usefull ?
                $this->walkHydrationByDataSource($mappedFieldName, $object, false);
            }
        }

        //Providers hydration.
        foreach ($this->metadata->getFieldsWithProviders() as $mappedFieldName) {

            if ($this->metadata->hasProvider($mappedFieldName)) {//<= Is this test usefull ?
                $this->walkHydrationByProvider($mappedFieldName, $object, false);
            }
        }

        //Value objects hydration.
        foreach ($this->metadata->getFieldsWithValueObjects() as $mappedFieldName) {
            $this->walkValueObjectHydration($mappedFieldName, $object, $data);
        }

        $this->executeMethods($object, $this->metadata->getPostHydrateListeners());

        $this->currentHydrationContext = $previousHydrationContext;

        return $object;
    }
685571
public function map($object, $data)
    {
        $object
            ->setProductId($data['OXID'])
            ->setRatingAverage($data['OXRATING'])
            ->setRatingCount($data['OXRATINGCNT']);

        return $object;
    }
961077
public function hydrate(array $data, $object)
    {
        $object->setId($this->getData('id', $data));
        $object->setName($this->getData('name', $data));
        return $object;
    }
627899
public function update($data, $object)
	{
		// Process data given.
		$processPayload = $this->process(__FUNCTION__, $data);

		if( ! $processPayload->isStatus(Payload::STATUS_VALID))
		{
			return $processPayload;
		}

		return $this->dataSource->update($processPayload->getData(), $object);
	}
485552
public static function unserialize($object, array $data)
    {
        $serializer = new static();
        $serializer->references = $data['@references'] ?? [];
        unset($data['@references']);

        return $serializer->unserializeObject($object, $data);
    }
1021143
public function hydrate($object, $data)
    {
        if (is_array($data)) {
            foreach ($data as $key => $value) {
                // Check setMethod
                if (!$this->callSetter($object, $this->toCamelCase($key), $value)) {
                    // If no setter is defined, we reinject into array
                    $data[$key] = $value; // Change data with subObject
                }
            }
        }

        return $object;
    }
736025
private function getHydrator($object)
    {
        $class = get_class($object);

        if (!isset(self::$hydratorCache[$class])) {
            $hydratorClass = $this->generator->getHydratorClass($class);

            self::$hydratorCache[$class] = new $hydratorClass;
        }

        return self::$hydratorCache[$class];
    }
277830
public function createFromData(array $data, array $map = null)
    {
        $object = $this->create();
        $this->hydrator->hydrate($data, $object, $map);
        return $object;
    }
86345
public function hydrate(array $data, $classNameOrObject)
    {
        $object = $this->buildObject($classNameOrObject);

        return parent::hydrate($data, $object);
    }
539444
public function hydrate($object, array $array)
    {
        $reflected = new \ReflectionClass($object);

        if (is_string($object)) {
            $object = $this->createInstance($reflected);
        }

        foreach ($array as $key => $value) {
            $attributeName = $this->formatter->toPhpAttribute($key);

            if ($reflected->hasProperty($attributeName)) {

                $property = $reflected->getProperty($attributeName);
                $this->setValue($object, $property, $value);
            } elseif ($this->isSchemaless()) {
                $object->$attributeName = $value;
            }
        }

        return $object;
    }
1230921
protected function hydrateObjectForm($object)
    {
        $data = array(
            'id' => $object->getId(),
            'locale' => $object->getLocale(),
            'visible' => $object->getVisible() ? true : false,
            'country_id' => $object->getCountryId(),
            'title' => $object->getTitle(),
            'isocode' => $object->getIsocode(),
        );

        return $this->createForm(AdminForm::STATE_MODIFICATION, 'form', $data);
    }
239327
function setData($object, array $data)
    {
        if (! $this->has($object) )
            throw new \Exception('Object Not Found.');

        if ($data == array_values($data))
            throw new \InvalidArgumentException('Data tags must be associative array.');


        $hash = $this->genETag($object);
        $this->_objs[$hash]['data'] = $data;
        return $this;
    }