class Service extends Service (View source)

Methods

Dao
getDao()

No description

setDao($dao)

No description

getResource() deprecated

No description

initDao(null $key = null, bool $forceDetection = false)

No description

$this
setValues(array $data = array())

No description

$this
setValue($key, $value)

No description

array
__sleep()

No description

mixed
__call($method, $args)

No description

void
__clone()

No description

array
getObjectVars()

returns object values without the dao

void
beginTransaction()

No description

void
commit()

No description

void
rollBack()

No description

void
configure()

No description

array
getValidTableColumns(string $table, bool $cache)

No description

void
resetValidTableColumnsCache(string $table)

No description

static string
getIdPath($element)

No description

from Service
static string
getTypePath($element)

No description

from Service
static array
getIdList($list, $idGetter = 'getId')

No description

from Service
static array
from Service
static array
from Service
static array
from Service
getDependedElement(array $config)

No description

from Service
static bool
isPublished(ElementInterface $element = null)

determines whether an element is published

from Service
getElementByPath(string $type, string $path)

No description

from Service
static ElementInterface|string
getSaveCopyName(string $type, string $sourceKey, ElementInterface $target)

Returns a uniqe key for the element in the $target-Path (recursive)

from Service
static bool
pathExists($path, $type = null)

No description

getElementById(string $type, int $id)

No description

from Service
static string
getElementType(ElementInterface $element)

No description

from Service
static string
getType(ElementInterface $element)

determines the type of an element (object,asset,document)

from Service
static void
scheduleForSanityCheck(ElementInterface $element)

Schedules element with this id for sanity check to be cleaned of broken relations

from Service
static 
runSanityCheck()

No description

from Service
static array
minimizePropertiesForEditmode($props)

No description

from Service
static array
gridElementData(ElementInterface $element)

No description

from Service
static string
getFilename(ElementInterface $element)

No description

from Service
static array
findForbiddenPaths($type, $user)

find all elements which the user may not list and therefore may never be shown to the user

from Service
static mixed
renewReferences($data, $initial = true)

renews all references, for example after unserializing an ElementInterface

from Service
static string
correctPath(string $path)

No description

from Service
loadAllFields(ElementInterface $element)

No description

from Service
cleanupBrokenViews()

clean up broken views which were generated by localized fields, .

from Service
static Folder|Folder|Folder
createFolderByPath($path, array $options = array())

No description

from Service
static 
addTreeFilterJoins($cv, $childsList)

Changes the query according to the custom view config

from Service
static 
getCustomViewById($id)

No description

from Service
static mixed|string
getValidKey($key, null $type)

No description

from Service
static bool
isValidKey($key, $type)

No description

from Service
static string
getUniqueKey($item, $nr)

returns a unique key for an element

static 
fixAllowedTypes($data, $type)

No description

from Service
static 
getSafeVersionInfo($versions)

No description

from Service
__construct(null $user = null)

No description

static string
render(Document $document, array $params = array(), bool $useLayout = false)

static function to render a document outside of a view

static 
saveRecursive($document, int $collectGarbageAfterIteration = 25, int $saved)

Save document and all child documents

copyRecursive(Document $target, Document $source)

No description

copyAsChild($target, $source, bool $enableInheritance = false, bool $resetIndex = false)

No description

mixed
copyContents($target, $source)

No description

static void
gridDocumentData(Document $document)

No description

static mixed
loadAllDocumentFields($doc)

No description

static bool
isValidType($type)

No description

static Document
rewriteIds($document, $rewriteConfig, $params = array())

