class Service (View source)

Properties

protected EntityManagerInterface $entityManager
protected Application $app
protected Repository $config
protected ResolverFactory $resolverFactory
protected Cache $cache
protected Service $siteTypeService

Methods

setEntityManager(EntityManagerInterface $entityManager)

No description

__construct(EntityManagerInterface $entityManager, Application $app, Repository $configRepository, ResolverFactory $resolverFactory, Service $siteTypeService)

No description

setCache(mixed $cache)

No description

Site[]
getByType(Type $type)

No description

Site|null
getByHandle(string $handle)

No description

Site|null
getDefault()

No description

add(Type $type, Theme $theme, string $handle, string $name, string $locale, bool $default = false)

No description

getController(Site $site)

No description

Tree|null
getSiteTreeByID(int $siteTreeID)

No description

Site|null
getByID(int $id)

No description

delete(Site $site)

No description

Site[]
getList(string $sort = 'name')

Returns a list of sites. If $sort = 'name' then the sites will be sorted by site name. If sort is false it will not be sorted. Only name is supported for now.

installDefault(string|null $locale = null)

No description

Site|null
getSite()

Resolve the active site This method MUST be treated as final by extending drivers, but MAY be replaced by a complete override.

Site|null
getActiveSiteForEditing()

Resolve the active site for editing This method MUST be treated as final by extending drivers, but MAY be replaced by a complete override.

getSiteDomains(Site $site)

No description

getSiteByDomain($domain)

No description

Details

setEntityManager(EntityManagerInterface $entityManager)

No description

Parameters

EntityManagerInterface $entityManager

__construct(EntityManagerInterface $entityManager, Application $app, Repository $configRepository, ResolverFactory $resolverFactory, Service $siteTypeService)

No description

Parameters

EntityManagerInterface $entityManager
Application $app
Repository $configRepository
ResolverFactory $resolverFactory
Service $siteTypeService

setCache(mixed $cache)

No description

Parameters

mixed $cache

Site[] getByType(Type $type)

No description

Parameters

Type $type

Return Value

Site[]

Site|null getByHandle(string $handle)

No description

Parameters

string $handle

Return Value

Site|null

Site|null getDefault()

No description

Return Value

Site|null

Site add(Type $type, Theme $theme, string $handle, string $name, string $locale, bool $default = false)

No description

Parameters

Type $type
Theme $theme
string $handle
string $name
string $locale
bool $default

Return Value

Site

getController(Site $site)

No description

Parameters

Site $site

Tree|null getSiteTreeByID(int $siteTreeID)

No description

Parameters

int $siteTreeID

Return Value

Tree|null

Site|null getByID(int $id)

No description

Parameters

int $id

Return Value

Site|null

delete(Site $site)

No description

Parameters

Site $site

Site[] getList(string $sort = 'name')

Returns a list of sites. If $sort = 'name' then the sites will be sorted by site name. If sort is false it will not be sorted. Only name is supported for now.

Parameters

string $sort

Return Value

Site[]

Site installDefault(string|null $locale = null)

No description

Parameters

string|null $locale

Return Value

Site

Site|null getSite()

Resolve the active site This method MUST be treated as final by extending drivers, but MAY be replaced by a complete override.

Return Value

Site|null

Site|null getActiveSiteForEditing()

Resolve the active site for editing This method MUST be treated as final by extending drivers, but MAY be replaced by a complete override.

Return Value

Site|null

getSiteDomains(Site $site)

No description

Parameters

Site $site

getSiteByDomain($domain)

No description

Parameters

$domain