class Hardlink extends Document (View source)

Traits

Properties

protected AbstractDao $dao from AbstractModel
protected int $__dataVersionTimestamp from AbstractElement
static array $types possible types of a document from Document
static protected array $pathCache from Document
int $id ID of the document from Document
int $parentId ID of the parent document, on root document this is null from Document
Document $parent The parent document. from Document
string $type static type of this object
string $key Filename/Key of the document from Document
string $path Path to the document, not conaining the key (the full path of the parent document) from Document
int $index Sorter index in the tree, can also be used for generating a navigation and so on from Document
bool $published published or not from Document
int $creationDate timestamp of creationdate from Document
int $modificationDate timestamp of modificationdate from Document
int $userOwner User-ID of the owner from Document
int $userModification User-ID of the user last modified the document from Document
$userPermissions Permissions for the user which requested this document in editmode* from Document
Dependency $dependencies Dependencies for this document from Document
array $properties List of Property, concerning the folder from Document
array $childs Contains a list of child-documents from Document
bool $hasChilds Indicator of document has childs or not. from Document
array $siblings Contains a list of sibling documents from Document
bool $hasSiblings Indicator if document has siblings or not from Document
string $locked Check if the document is locked. from Document
array $scheduledTasks Contains all scheduled tasks from ScheduledTasksTrait
int $sourceId
bool $propertiesFromSource
bool $childsFromSource

Methods

Dao
getDao()

No description

setDao($dao)

No description

getResource() deprecated

No description

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

No description

static string|null
locateDaoClass(string $modelClass)

No description

$this
setValues(array $data = [])

No description

$this
setValue($key, $value)

No description

array
__sleep()

No description

from Document
mixed
__call($method, $args)

No description

__clone()

No description

array
getObjectVars()

returns object values without the dao

array
__debugInfo()

No description

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

updateModificationInfos()

No description

mixed
getProperty(string $name, bool $asContainer = false)

Get specific property data or the property object itself ($asContainer=true) by its name, if the property doesn't exists return null

bool
hasProperty($name)

No description

removeProperty($name)

No description

string
getCacheTag()

get the cache tag for the element

array
getCacheTags(array $tags = [])

Resolves dependencies and create tags for caching out of them

array
resolveDependencies()

No description

$this
isLocked()

Returns true if the element is locked

array
getUserPermissions()

No description

bool
isAllowed(string $type)

This is used for user-permissions, pass a permission type (eg. list, view, save) an you know if the current user is allowed to perform the requested action

unlockPropagate()

No description

validatePathLength()

No description

bool
hasNoChilds()

Inverted hasChilds()

string
__toString()

No description

int
__getDataVersionTimestamp()

No description

__setDataVersionTimestamp(int $_dataVersionTimestamp)

No description

bool
__isBasedOnLatestData()

No description

from Document
mixed
getChilds() deprecated

No description

mixed
setChilds() deprecated

No description

mixed
hasChilds() deprecated

No description

static 
addDocumentType($type)

Add document type to the $types array. It defines additional document types available in Pimcore.

from Document
static 
setHideUnpublished(bool $flag)

Set true if want to hide documents.

from Document
static bool
doHideUnpublished()

Checks if unpublished documents should be hidden.

from Document
static array
getTypes()

get possible types

from Document
getByPath(string $path, bool $force = false)

Static helper to get a Document by it's path

from Document
getById($id, bool $force = false)

No description

from Document
static Document
create(int $parentId, array $data = [], bool $save = true)

Static helper to quickly create a new document

from Document
static Listing
getList(array $config = [])

Returns the documents list instance.

from Document
static int
getTotalCount(array $config = [])

Get total count of documents.

from Document
save()

No description

from Document
correctPath()

Validate the document path.

from Document
update(array $params = [])

No description

saveIndex(int $index)

Update the document index.

from Document
clearDependentCache(array $additionalTags = [])

Clear the cache related to the document.

from Document
getDependencies()

Returns the dependencies of the document

from Document
array
setChildren($children)

set the children of the document

from Document
array
getChildren(bool $unpublished = false)

No description

bool
hasChildren()

hast to overwrite the resource implementation because there can be inherited childs

array
getSiblings(bool $unpublished = false)

Get a list of the sibling documents

from Document
bool
hasSiblings()

Returns true if the document has at least one sibling

from Document
string
getLocked()

Returns true if the element is locked

from Document
$this
setLocked(bool $locked)

No description

from Document
delete()

No description

string
getFullPath()

No description

from Document
mixed
prepareFrontendPath($path)

No description

from Document
int
getCreationDate()

No description

from Document
int
getId()

No description

from Document
string
getKey()

No description

from Document
int
getModificationDate()

No description

from Document
int
getParentId()

No description

from Document
string
getPath()

No description

from Document
string
getRealPath()

No description

from Document
string
getRealFullPath()

