Beta version

class Node extends AbstractDateTimedPositioned

Node entities are the central feature of RZ-CMS, it describes a document-like object which can be inherited with NodesSources to create complex data structures.

Traits

Trait which describe a positioned entity

Constants

DRAFT

PENDING

PUBLISHED

ARCHIVED

DELETED

Methods

int
getId()

Get entity unique identifier.

setId(int $id)

No description

getCreatedAt()

No description

$this
setCreatedAt(DateTime $createdAt)

No description

getUpdatedAt()

No description

$this
setUpdatedAt(DateTime $updatedAt)

No description

preUpdate()

No description

prePersist()

No description

$this
resetDates()

Set creation and update date to now.

float
getPosition()

No description

$this
setPosition(float $newPosition)

Set position as a float to enable increment and decrement by O.5 to insert a node between two others.

static string
getStatusLabel(int $status)

No description

string
getNodeName()

No description

$this
setNodeName(string $nodeName)

No description

boolean
isDynamicNodeName()

Dynamic node name will be updated against default translated nodeSource title at each save.

$this
setDynamicNodeName(boolean $dynamicNodeName)

No description

boolean
isHome()

No description

$this
setHome(boolean $home)

No description

boolean
isVisible()

No description

$this
setVisible(boolean $visible)

No description

int
getStatus()

No description

$this
setStatus(int $status)

No description

boolean
isPublished()

No description

boolean
isPending()

No description

boolean
isDraft()

No description

boolean
isDeleted()

No description

$this
setPublished(boolean $published)

No description

$this
setPending(boolean $pending)

No description

boolean
isLocked()

No description

$this
setLocked(boolean $locked)

No description

integer
getPriority()

No description

$this
setPriority(integer $priority)

No description

mixed
getHideChildren()

No description

setHideChildren(mixed $hideChildren)

No description

boolean
isHidingChildren()

No description

$this
setHidingChildren(boolean $hideChildren)

No description

boolean
isArchived()

No description

$this
setArchived(boolean $archived)

No description

boolean
isSterile()

No description

$this
setSterile(boolean $sterile)

No description

string
getChildrenOrder()

No description

$this
setChildrenOrder(string $childrenOrder)

No description

string
getChildrenOrderDirection()

No description

$this
setChildrenOrderDirection(string $childrenOrderDirection)

No description

getNodeType()

No description

$this
setNodeType(NodeType $nodeType = null)

No description

getParent()

No description

$this
setParent(Node $parent = null)

No description

ArrayCollection
getChildren()

No description

$this
addChild(Node $child)

No description

$this
removeChild(Node $child)

No description

ArrayCollection
getTags()

No description

$this
removeTag(Tag $tag)

No description

$this
addTag(Tag $tag)

No description

ArrayCollection
getCustomForms()

No description

ArrayCollection
getStackTypes()

No description

$this
removeStackType(NodeType $stackType)

No description

$this
addStackType(NodeType $stackType)

No description

ArrayCollection
getNodeSources()

No description

Collection
getNodeSourcesByTranslation(Translation $translation)

Get node-sources using a given translation.

$this
removeNodeSources(NodesSources $ns)

No description

$this
addNodeSources(NodesSources $ns)

No description

ArrayCollection
getBNodes()

Return nodes related to this (B nodes).

ArrayCollection
getANodes()

Return nodes which own a relation with this (A nodes).

getNewsletter()

No description

__construct(NodeType $nodeType = null)

Create a new empty Node according to given node-type.

string
getOneLineSummary()

No description

string
getOneLineSourceSummary()

No description

getHandler()

No description

__clone()

Clone current node and ist relations.

string
__toString()

No description

Details

in AbstractEntity at line 51
int getId()

Get entity unique identifier.

Return Value

int

in AbstractEntity at line 60
AbstractEntity setId(int $id)

Parameters

int $id

Return Value

AbstractEntity

in AbstractDateTimed at line 53
DateTime getCreatedAt()

Return Value

DateTime

in AbstractDateTimed at line 63
$this setCreatedAt(DateTime $createdAt)

Parameters

DateTime $createdAt

Return Value

$this

in AbstractDateTimed at line 78
DateTime getUpdatedAt()

Return Value

DateTime

in AbstractDateTimed at line 88
$this setUpdatedAt(DateTime $updatedAt)

Parameters

DateTime $updatedAt

Return Value

$this

in AbstractDateTimed at line 98
preUpdate()

at line 810
prePersist()

in AbstractDateTimed at line 115
$this resetDates()

Set creation and update date to now.

Return Value

$this

in PositionedTrait at line 45
float getPosition()

Return Value

float

in PositionedTrait at line 58
$this setPosition(float $newPosition)

Set position as a float to enable increment and decrement by O.5 to insert a node between two others.

Parameters

float $newPosition

Return Value

$this

at line 70
static string getStatusLabel(int $status)

Parameters

int $status

Return Value

string

at line 97
string getNodeName()

Return Value

string

at line 107
$this setNodeName(string $nodeName)

Parameters

string $nodeName

Return Value

$this

