Returns an associative array of object properties.

@param   boolean  $public  If true, returns only the public properties.
@return  array
971249
public function getProperties($public = true)
	{
		$vars = get_object_vars($this);

		if ($public)
		{
			foreach ($vars as $key => $value)
			{
				if ('_' == substr($key, 0, 1))
				{
					unset($vars[$key]);
				}
			}
		}

		return $vars;
	}
440979
protected function parseProperties(array $properties)
    {
        $parsed = [];

        foreach ($properties as $propertyString) {
            if (!mb_strpos($propertyString, ':')) {
                list($key, $value) = $this->parseBooleanShortcut($propertyString);
                $parsed[Type::camelCase($key)] = $value;
                continue;
            }


            list($key, $value) = explode(':', $propertyString, 2);


            if (!$this->isNestedShortCut($value)) {
                $parsed[Type::camelCase($key)] = $value;
                continue;
            }

            $type = $this->stringToType(trim($value, '[]'));

            $parsed[Type::camelCase($key)] = $type;
        }

        return $parsed;
    }
1359573
public function getPageProperties($properties = array())
    {
        $success = 0;
        $data    = array();

        $page = $this->getServiceLocator()->get("MelisPageProperty");

        if(is_array($property))
        {
            $data = $page->getPageProperties($properties);
        }

        return $data;
    }
695040
protected function propertiesFromAttributes(): array
    {
        // Get all managed properties
        $propertyNames = $this->entityMap->getProperties();

        $propertyAttributes = array_only($this->attributes, $propertyNames);
        $attributesArray = array_except($this->attributes, $propertyNames);

        $attributesArrayName = $this->entityMap->getAttributesArrayName();

        if ($attributesArrayName) {
            $propertyAttributes[$attributesArrayName] = $attributesArray;
        }

        return $propertyAttributes;
    }
612963
public function toArray($deep = true) {

        // Get each property
        $array = array();
        foreach ($this->__getSerialisablePropertyMap() as $key => $value) {
            if ($value instanceof AssociativeArray) {
                $array[$key] = $deep ? $value->toArray() : $value;
            } else {
                $array[$key] = $value;
            }
        }

        return $array;
    }
56648
protected function attributesFromProperties(array $properties): array
    {
        // First, we'll only keep the entities that are part of the Entity's
        // attributes
        $managedProperties = $this->getManagedProperties();

        $properties = array_only($properties, $managedProperties);

        // If the entity does not uses the attributes array to store
        // part of its attributes, we'll directly return the properties
        if (!$this->entityMap->usesAttributesArray()) {
            return $properties;
        }

        $arrayName = $this->entityMap->getAttributesArrayName();

        if (!array_key_exists($arrayName, $properties)) {
            throw new MappingException("Property $arrayName not set on object of type ".$this->getEntityClass());
        }

        if (!is_array($properties[$arrayName])) {
            throw new MappingException("Property $arrayName should be an array.");
        }

        $attributes = $properties[$arrayName];

        unset($properties[$arrayName]);

        return $properties + $attributes;
    }
1336063
public function getProperties($accountId = false)
    {
        if (!$this->getAccountId() && !$accountId) {
            return false;
        }

        if ($accountId) {
            $webproperties = $this->serviceHelper->getService()->management_webproperties->listManagementWebproperties($accountId);
        } else {
            $webproperties = $this->serviceHelper->getService()->management_webproperties->listManagementWebproperties($this->getAccountId());
        }
        $data = array();

        foreach ($webproperties->getItems() as $property) {
            $profiles = $this->getProfiles($accountId, $property->getId());
            if (count($profiles) > 0) {
                $data[$property->getName()] = array(
                        'propertyId' => $property->getId(),
                        'propertyName' => $property->getName() . ' (' . $property->getWebsiteUrl() . ')',
                    );
            }
        }
        ksort($data);

        return $data;
    }
356573
public function getProperties()
    {
        $properties = [];

        // URL must precede all other properties
        if ($this->url !== null) {
            $properties[] = new Property(Property::IMAGE_URL, $this->url);
        }

        if ($this->height !== null) {
            $properties[] = new Property(Property::IMAGE_HEIGHT, $this->height);
        }

        if ($this->secureUrl !== null) {
            $properties[] = new Property(Property::IMAGE_SECURE_URL, $this->secureUrl);
        }

        if ($this->type !== null) {
            $properties[] = new Property(Property::IMAGE_TYPE, $this->type);
        }

        if ($this->width !== null) {
            $properties[] = new Property(Property::IMAGE_WIDTH, $this->width);
        }

        if ($this->userGenerated !== null) {
            $properties[] = new Property(Property::IMAGE_USER_GENERATED, $this->userGenerated);
        }

        return $properties;
    }
