<?php
use Sulu\Component\Localization\Localization;
use Sulu\Component\Webspace\Manager\WebspaceCollection;
use Sulu\Component\Webspace\Portal;
use Sulu\Component\Webspace\PortalInformation;
use Sulu\Component\Webspace\Environment;
use Sulu\Component\Webspace\Security;
use Sulu\Component\Webspace\Segment;
use Sulu\Component\Webspace\Url;
use Sulu\Component\Webspace\CustomUrl;
use Sulu\Component\Webspace\Webspace;
use Sulu\Component\Webspace\Navigation;
use Sulu\Component\Webspace\NavigationContext;
/**
* websiteWebspaceCollectionCache
*
* DO NOT EDIT
* This file is autogenerated by the Sulu Webspace component
*/
class websiteWebspaceCollectionCache extends WebspaceCollection
{
public function __construct()
{
$webspaceRefs = array();
$portalRefs = array();
$localizationRefs = array();
$segmentRefs = array();
$portalInformationRefs = array();
// new webspace
$webspace = new Webspace();
$webspace->setKey('duplicated');
$webspace->setName("duplicated");
// add localization to webspace
$localization0 = new Localization('fr', '');
$localization0->setShadow('');
$localization0->setDefault(true);
$localization0->setXDefault('');
$localizationRefs['duplicated_fr'] = $localization0;
$webspace->addLocalization($localization0);
// add localization to webspace
$localization0 = new Localization('en', '');
$localization0->setShadow('');
$localization0->setDefault(false);
$localization0->setXDefault('');
$localizationRefs['duplicated_en'] = $localization0;
$webspace->addLocalization($localization0);
// add theme
$webspace->addTemplate('search', 'search/search');
$webspace->addTemplate('error', 'error/error');
$webspace->addTemplate('error-404', 'error/error-404');
$webspace->addDefaultTemplate('page', 'default');
$webspace->addDefaultTemplate('home', 'default');
$webspace->addExcludedTemplate('partner_login');
// add navigation
$navigation = new Navigation();
$navigation->addContext(new NavigationContext('main', array(
'title' => array(
'fr' => 'Navigation principale',
'en' => 'Main Navigation',
)
,
)
));
$navigation->addContext(new NavigationContext('footer', array(
'title' => array(
'en' => 'Footer Navigation',
'fr' => 'Navigation du pied de page',
)
,
)
));
$webspace->setNavigation($navigation);
$webspace->setResourceLocatorStrategy('tree_leaf_edit');
// new portal
$portal = new Portal();
$portal->setName('duplicated.croisiland.com');
$portal->setKey('duplicated.croisiland');
$portal->setWebspace($webspace);
// add localization
$localization = new Localization('fr', '');
$localization->setDefault('1');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add localization
$localization = new Localization('en', '');
$localization->setDefault('');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add environment
$environment = new Environment();
$environment->setType('prod');
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('stage');
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('test');
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('duplicated.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('dev');
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
if (isset($portalRefs['duplicated.croisiland'])) {
throw new \InvalidArgumentException('Portal with key "duplicated.croisiland" already exists in webspace "' . $portalRefs['duplicated.croisiland']->getWebspace()->getKey() . '" and conflicts with webspace "duplicated". Portal keys must be unique across all webspaces.');
}
$portalRefs['duplicated.croisiland'] = $portal;
$webspace->addPortal($portal);
$webspaceRefs['duplicated'] = $webspace;
// new webspace
$webspace = new Webspace();
$webspace->setKey('hello');
$webspace->setName("hello");
// add localization to webspace
$localization0 = new Localization('fr', '');
$localization0->setShadow('');
$localization0->setDefault(true);
$localization0->setXDefault('');
$localizationRefs['hello_fr'] = $localization0;
$webspace->addLocalization($localization0);
// add localization to webspace
$localization0 = new Localization('en', '');
$localization0->setShadow('');
$localization0->setDefault(false);
$localization0->setXDefault('');
$localizationRefs['hello_en'] = $localization0;
$webspace->addLocalization($localization0);
// add theme
$webspace->addTemplate('search', 'search/search');
$webspace->addTemplate('error', 'error/error');
$webspace->addTemplate('error-404', 'error/error-404');
$webspace->addDefaultTemplate('page', 'default');
$webspace->addDefaultTemplate('home', 'default');
$webspace->addExcludedTemplate('partner_login');
// add navigation
$navigation = new Navigation();
$navigation->addContext(new NavigationContext('main', array(
'title' => array(
'fr' => 'Navigation principale',
'en' => 'Main Navigation',
)
,
)
));
$navigation->addContext(new NavigationContext('footer', array(
'title' => array(
'en' => 'Footer Navigation',
'fr' => 'Navigation du pied de page',
)
,
)
));
$webspace->setNavigation($navigation);
$webspace->setResourceLocatorStrategy('tree_leaf_edit');
// new portal
$portal = new Portal();
$portal->setName('hello.croisiland.com');
$portal->setKey('hello.croisiland');
$portal->setWebspace($webspace);
// add localization
$localization = new Localization('fr', '');
$localization->setDefault('1');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add localization
$localization = new Localization('en', '');
$localization->setDefault('');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add environment
$environment = new Environment();
$environment->setType('prod');
// add environment url
$url = new Url();
$url->setUrl('hello.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('hello.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('stage');
// add environment url
$url = new Url();
$url->setUrl('hello.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('hello.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('test');
// add environment url
$url = new Url();
$url->setUrl('hello.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('hello.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('dev');
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
if (isset($portalRefs['hello.croisiland'])) {
throw new \InvalidArgumentException('Portal with key "hello.croisiland" already exists in webspace "' . $portalRefs['hello.croisiland']->getWebspace()->getKey() . '" and conflicts with webspace "hello". Portal keys must be unique across all webspaces.');
}
$portalRefs['hello.croisiland'] = $portal;
$webspace->addPortal($portal);
$webspaceRefs['hello'] = $webspace;
// new webspace
$webspace = new Webspace();
$webspace->setKey('main-website');
$webspace->setName("Site public Croisiland");
// add localization to webspace
$localization0 = new Localization('fr', '');
$localization0->setShadow('');
$localization0->setDefault(true);
$localization0->setXDefault('');
$localizationRefs['main-website_fr'] = $localization0;
$webspace->addLocalization($localization0);
// add localization to webspace
$localization0 = new Localization('en', '');
$localization0->setShadow('');
$localization0->setDefault(false);
$localization0->setXDefault('');
$localizationRefs['main-website_en'] = $localization0;
$webspace->addLocalization($localization0);
// add theme
$webspace->addTemplate('search', 'search/search');
$webspace->addTemplate('error', 'error/error');
$webspace->addTemplate('error-404', 'error/error-404');
$webspace->addDefaultTemplate('page', 'default');
$webspace->addDefaultTemplate('home', 'default');
$webspace->addExcludedTemplate('partner_login');
// add navigation
$navigation = new Navigation();
$navigation->addContext(new NavigationContext('main', array(
'title' => array(
'fr' => 'Navigation principale',
'en' => 'Main Navigation',
)
,
)
));
$navigation->addContext(new NavigationContext('footer', array(
'title' => array(
'en' => 'Footer Navigation',
'fr' => 'Navigation du pied de page',
)
,
)
));
$webspace->setNavigation($navigation);
$webspace->setResourceLocatorStrategy('tree_leaf_edit');
// new portal
$portal = new Portal();
$portal->setName('croisiland.com');
$portal->setKey('croisiland');
$portal->setWebspace($webspace);
// add localization
$localization = new Localization('fr', '');
$localization->setDefault('1');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add localization
$localization = new Localization('en', '');
$localization->setDefault('');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add environment
$environment = new Environment();
$environment->setType('prod');
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('stage');
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('test');
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('dev');
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu.local.nip.io/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('sulu-envdev.local/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
if (isset($portalRefs['croisiland'])) {
throw new \InvalidArgumentException('Portal with key "croisiland" already exists in webspace "' . $portalRefs['croisiland']->getWebspace()->getKey() . '" and conflicts with webspace "main-website". Portal keys must be unique across all webspaces.');
}
$portalRefs['croisiland'] = $portal;
$webspace->addPortal($portal);
$webspaceRefs['main-website'] = $webspace;
// new webspace
$webspace = new Webspace();
$webspace->setKey('test');
$webspace->setName("test");
// add localization to webspace
$localization0 = new Localization('fr', '');
$localization0->setShadow('');
$localization0->setDefault(true);
$localization0->setXDefault('');
$localizationRefs['test_fr'] = $localization0;
$webspace->addLocalization($localization0);
// add localization to webspace
$localization0 = new Localization('en', '');
$localization0->setShadow('');
$localization0->setDefault(false);
$localization0->setXDefault('');
$localizationRefs['test_en'] = $localization0;
$webspace->addLocalization($localization0);
// add theme
$webspace->addTemplate('search', 'search/search');
$webspace->addTemplate('error', 'error/error');
$webspace->addTemplate('error-404', 'error/error-404');
$webspace->addDefaultTemplate('page', 'default');
$webspace->addDefaultTemplate('home', 'default');
$webspace->addExcludedTemplate('partner_login');
// add navigation
$navigation = new Navigation();
$navigation->addContext(new NavigationContext('main', array(
'title' => array(
'fr' => 'Navigation principale',
'en' => 'Main Navigation',
)
,
)
));
$navigation->addContext(new NavigationContext('footer', array(
'title' => array(
'en' => 'Footer Navigation',
'fr' => 'Navigation du pied de page',
)
,
)
));
$webspace->setNavigation($navigation);
$webspace->setResourceLocatorStrategy('tree_leaf_edit');
// new portal
$portal = new Portal();
$portal->setName('test.croisiland.com');
$portal->setKey('test.croisiland');
$portal->setWebspace($webspace);
// add localization
$localization = new Localization('fr', '');
$localization->setDefault('1');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add localization
$localization = new Localization('en', '');
$localization->setDefault('');
$localization->setXDefault('');
$portal->addLocalization($localization);
// add environment
$environment = new Environment();
$environment->setType('prod');
// add environment url
$url = new Url();
$url->setUrl('test.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('stage');
// add environment url
$url = new Url();
$url->setUrl('test.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('test');
// add environment url
$url = new Url();
$url->setUrl('test.{host}');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('{host}/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.{host}/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
// add environment
$environment = new Environment();
$environment->setType('dev');
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(true);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('cms.preprod-croisiland.dev/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.sulu-envdev.local');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.sulu-envdev.local/fr');
$url->setLanguage('fr');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
// add environment url
$url = new Url();
$url->setUrl('test.sulu-envdev.local/en');
$url->setLanguage('en');
$url->setCountry('');
$url->setSegment('');
$url->setRedirect('');
$url->setMain(false);
$environment->addUrl($url);
$portal->addEnvironment($environment);
if (isset($portalRefs['test.croisiland'])) {
throw new \InvalidArgumentException('Portal with key "test.croisiland" already exists in webspace "' . $portalRefs['test.croisiland']->getWebspace()->getKey() . '" and conflicts with webspace "test". Portal keys must be unique across all webspaces.');
}
$portalRefs['test.croisiland'] = $portal;
$webspace->addPortal($portal);
$webspaceRefs['test'] = $webspace;
$portalInformationRefs['prod']['duplicated.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_en'],
'duplicated.{host}/en',
null,
null,
false,
'duplicated.{host}/en',
5
);
$portalInformationRefs['prod']['duplicated.{host}'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_fr'],
'duplicated.{host}',
null,
null,
true,
'duplicated.{host}',
5
);
$portalInformationRefs['prod']['hello.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_en'],
'hello.{host}/en',
null,
null,
false,
'hello.{host}/en',
5
);
$portalInformationRefs['prod']['test.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_en'],
'test.{host}/en',
null,
null,
false,
'test.{host}/en',
5
);
$portalInformationRefs['prod']['hello.{host}'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_fr'],
'hello.{host}',
null,
null,
true,
'hello.{host}',
5
);
$portalInformationRefs['prod']['test.{host}'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'test.{host}',
null,
null,
true,
'test.{host}',
5
);
$portalInformationRefs['prod']['{host}/fr'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'{host}/fr',
null,
null,
false,
'{host}/fr',
5
);
$portalInformationRefs['prod']['{host}/en'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_en'],
'{host}/en',
null,
null,
false,
'{host}/en',
5
);
$portalInformationRefs['prod']['{host}'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'{host}',
null,
null,
true,
'{host}',
5
);
$portalInformationRefs['stage']['duplicated.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_en'],
'duplicated.{host}/en',
null,
null,
false,
'duplicated.{host}/en',
5
);
$portalInformationRefs['stage']['duplicated.{host}'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_fr'],
'duplicated.{host}',
null,
null,
true,
'duplicated.{host}',
5
);
$portalInformationRefs['stage']['hello.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_en'],
'hello.{host}/en',
null,
null,
false,
'hello.{host}/en',
5
);
$portalInformationRefs['stage']['test.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_en'],
'test.{host}/en',
null,
null,
false,
'test.{host}/en',
5
);
$portalInformationRefs['stage']['hello.{host}'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_fr'],
'hello.{host}',
null,
null,
true,
'hello.{host}',
5
);
$portalInformationRefs['stage']['test.{host}'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'test.{host}',
null,
null,
true,
'test.{host}',
5
);
$portalInformationRefs['stage']['{host}/fr'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'{host}/fr',
null,
null,
false,
'{host}/fr',
5
);
$portalInformationRefs['stage']['{host}/en'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_en'],
'{host}/en',
null,
null,
false,
'{host}/en',
5
);
$portalInformationRefs['stage']['{host}'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'{host}',
null,
null,
true,
'{host}',
5
);
$portalInformationRefs['test']['duplicated.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_en'],
'duplicated.{host}/en',
null,
null,
false,
'duplicated.{host}/en',
5
);
$portalInformationRefs['test']['duplicated.{host}'] = new PortalInformation(
1,
$webspaceRefs['duplicated'],
$portalRefs['duplicated.croisiland'],
$localizationRefs['duplicated_fr'],
'duplicated.{host}',
null,
null,
true,
'duplicated.{host}',
5
);
$portalInformationRefs['test']['hello.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_en'],
'hello.{host}/en',
null,
null,
false,
'hello.{host}/en',
5
);
$portalInformationRefs['test']['test.{host}/en'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_en'],
'test.{host}/en',
null,
null,
false,
'test.{host}/en',
5
);
$portalInformationRefs['test']['hello.{host}'] = new PortalInformation(
1,
$webspaceRefs['hello'],
$portalRefs['hello.croisiland'],
$localizationRefs['hello_fr'],
'hello.{host}',
null,
null,
true,
'hello.{host}',
5
);
$portalInformationRefs['test']['test.{host}'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'test.{host}',
null,
null,
true,
'test.{host}',
5
);
$portalInformationRefs['test']['{host}/fr'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'{host}/fr',
null,
null,
false,
'{host}/fr',
5
);
$portalInformationRefs['test']['{host}/en'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_en'],
'{host}/en',
null,
null,
false,
'{host}/en',
5
);
$portalInformationRefs['test']['{host}'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'{host}',
null,
null,
true,
'{host}',
5
);
$portalInformationRefs['dev']['cms.preprod-croisiland.dev/fr'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'cms.preprod-croisiland.dev/fr',
null,
null,
false,
'cms.preprod-croisiland.dev/fr',
10
);
$portalInformationRefs['dev']['cms.preprod-croisiland.dev/en'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_en'],
'cms.preprod-croisiland.dev/en',
null,
null,
false,
'cms.preprod-croisiland.dev/en',
10
);
$portalInformationRefs['dev']['cms.preprod-croisiland.dev'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'cms.preprod-croisiland.dev',
null,
null,
true,
'cms.preprod-croisiland.dev',
10
);
$portalInformationRefs['dev']['test.sulu-envdev.local/fr'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'test.sulu-envdev.local/fr',
null,
null,
false,
'test.sulu-envdev.local/fr',
10
);
$portalInformationRefs['dev']['test.sulu-envdev.local/en'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_en'],
'test.sulu-envdev.local/en',
null,
null,
false,
'test.sulu-envdev.local/en',
10
);
$portalInformationRefs['dev']['test.sulu-envdev.local'] = new PortalInformation(
1,
$webspaceRefs['test'],
$portalRefs['test.croisiland'],
$localizationRefs['test_fr'],
'test.sulu-envdev.local',
null,
null,
false,
'test.sulu-envdev.local',
10
);
$portalInformationRefs['dev']['sulu-envdev.local/fr'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'sulu-envdev.local/fr',
null,
null,
false,
'sulu-envdev.local/fr',
10
);
$portalInformationRefs['dev']['sulu.local.nip.io/fr'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'sulu.local.nip.io/fr',
null,
null,
false,
'sulu.local.nip.io/fr',
10
);
$portalInformationRefs['dev']['sulu-envdev.local/en'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_en'],
'sulu-envdev.local/en',
null,
null,
false,
'sulu-envdev.local/en',
10
);
$portalInformationRefs['dev']['sulu-envdev.local'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'sulu-envdev.local',
null,
null,
false,
'sulu-envdev.local',
10
);
$portalInformationRefs['dev']['sulu.local.nip.io'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'sulu.local.nip.io',
null,
null,
false,
'sulu.local.nip.io',
10
);
$portalInformationRefs['dev']['{host}/fr'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'{host}/fr',
null,
null,
false,
'{host}/fr',
5
);
$portalInformationRefs['dev']['{host}/en'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_en'],
'{host}/en',
null,
null,
false,
'{host}/en',
5
);
$portalInformationRefs['dev']['{host}'] = new PortalInformation(
1,
$webspaceRefs['main-website'],
$portalRefs['croisiland'],
$localizationRefs['main-website_fr'],
'{host}',
null,
null,
false,
'{host}',
5
);
$this->setWebspaces($webspaceRefs);
$this->setPortals($portalRefs);
$this->setPortalInformations($portalInformationRefs);
}
}