Rewrites id from source to target, $rewriteConfig contains array( "document" => array( SOURCEID => TARGETID, SOURCEID => TARGETID ), "object" => array(.

static Document
getByUrl($url)

No description

Details

at line line 28
Dao getDao()

Return Value

Dao

AbstractModel setDao($dao)

Parameters

$dao

Return Value

AbstractModel

AbstractDao getResource() deprecated

deprecated

Return Value

AbstractDao

initDao(null $key = null, bool $forceDetection = false)

Parameters

null $key
bool $forceDetection

Exceptions

Exception

$this setValues(array $data = array())

Parameters

array $data

Return Value

$this

$this setValue($key, $value)

Parameters

$key
$value

Return Value

$this

array __sleep()

Return Value

array

mixed __call($method, $args)

Parameters

$method
$args

Return Value

mixed

Exceptions

Exception

void __clone()

Return Value

void

array getObjectVars()

returns object values without the dao

Return Value

array

void beginTransaction()

Return Value

void

void commit()

Return Value

void

void rollBack()

Return Value

void

void configure()

Return Value

void

array getValidTableColumns(string $table, bool $cache)

Parameters

string $table
bool $cache

Return Value

array

void resetValidTableColumnsCache(string $table)

Parameters

string $table

Return Value

void

in Service at line line 39
static string getIdPath($element)

Parameters

$element

Return Value

string

in Service at line line 65
static string getTypePath($element)

Parameters

$element

Return Value

string

in Service at line line 105
static array getIdList($list, $idGetter = 'getId')

Parameters

$list
$idGetter

Return Value

array

in Service at line line 130
static array getRequiredByDependenciesForFrontend(Dependency $d)

Parameters

Dependency $d

Return Value

array

in Service at line line 153
static array getRequiresDependenciesForFrontend(Dependency $d)

Parameters

Dependency $d

Return Value

array

in Service at line line 176
static array getDependencyForFrontend(Document|Asset|AbstractObject $element)

Parameters

Document|Asset|AbstractObject $element

Return Value

array

in Service at line line 192
static AbstractObject|Document|Asset getDependedElement(array $config)

Parameters

array $config

Return Value

AbstractObject|Document|Asset

in Service at line line 213
static bool isPublished(ElementInterface $element = null)

determines whether an element is published

Parameters

ElementInterface $element

Return Value

bool

in Service at line line 232
static ElementInterface getElementByPath(string $type, string $path)

Parameters

string $type
string $path

Return Value

ElementInterface

in Service at line line 254
static ElementInterface|string getSaveCopyName(string $type, string $sourceKey, ElementInterface $target)

Returns a uniqe key for the element in the $target-Path (recursive)

Parameters

string $type
string $sourceKey
ElementInterface $target

Return Value

ElementInterface|string

at line line 399
static bool pathExists($path, $type = null)

Parameters

$path
$type

Return Value

bool

in Service at line line 296
static ElementInterface getElementById(string $type, int $id)

Parameters

string $type
int $id

Return Value

ElementInterface

in Service at line line 315
static string getElementType(ElementInterface $element)

Parameters

ElementInterface $element $element

Return Value

string

in Service at line line 336
static string getType(ElementInterface $element)

determines the type of an element (object,asset,document)

Parameters

ElementInterface $element

Return Value

string

in Service at line line 348
static void scheduleForSanityCheck(ElementInterface $element)

Schedules element with this id for sanity check to be cleaned of broken relations

Parameters

ElementInterface $element

Return Value

void

in Service at line line 358
static runSanityCheck()

in Service at line line 415
static array minimizePropertiesForEditmode($props)

Parameters

$props

Return Value

array

in Service at line line 494
static array gridElementData(ElementInterface $element)

Parameters

ElementInterface $element

Return Value

array

in Service at line line 520
static string getFilename(ElementInterface $element)

Parameters

ElementInterface $element

Return Value

string

in Service at line line 534
static array findForbiddenPaths($type, $user)

find all elements which the user may not list and therefore may never be shown to the user

Parameters

$type
$user

Return Value

array

in Service at line line 566
static mixed renewReferences($data, $initial = true)

renews all references, for example after unserializing an ElementInterface

Parameters

$data
$initial

Return Value

mixed

in Service at line line 615
static string correctPath(string $path)

Parameters

string $path

Return Value

string

in Service at line line 637
static ElementInterface loadAllFields(ElementInterface $element)

Parameters

ElementInterface $element

Return Value

ElementInterface

in Service at line line 654
cleanupBrokenViews()

clean up broken views which were generated by localized fields, .

... when removing a language the view isn't valid anymore

in Service at line line 674
static Folder|Folder|Folder createFolderByPath($path, array $options = array())

Parameters

$path
array $options

Return Value

Folder|Folder|Folder

Exceptions

Exception

in Service at line line 750
static addTreeFilterJoins($cv, $childsList)

Changes the query according to the custom view config

Parameters

$cv array
$childsList

in Service at line line 778
static getCustomViewById($id)

Parameters

$id

in Service at line line 795
static mixed|string getValidKey($key, null $type)

Parameters

$key
null $type

Return Value

mixed|string

in Service at line line 833
static bool isValidKey($key, $type)

Parameters

$key
$type

Return Value

bool

at line line 524
static string getUniqueKey($item, $nr)

returns a unique key for an element

Parameters

$item
$nr

Return Value

string

in Service at line line 855
static fixAllowedTypes($data, $type)

Parameters

$data
$type

in Service at line line 897
static getSafeVersionInfo($versions)

Parameters

$versions

at line line 43
__construct(null $user = null)

Parameters

null $user

at line line 57
static string render(Document $document, array $params = array(), bool $useLayout = false)

static function to render a document outside of a view

Parameters

Document $document
array $params
bool $useLayout

Return Value

string

at line line 175
static saveRecursive($document, int $collectGarbageAfterIteration = 25, int $saved)

Save document and all child documents

Parameters

$document
int $collectGarbageAfterIteration
int $saved

at line line 204
Document copyRecursive(Document $target, Document $source)

Parameters

Document $target
Document $source

Return Value

Document copied document

at line line 263
Document copyAsChild($target, $source, bool $enableInheritance = false, bool $resetIndex = false)

Parameters

$target
$source
bool $enableInheritance
bool $resetIndex

Return Value

Document

Exceptions

Exception

at line line 314
mixed copyContents($target, $source)

Parameters

$target
$source

Return Value

mixed

Exceptions

Exception

at line line 358
static void gridDocumentData(Document $document)

Parameters

Document $document

Return Value

void

at line line 379
static mixed loadAllDocumentFields($doc)

Parameters

$doc

Return Value

mixed

at line line 421
static bool isValidType($type)

Parameters

$type

Return Value

bool

at line line 440
static Document rewriteIds($document, $rewriteConfig, $params = array())

Rewrites id from source to target, $rewriteConfig contains array( "document" => array( SOURCEID => TARGETID, SOURCEID => TARGETID ), "object" => array(.

..), "asset" => array(...) )

Parameters

$document
$rewriteConfig
$params

Return Value

Document

at line line 500
static Document getByUrl($url)

Parameters

$url

Return Value

Document