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;
    }