src-dev/Mouf/Controllers/AbstractMoufInstanceController.php
protected function getValueForProperty(MoufPropertyDescriptor $property) {
		if ($property->isPublicFieldProperty()) {
			$propertyName =  $property->getName();
			if ($this->moufManager->hasParameter($this->instanceName, $propertyName)) {
				$defaultValue = $this->moufManager->getParameter($this->instanceName, $propertyName);
			} else {
				$defaultValue = $this->reflectionClass->getProperty($propertyName)->getDefault();
			}
		} else {
			// This is a setter.
			$propertyName =  $property->getName();
			if ($this->moufManager->hasParameterForSetter($this->instanceName, $property->getMethodName())) {
				$defaultValue = $this->moufManager->getParameterForSetter($this->instanceName, $property->getMethodName());
			} else {
				// TODO: return a default value. We could try to find it using a getter maybe...
				// Or a default value for the setter? 
				return null;
			}
			
		}
		return $defaultValue;
	}
protected function getValueForProperty(MoufPropertyDescriptor $property) {
		if ($property->isPublicFieldProperty()) {
			$propertyName =  $property->getName();
			if ($this->moufManager->hasParameter($this->instanceName, $propertyName)) {
				$defaultValue = $this->moufManager->getParameter($this->instanceName, $propertyName);
			} else {
				$defaultValue = $this->reflectionClass->getProperty($propertyName)->getDefault();
			}
		} else {
			// This is a setter.
			$propertyName =  $property->getName();
			if ($this->moufManager->hasParameterForSetter($this->instanceName, $property->getMethodName())) {
				$defaultValue = $this->moufManager->getParameterForSetter($this->instanceName, $property->getMethodName());
			} else {
				// TODO: return a default value. We could try to find it using a getter maybe...
				// Or a default value for the setter? 
				return null;
			}
			
		}
		return $defaultValue;
	}
protected function getValueForProperty ( MoufPropertyDescriptor $ property ) { if ( $ property -> isPublicFieldProperty ( ) ) { $ propertyName = $ property -> getName ( ) ; if ( $ this -> moufManager -> hasParameter ( $ this -> instanceName , $ propertyName ) ) { $ defaultValue = $ this -> moufManager -> getParameter ( $ this -> instanceName , $ propertyName ) ; } else { $ defaultValue = $ this -> reflectionClass -> getProperty ( $ propertyName ) -> getDefault ( ) ; } } else { // This is a setter. $ propertyName = $ property -> getName ( ) ; if ( $ this -> moufManager -> hasParameterForSetter ( $ this -> instanceName , $ property -> getMethodName ( ) ) ) { $ defaultValue = $ this -> moufManager -> getParameterForSetter ( $ this -> instanceName , $ property -> getMethodName ( ) ) ; } else { // TODO: return a default value. We could try to find it using a getter maybe... // Or a default value for the setter?  return null ; } } return $ defaultValue ; }
Returns the value set for the instance passed in parameter... or the default value if the value is not set.

@param MoufPropertyDescription $property
@return mixed
Returns the value set for the instance passed in parameter ... or the default value if the value is not set .