at line 128
boolean isDynamicNodeName()

Dynamic node name will be updated against default translated nodeSource title at each save.

Disable this parameter if you need to protect your nodeName from title changes.

Return Value

boolean

at line 141
$this setDynamicNodeName(boolean $dynamicNodeName)

Parameters

boolean $dynamicNodeName

Return Value

$this

at line 156
boolean isHome()

Return Value

boolean

at line 166
$this setHome(boolean $home)

Parameters

boolean $home

Return Value

$this

at line 181
boolean isVisible()

Return Value

boolean

at line 191
$this setVisible(boolean $visible)

Parameters

boolean $visible

Return Value

$this

at line 206
int getStatus()

Return Value

int

at line 215
$this setStatus(int $status)

Parameters

int $status

Return Value

$this

at line 225
boolean isPublished()

Return Value

boolean

at line 233
boolean isPending()

Return Value

boolean

at line 241
boolean isDraft()

Return Value

boolean

at line 249
boolean isDeleted()

Return Value

boolean

at line 259
$this setPublished(boolean $published)

Parameters

boolean $published

Return Value

$this

at line 271
$this setPending(boolean $pending)

Parameters

boolean $pending

Return Value

$this

at line 286
boolean isLocked()

Return Value

boolean

at line 296
$this setLocked(boolean $locked)

Parameters

boolean $locked

Return Value

$this

at line 311
integer getPriority()

Return Value

integer

at line 321
$this setPriority(integer $priority)

Parameters

integer $priority

Return Value

$this

at line 336
mixed getHideChildren()

Return Value

mixed

at line 345
Node setHideChildren(mixed $hideChildren)

Parameters

mixed $hideChildren

Return Value

Node

at line 355
boolean isHidingChildren()

Return Value

boolean

at line 365
$this setHidingChildren(boolean $hideChildren)

Parameters

boolean $hideChildren

Return Value

$this

at line 375
boolean isArchived()

Return Value

boolean

at line 385
$this setArchived(boolean $archived)

Parameters

boolean $archived

Return Value

$this

at line 400
boolean isSterile()

Return Value

boolean

at line 410
$this setSterile(boolean $sterile)

Parameters

boolean $sterile

Return Value

$this

at line 425
string getChildrenOrder()

Return Value

string

at line 435
$this setChildrenOrder(string $childrenOrder)

Parameters

string $childrenOrder

Return Value

$this

at line 450
string getChildrenOrderDirection()

Return Value

string

at line 460
$this setChildrenOrderDirection(string $childrenOrderDirection)

Parameters

string $childrenOrderDirection

Return Value

$this

at line 476
NodeType getNodeType()

Return Value

NodeType

at line 486
$this setNodeType(NodeType $nodeType = null)

Parameters

NodeType $nodeType

Return Value

$this

at line 503
Node getParent()

Return Value

Node Parent node

at line 513
$this setParent(Node $parent = null)

Parameters

Node $parent

Return Value

$this

at line 530
ArrayCollection getChildren()

Return Value

ArrayCollection

at line 540
$this addChild(Node $child)

Parameters

Node $child

Return Value

$this

at line 554
$this removeChild(Node $child)

Parameters

Node $child

Return Value

$this

at line 573
ArrayCollection getTags()

Return Value

ArrayCollection

at line 583
$this removeTag(Tag $tag)

Parameters

Tag $tag

Return Value

$this

at line 597
$this addTag(Tag $tag)

Parameters

Tag $tag

Return Value

$this

at line 615
ArrayCollection getCustomForms()

Return Value

ArrayCollection

at line 630
ArrayCollection getStackTypes()

Return Value

ArrayCollection

at line 640
$this removeStackType(NodeType $stackType)

Parameters

NodeType $stackType

Return Value

$this

at line 654
$this addStackType(NodeType $stackType)

Parameters

NodeType $stackType

Return Value

$this

at line 671
ArrayCollection getNodeSources()

Return Value

ArrayCollection

at line 682
Collection getNodeSourcesByTranslation(Translation $translation)

Get node-sources using a given translation.

Parameters

Translation $translation

Return Value

Collection

at line 695
$this removeNodeSources(NodesSources $ns)

Parameters

NodesSources $ns

Return Value

$this

at line 709
$this addNodeSources(NodesSources $ns)

Parameters

NodesSources $ns

Return Value

$this

at line 729
ArrayCollection getBNodes()

Return nodes related to this (B nodes).

Return Value

ArrayCollection

at line 745
ArrayCollection getANodes()

Return nodes which own a relation with this (A nodes).

Return Value

ArrayCollection

at line 758
Newsletter getNewsletter()

Return Value

Newsletter

at line 768
__construct(NodeType $nodeType = null)

Create a new empty Node according to given node-type.

Parameters

NodeType $nodeType

at line 784
string getOneLineSummary()

Return Value

string

at line 793
string getOneLineSourceSummary()

Return Value

string

at line 825
NodeHandler getHandler()

Return Value

NodeHandler

at line 836
__clone()

Clone current node and ist relations.

at line 870
string __toString()

Return Value

string