No description

from Document
$this
setCreationDate(int $creationDate)

No description

from Document
setId(int $id)

Set the id of the document.

from Document
setKey(int $key)

Set the document key.

from Document
$this
setModificationDate(int $modificationDate)

No description

from Document
setParentId(int $parentId)

Set the parent id of the document.

from Document
setPath(string $path)

Set the document path.

from Document
int
getIndex()

Returns the document index.

from Document
setIndex(int $index)

Set the document index.

from Document
string
getType()

No description

from Document
setType(int $type)

Set the document type.

from Document
int
getUserModification()

No description

from Document
int
getUserOwner()

No description

from Document
$this
setUserModification(int $userModification)

No description

from Document
$this
setUserOwner(int $userOwner)

No description

from Document
bool
isPublished()

Checks if the document is published.

from Document
bool
getPublished()

Checks if the document is published.

from Document
setPublished(int $published)

Set the publish status of the document.

from Document
array
getProperties()

No description

setProperties(array $properties)

Set document properties.

from Document
setProperty(string $name, string $type, mixed $data, bool $inherited = false, bool $inheritable = true)

Set the document property.

from Document
getParent()

Returns the parent document instance.

from Document
setParent(Document $parent)

Set the parent document instance.

from Document
__wakeup()

No description

from Document
removeInheritedProperties()

Removes all inherited properties.

from Document
renewInheritedProperties()

Renews all inherited properties.

from Document
bool
doRenderWithLegacyStack()

returns true if document should be rendered with legacy stack

from Document
array
getScheduledTasks()

No description

$this
setScheduledTasks($scheduledTasks)

No description

saveScheduledTasks()

No description

getSourceDocument()

No description

setChildrenFromSource($childsFromSource)

No description

setChildsFromSource($childsFromSource) deprecated

No description

bool
getChildrenFromSource()

No description

bool
getChildsFromSource() deprecated

No description

$this
setSourceId($sourceId)

No description

int
getSourceId()

No description

$this
setPropertiesFromSource($propertiesFromSource)

No description

bool
getPropertiesFromSource()

No description

Details

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

static string|null locateDaoClass(string $modelClass)

Parameters

string $modelClass

Return Value

string|null

$this setValues(array $data = [])

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

__clone()

array getObjectVars()

returns object values without the dao

Return Value

array

array __debugInfo()

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

protected updateModificationInfos()

mixed getProperty(string $name, bool $asContainer = false)

Get specific property data or the property object itself ($asContainer=true) by its name, if the property doesn't exists return null

Parameters

string $name
bool $asContainer

Return Value

mixed

bool hasProperty($name)

Parameters

$name

Return Value

bool

removeProperty($name)

Parameters

$name

string getCacheTag()

get the cache tag for the element

Return Value

string

array getCacheTags(array $tags = [])

Resolves dependencies and create tags for caching out of them

Parameters

array $tags

Return Value

array

array resolveDependencies()

Return Value

array

See also

Document::resolveDependencies

$this isLocked()

Returns true if the element is locked

Return Value

$this

array getUserPermissions()

Return Value

array

bool isAllowed(string $type)

This is used for user-permissions, pass a permission type (eg. list, view, save) an you know if the current user is allowed to perform the requested action

Parameters

string $type

Return Value

bool

unlockPropagate()

protected validatePathLength()

bool hasNoChilds()

Inverted hasChilds()

Return Value

bool

string __toString()

Return Value

string

int __getDataVersionTimestamp()

Return Value

int

__setDataVersionTimestamp(int $_dataVersionTimestamp)

Parameters

int $_dataVersionTimestamp

bool __isBasedOnLatestData()

Return Value

bool

mixed getChilds() deprecated

deprecated

Return Value

mixed

mixed setChilds() deprecated

deprecated

Return Value

mixed

mixed hasChilds() deprecated

deprecated

Return Value

mixed

static addDocumentType($type)

Add document type to the $types array. It defines additional document types available in Pimcore.

Parameters

$type

static setHideUnpublished(bool $flag)

Set true if want to hide documents.

Parameters

bool $flag

static bool doHideUnpublished()

Checks if unpublished documents should be hidden.

Return Value

bool

static array getTypes()

get possible types

Return Value

array

static Document|Email|Folder|Hardlink|Link|Page|Printcontainer|Printpage|Snippet getByPath(string $path, bool $force = false)

Static helper to get a Document by it's path

Parameters

string $path
bool $force

Return Value

Document|Email|Folder|Hardlink|Link|Page|Printcontainer|Printpage|Snippet

static ElementInterface getById($id, bool $force = false)

Parameters

$id
bool $force

Return Value

ElementInterface $resource

static Document create(int $parentId, array $data = [], bool $save = true)

Static helper to quickly create a new document

Parameters

int $parentId
array $data
bool $save

Return Value

Document

