src/Blackprism/Serializer/Json/Serialize.php
private function setArray($object): array
    {
        $data = [];
        $configurationObject = $this->configuration->getConfigurationObjectForClass(new ClassName(get_class($object)));

        $identifier = $configurationObject->getIdentifier();
        if ($identifier !== '') {
            $data[$this->configuration->getIdentifierAttribute()] = $identifier;
        }

        foreach ($configurationObject->getAttributes() as $attribute) {
            $type = $configurationObject->getTypeForAttribute($attribute);
            $data = $this->processSerializeForType($type, $object, $data, $attribute);
        }

        return $data;
    }
private function setArray($object): array
    {
        $data = [];
        $configurationObject = $this->configuration->getConfigurationObjectForClass(new ClassName(get_class($object)));

        $identifier = $configurationObject->getIdentifier();
        if ($identifier !== '') {
            $data[$this->configuration->getIdentifierAttribute()] = $identifier;
        }

        foreach ($configurationObject->getAttributes() as $attribute) {
            $type = $configurationObject->getTypeForAttribute($attribute);
            $data = $this->processSerializeForType($type, $object, $data, $attribute);
        }

        return $data;
    }
private function setArray ( $ object ) : array { $ data = [ ] ; $ configurationObject = $ this -> configuration -> getConfigurationObjectForClass ( new ClassName ( get_class ( $ object ) ) ) ; $ identifier = $ configurationObject -> getIdentifier ( ) ; if ( $ identifier !== '' ) { $ data [ $ this -> configuration -> getIdentifierAttribute ( ) ] = $ identifier ; } foreach ( $ configurationObject -> getAttributes ( ) as $ attribute ) { $ type = $ configurationObject -> getTypeForAttribute ( $ attribute ) ; $ data = $ this -> processSerializeForType ( $ type , $ object , $ data , $ attribute ) ; } return $ data ; }
Create array from object

@param object $object

@return mixed[]
Create array from object