Neos.Neos/Classes/Domain/Model/UserInterfaceMode.php
public static function createByConfiguration($modeName, array $configuration)
    {
        $mode = new static();
        $mode->setName($modeName);
        $mode->setPreview($configuration['isPreviewMode']);
        $mode->setEdit($configuration['isEditingMode']);
        $mode->setTitle($configuration['title']);

        if (isset($configuration['fusionRenderingPath'])) {
            $mode->setFusionPath($configuration['fusionRenderingPath']);
        } else {
            $mode->setFusionPath('');
        }

        if (isset($configuration['options']) && is_array($configuration['options'])) {
            $mode->setOptions($configuration['options']);
        }

        return $mode;
    }
public static function createByConfiguration($modeName, array $configuration)
    {
        $mode = new static();
        $mode->setName($modeName);
        $mode->setPreview($configuration['isPreviewMode']);
        $mode->setEdit($configuration['isEditingMode']);
        $mode->setTitle($configuration['title']);

        if (isset($configuration['fusionRenderingPath'])) {
            $mode->setFusionPath($configuration['fusionRenderingPath']);
        } else {
            $mode->setFusionPath('');
        }

        if (isset($configuration['options']) && is_array($configuration['options'])) {
            $mode->setOptions($configuration['options']);
        }

        return $mode;
    }
public static function createByConfiguration ( $ modeName , array $ configuration ) { $ mode = new static ( ) ; $ mode -> setName ( $ modeName ) ; $ mode -> setPreview ( $ configuration [ 'isPreviewMode' ] ) ; $ mode -> setEdit ( $ configuration [ 'isEditingMode' ] ) ; $ mode -> setTitle ( $ configuration [ 'title' ] ) ; if ( isset ( $ configuration [ 'fusionRenderingPath' ] ) ) { $ mode -> setFusionPath ( $ configuration [ 'fusionRenderingPath' ] ) ; } else { $ mode -> setFusionPath ( '' ) ; } if ( isset ( $ configuration [ 'options' ] ) && is_array ( $ configuration [ 'options' ] ) ) { $ mode -> setOptions ( $ configuration [ 'options' ] ) ; } return $ mode ; }
Creates an UserInterfaceMode object by configuration

@param string $modeName
@param array $configuration
@return static
Creates an UserInterfaceMode object by configuration