src/Micrometa/Application/Factory/ItemFactory.php
protected function processPropertyValue($propertyValue)
    {
        // If this is an item value
        if (is_object($propertyValue) && isset($propertyValue->type)) {
            return $this->__invoke($propertyValue);

            // Else these are alternate values
        } elseif (is_array($propertyValue)) {
            return new AlternateValues(array_map([$this, __METHOD__], $propertyValue));
        }

        list($propertyValue, $language) = $this->processLanguageTaggedPropertyValue($propertyValue);

        return new StringValue($propertyValue, $language);
    }
protected function processPropertyValue($propertyValue)
    {
        // If this is an item value
        if (is_object($propertyValue) && isset($propertyValue->type)) {
            return $this->__invoke($propertyValue);

            // Else these are alternate values
        } elseif (is_array($propertyValue)) {
            return new AlternateValues(array_map([$this, __METHOD__], $propertyValue));
        }

        list($propertyValue, $language) = $this->processLanguageTaggedPropertyValue($propertyValue);

        return new StringValue($propertyValue, $language);
    }
protected function processPropertyValue ( $ propertyValue ) { // If this is an item value if ( is_object ( $ propertyValue ) && isset ( $ propertyValue -> type ) ) { return $ this -> __invoke ( $ propertyValue ) ; // Else these are alternate values } elseif ( is_array ( $ propertyValue ) ) { return new AlternateValues ( array_map ( [ $ this , __METHOD__ ] , $ propertyValue ) ) ; } list ( $ propertyValue , $ language ) = $ this -> processLanguageTaggedPropertyValue ( $ propertyValue ) ; return new StringValue ( $ propertyValue , $ language ) ; }
Prepare a single property value

@param mixed $propertyValue Property Value

@return ValueInterface Value
Prepare a single property value