static Listing getList(array $config = [])

Returns the documents list instance.

Parameters

array $config

Return Value

Listing

Exceptions

Exception

static int getTotalCount(array $config = [])

Get total count of documents.

Parameters

array $config

Return Value

int count

Document save()

Return Value

Document

Exceptions

Exception

correctPath()

Validate the document path.

Exceptions

Exception

protected update(array $params = [])

Parameters

array $params additional parameters (e.g. "versionNote" for the version note)

Exceptions

Exception

saveIndex(int $index)

Update the document index.

Parameters

int $index

clearDependentCache(array $additionalTags = [])

Clear the cache related to the document.

Parameters

array $additionalTags

Dependency getDependencies()

Returns the dependencies of the document

Return Value

Dependency

array setChildren($children)

set the children of the document

Parameters

$children

Return Value

array

array getChildren(bool $unpublished = false)

Parameters

bool $unpublished

Return Value

array

bool hasChildren()

hast to overwrite the resource implementation because there can be inherited childs

Return Value

bool

array getSiblings(bool $unpublished = false)

Get a list of the sibling documents

Parameters

bool $unpublished

Return Value

array

bool hasSiblings()

Returns true if the document has at least one sibling

Return Value

bool

string getLocked()

Returns true if the element is locked

Return Value

string

$this setLocked(bool $locked)

Parameters

bool $locked

Return Value

$this

delete()

See also

Document::delete

string getFullPath()

Return Value

string

protected mixed prepareFrontendPath($path)

Parameters

$path

Return Value

mixed

int getCreationDate()

Return Value

int

int getId()

Return Value

int $id

string getKey()

Return Value

string

int getModificationDate()

Return Value

int

int getParentId()

Return Value

int

string getPath()

Return Value

string

string getRealPath()

Return Value

string

string getRealFullPath()

Return Value

string

$this setCreationDate(int $creationDate)

Parameters

int $creationDate

Return Value

$this

Document setId(int $id)

Set the id of the document.

Parameters

int $id

Return Value

Document

Document setKey(int $key)

Set the document key.

Parameters

int $key

Return Value

Document

$this setModificationDate(int $modificationDate)

Parameters

int $modificationDate

Return Value

$this

Document setParentId(int $parentId)

Set the parent id of the document.

Parameters

int $parentId

Return Value

Document

Document setPath(string $path)

Set the document path.

Parameters

string $path

Return Value

Document

int getIndex()

Returns the document index.

Return Value

int

Document setIndex(int $index)

Set the document index.

Parameters

int $index

Return Value

Document

string getType()

Return Value

string

Document setType(int $type)

Set the document type.

Parameters

int $type

Return Value

Document

int getUserModification()

Return Value

int

int getUserOwner()

Return Value

int

$this setUserModification(int $userModification)

Parameters

int $userModification

Return Value

$this

$this setUserOwner(int $userOwner)

Parameters

int $userOwner

Return Value

$this

bool isPublished()

Checks if the document is published.

Return Value

bool

bool getPublished()

Checks if the document is published.

Return Value

bool

Document setPublished(int $published)

Set the publish status of the document.

Parameters

int $published

Return Value

Document

array getProperties()

Return Value

array

Document setProperties(array $properties)

Set document properties.

Parameters

array $properties

Return Value

Document

Document setProperty(string $name, string $type, mixed $data, bool $inherited = false, bool $inheritable = true)

Set the document property.

Parameters

string $name
string $type
mixed $data
bool $inherited
bool $inheritable

Return Value

Document

Document getParent()

Returns the parent document instance.

Return Value

Document

Document setParent(Document $parent)

Set the parent document instance.

Parameters

Document $parent

Return Value

Document

__wakeup()

removeInheritedProperties()

Removes all inherited properties.

renewInheritedProperties()

Renews all inherited properties.

bool doRenderWithLegacyStack()

returns true if document should be rendered with legacy stack

Return Value

bool

array getScheduledTasks()

Return Value

array the $scheduledTasks

$this setScheduledTasks($scheduledTasks)

Parameters

$scheduledTasks

Return Value

$this

saveScheduledTasks()

PageSnippet getSourceDocument()

Return Value

PageSnippet

Hardlink setChildrenFromSource($childsFromSource)

Parameters

$childsFromSource

Return Value

Hardlink

Hardlink setChildsFromSource($childsFromSource) deprecated

deprecated

Parameters

$childsFromSource

Return Value

Hardlink

bool getChildrenFromSource()

Return Value

bool

bool getChildsFromSource() deprecated

deprecated

Return Value

bool

$this setSourceId($sourceId)

Parameters

$sourceId

Return Value

$this

int getSourceId()

Return Value

int

$this setPropertiesFromSource($propertiesFromSource)

Parameters

$propertiesFromSource

Return Value

$this

bool getPropertiesFromSource()

Return Value

bool