1354883
public function & get($property, array $conditions = array())
	{
		// database columns
		if (array_key_exists($property, static::properties()))
		{
			if ( ! array_key_exists($property, $this->_data))
			{
				$result = null;
			}
			elseif ($this->_sanitization_enabled)
			{
				// use a copy
				$result = $this->_data[$property];
			}
			else
			{
				// use a reference
				$result =& $this->_data[$property];
			}
		}

		// related models
		elseif ($rel = static::relations($property))
		{
			if ( ! array_key_exists($property, $this->_data_relations))
			{
				$this->_data_relations[$property] = $rel->get($this, $conditions);
				$this->_update_original_relations(array($property));
			}

			$result =& $this->_data_relations[$property];
		}

		// EAV properties
		elseif (($result = $this->_get_eav($property)) !== false)
		{
			// nothing else to do here
		}

		// database view columns
		elseif ($this->_view and in_array($property, static::$_views_cached[get_class($this)][$this->_view]['columns']))
		{
			if ($this->_sanitization_enabled)
			{
				// use a copy
				$result = $this->_data[$property];
			}
			else
			{
				// use a reference
				$result =& $this->_data[$property];
			}
		}

		// stored custom data
		elseif (array_key_exists($property, $this->_custom_data))
		{
			if ($this->_sanitization_enabled)
			{
				// use a copy
				$result = $this->_custom_data[$property];
			}
			else
			{
				// use a reference
				$result =& $this->_custom_data[$property];
			}
		}
		else
		{
			throw new \OutOfBoundsException('Property "'.$property.'" not found for '.get_class($this).'.');
		}

		// do we need to clean before returning the result?
		if ($this->_sanitization_enabled)
		{
			$result = $this->_sanitize($property, $result);
		}

		return $result;
	}
37263
public function getProperties(array $props = array())
    {
        if (empty($props)) {
            return $this->properties;
        }

        $properties = [];
        foreach ($props as $key) {
            $properties[$key] = isset($this->properties[$key]) ? $this->properties[$key] : null;
        }

        return $properties;
    }
359546
public function toArray()
    {
        $result = [];
        foreach ($this->visibleProperties() as $property) {
            $value = $this->get($property);
            if (is_array($value)) {
                $result[$property] = [];
                foreach ($value as $k => $entity) {
                    if ($entity instanceof EntityInterface) {
                        $result[$property][$k] = $entity->toArray();
                    } else {
                        $result[$property][$k] = $entity;
                    }
                }
            } elseif ($value instanceof EntityInterface) {
                $result[$property] = $value->toArray();
            } else {
                $result[$property] = $value;
            }
        }

        return $result;
    }
13254
public function getInjectablePropertiesByPublicProperty() {
    	if ($this->injectablePropertiesByPublicProperty === null) {
	    	$moufProperties = array();
	    	foreach($this->getProperties() as $attribute) {
	    		/* @var $attribute MoufXmlReflectionProperty */
	    		//if ($attribute->hasAnnotation("Property")) {
	    		if ($attribute->isPublic() && !$attribute->isStatic()) {
	    			// We might want to catch it and to display it properly
	    			$propertyDescriptor = new MoufPropertyDescriptor($attribute);
	    			$moufProperties[$attribute->getName()] = $propertyDescriptor;
	    		}
	    		//}
	    	}
	    	$this->injectablePropertiesByPublicProperty = $moufProperties;
    	}
    	return $this->injectablePropertiesByPublicProperty;
    }
1023257
protected function getObjectProperties(array $objects): array
    {
        $objectProperties = [];
        /** @var ITypedObject[] $objects */
        foreach ($objects as $key => $object) {
            $objectProperties[$key] = $object->toArray();
        }

        return $objectProperties;
    }
381582
public function data(array $properties = null)
    {
        $data = [];
        $properties = $this->properties($properties);
        foreach ($properties as $propertyIdent => $property) {
            // Ensure objects are properly encoded.
            $val = $this->propertyValue($propertyIdent);
            $val = $this->serializedValue($val);
            $data[$propertyIdent] = $val;
        }

        return $data;
    }
727215
public function getPropertyValues($property)
    {
        $returnValue = null;
        switch ($property) {
            case GenerisRdf::PROPERTY_USER_DEFLG :
                $returnValue = array(DEFAULT_LANG);
                break;
            case GenerisRdf::PROPERTY_USER_UILG :
                $returnValue = array($this->language);
                break;
            case  GenerisRdf::PROPERTY_USER_ROLES :
                $returnValue = $this->taoRoles;
                break;
            case  GenerisRdf::PROPERTY_USER_FIRSTNAME :
                $returnValue = [$this->firstname];
                break;
            case  GenerisRdf::PROPERTY_USER_LASTNAME :
                $returnValue = [$this->lastname];
                break;
            case  OntologyRdfs::RDFS_LABEL :
                $returnValue = [$this->label];
                break;
            default:
                \common_Logger::d('Unkown property ' . $property . ' requested from ' . __CLASS__);
                $returnValue = array();
        }
        return $returnValue;
    }
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;
    }
497554
public function getGettablePropertiesOfObject($object)
    {
        $className = get_class($object);

        if (false === isset($this->gettablePropertiesOfObjects[$className])) {
            $this->gettablePropertiesOfObjects[$className] = [];
            $properties = $this->getReflectionService()->getClassPropertyNames($className);

            foreach ($properties as $propertyName) {
                if (true === $this->isPropertyGettable($object, $propertyName)) {
                    $this->gettablePropertiesOfObjects[$className][] = $propertyName;
                }
            }
        }

        return $this->gettablePropertiesOfObjects[$className];
    }