Will return all the accessible properties of the given object instance.

@param object $object
@return array
422868
private function getObjectPropertiesValues($object)
    {
        $properties = Core::get()->getGettablePropertiesOfObject($object);
        $finalProperties = [];

        foreach ($properties as $property) {
            $finalProperties[$property] = Core::get()->getObjectService()->getObjectProperty($object, $property);
        }

        return $finalProperties;
    }
1028541
private function _recursiveGetObjectVars($object)
    {
        $vars = $object;
        if ( is_object($object) ) {
            $vars = get_object_vars($object);
            foreach ($vars as $key => $value) {
                $vars[$key] = $this->_recursiveGetObjectVars($value);
            }
        }

        return $vars;
    }
388685
protected function _getMethods($object)
    {
        if (is_string($object)) {
            $className = $object;
        } else {
            $className = get_class($object);
        }
        $methods = get_class_methods($className);

        if (self::$_config['sort']['methods']) {
            sort($methods);
        }
        return $methods;
    }
868379
public static function attrToArray($object){
        if(is_array($object) || is_object($object)) {
            $result = [];
            foreach ($object as $key => $value) {
                $result[$key] = self::attrToArray($value);
            }
            return $result;
        }
        return $object;
    }
647065
public function extract( $object )
    {
        if ( $object instanceof Structure )
        {
            return array(
                'rootId'    => $object->rootId,
                'css'       => $object->render()
                                      ->getBuffer(),
            );
        }

        return array(
            'rootId'    => isset( $object->rootId )
                            ? (string) $object->rootId
                            : null,
            'css'       => isset( $object->css )
                            ? (string) $object->css
                            : null,
        );
    }
987704
private function buildDataFromObject($object)
    {
        $result = array();

        $stack = new \SplStack();
        $stack->push($object);

        while (!$stack->isEmpty()) {
            $current = $stack->pop();
            if (is_object($current)) {
                array_push($result, $current);
            }

            foreach ($this->getDataFromItem($current) as $propertyName => $propertyValue) {
                if (is_object($propertyValue) || is_array($propertyValue)) {
                    $stack->push($propertyValue);
                }
            }
        }

        return $result;
    }
773887
public function getData($object)
    {
        return [
            'OXID'          => $object->getId(),
            'OXRATING'      => $object->getRating(),
            'OXTEXT'        => $object->getText(),
            'OXOBJECTID'    => $object->getObjectId(),
            'OXUSERID'      => $object->getUserId(),
            'OXTYPE'        => $object->getType(),
            'OXTIMESTAMP'   => $object->getCreatedAt(),
        ];
    }
801902
protected static function objectToArray($object)
    {
        if (!\is_object($object)) {
            return $object;
        }

        if (\is_object($object)) {
            $object = \get_object_vars($object);
        }

        return \array_map(['static', 'objectToArray'], $object);
    }
382226
public static function wrap($object): array
    {
        if (null === $object) {
            return [];
        }

        if (is_array($object) && !self::isAssoc($object)) {
            return $object;
        }

        return [$object];
    }
123689
public function normalize($object) : array
    {
        return $this->asArray ? $this->normalizeAsArray($object) : $this->normalizeAsAttributes($object);
    }
207618
public function extract($object)
    {
        $data = ['name' => $object->getNormalizedName()];
        if ($object->hasParent()) {
            $data['source'] = strval($object->getParent()->getNormalizedName());
        }
        return $data;
    }
192849
private static function getPropertyMapping($object)
    {
        $mapping = array();
        $reflection = new \ReflectionClass($object);

        // Create a default property mapping by getting the properties
        foreach ($reflection->getProperties() as $property) {
            $name = $property->getName();
            $setterMethod = 'set' . ucfirst($name);

            if (method_exists($object, $setterMethod) || $property->isPublic()) {
                $mapping[$name] = $name;
            }
        }

        // If the getPropertyMapping method exists, merge it with the
        // existing mapping.
        //
        // This comes last because it has higher priority than the default
        // mapping.
        if (method_exists($object, 'getPropertyMapping')) {
            $mapping = array_merge($mapping, $object->getPropertyMapping());
        }

        // Filter any properties that are mapped to null
        foreach ($mapping as $destination => $source) {
            if (!$source) {
                unset($mapping[$destination]);
            }
        }

        return $mapping;
    }
488823
public function extract($object)
    {
        $data = $object->getArrayCopy();
        $extractedData = [];

        foreach ($data as $key => $value) {
            $extractName = $this->extractName($key);

            if (array_key_exists($extractName, $this->map)) {
                $value = $this->extractValue($key, $value, $data);
                $extractedData[$extractName] = $value;
            }
        }

        return $extractedData;
    }
1064595
protected static function rawData( $object )
    {
        if ( is_object( $object ) )
        {
            $hash = spl_object_hash( $object );

            if ( isset( self::$rawCheck[$hash] ) )
            {
                return array( '#recursion#' => $hash );
            }

            self::$rawCheck[$hash] = true;
        }

        $object = (array) $object;

        foreach ( $object as $key => $value )
        {
            if ( is_array( $value ) || is_object( $value ) )
            {
                $object[$key] = self::rawData( $value );
            }
        }

        return (object) $object;
    }
1321636
public function readObject($object = null)
    {
        if ($object === null) {
            $object = array();
        }

        while (true) {
            $key        = $this->_stream->readUTF();
            $typeMarker = $this->_stream->readByte();
            if ($typeMarker != Zend_Amf_Constants::AMF0_OBJECTTERM ){
                //Recursivly call readTypeMarker to get the types of properties in the object
                $object[$key] = $this->readTypeMarker($typeMarker);
            } else {
                //encountered AMF object terminator
                break;
            }
        }
        $this->_reference[] = $object;
        return (object) $object;
    }
297868
public static function displayProperties($object)
    {
        $class = get_class($object);

        echo sprintf(self::_('Properties for class %s:'), $class);
        echo '<ul>';

        foreach (get_class_vars($class) as $property_name => $value) {
            $instance_value = $object->$property_name;
            echo '<li>', $property_name, ' = ', $instance_value, '</li>';
        }

        echo '</ul>';
    }
962055
public function getLabeledPropertiesToBeSet($object)
    {
        return array_filter($this->getLabeledProperties(), function (LabeledPropertyMetadata $labeledPropertyMetadata) use ($object) {
            return true === $labeledPropertyMetadata->getValue($object);
        });
    }