kernel/private/api/content/field_set.php
public static function fromContentObject( eZContentObject $contentObject )
    {
        $set = new ezpContentFieldSet();
        $languages = $contentObject->availableLanguages();
        foreach( $languages as $language )
        {
            $set->childrenFieldSets[$language] =
                ezpContentFieldSet::fromDataMap( $contentObject->fetchDataMap( false, $language ) );
        }

        // this sequence is REALLY ugly
        reset( $languages );
        $set->setActiveLanguage( current( $languages ) );

        return $set;
    }
public static function fromContentObject( eZContentObject $contentObject )
    {
        $set = new ezpContentFieldSet();
        $languages = $contentObject->availableLanguages();
        foreach( $languages as $language )
        {
            $set->childrenFieldSets[$language] =
                ezpContentFieldSet::fromDataMap( $contentObject->fetchDataMap( false, $language ) );
        }

        // this sequence is REALLY ugly
        reset( $languages );
        $set->setActiveLanguage( current( $languages ) );

        return $set;
    }
public static function fromContentObject ( eZContentObject $ contentObject ) { $ set = new ezpContentFieldSet ( ) ; $ languages = $ contentObject -> availableLanguages ( ) ; foreach ( $ languages as $ language ) { $ set -> childrenFieldSets [ $ language ] = ezpContentFieldSet :: fromDataMap ( $ contentObject -> fetchDataMap ( false , $ language ) ) ; } // this sequence is REALLY ugly reset ( $ languages ) ; $ set -> setActiveLanguage ( current ( $ languages ) ) ; return $ set ; }
Initializes a level one ezpContentFieldSet from an eZContentObject
@param eZContentObject $contentObject
@return ezpContentFieldSet
Initializes a level one ezpContentFieldSet from an eZContentObject