Skip to content

Commit

Permalink
Fixing inline doc (#197)
Browse files Browse the repository at this point in the history
* Fixing inline doc

* Added inline doc - setting another function as public

* more inline doc fixes

* typo fixed
  • Loading branch information
pkamps authored Mar 5, 2021
1 parent f3c0833 commit 11212c5
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 11 deletions.
11 changes: 6 additions & 5 deletions kernel/classes/ezcontentobject.php
Original file line number Diff line number Diff line change
Expand Up @@ -3936,11 +3936,12 @@ function assignedNodes( $asObject = true, $checkVisibility = false )
}

/**
* Returns the main node id for the current object and sets the attribute MainNodeID in the current object
* Returns the main node id for the current object and
* sets the attribute MainNodeID in the current object
*
* @return int|null
*/
function mainNodeID()
public function mainNodeID()
{
if ( !is_numeric( $this->MainNodeID ) )
{
Expand All @@ -3951,11 +3952,11 @@ function mainNodeID()
}

/**
* Returns the main node id for the current object.
* Returns the main node for the current object.
*
* @return int|null
* @return eZContentObjectTreeNode|null
*/
function mainNode()
public function mainNode()
{
return eZContentObjectTreeNode::findMainNode( $this->attribute( 'id' ), true );
}
Expand Down
19 changes: 13 additions & 6 deletions kernel/classes/ezcontentobjecttreenode.php
Original file line number Diff line number Diff line change
Expand Up @@ -2966,7 +2966,7 @@ static function fetchAliasesFromNodeList( $nodeList )
* @param int $objectID
* @param boolean $asObject
*
* @return int|null
* @return int|eZContentObjectTreeNode|null
*/
static function findMainNode( $objectID, $asObject = false )
{
Expand Down Expand Up @@ -3189,11 +3189,17 @@ static function fetchNode( $contentObjectID, $parentNodeID )
return $returnValue;
}

function fetchParent()
/**
* @return eZContentObjectTreeNode|null
*/
public function fetchParent()
{
return $this->fetch( $this->attribute( 'parent_node_id' ) );
}

/**
* @return array
*/
function pathArray()
{
$pathString = $this->attribute( 'path_string' );
Expand All @@ -3207,7 +3213,9 @@ function pathArray()
return $pathArray;
}


/**
* @return eZContentObjectTreeNode[]|false
*/
function fetchPath()
{
$nodePath = $this->attribute( 'path_string' );
Expand Down Expand Up @@ -5870,14 +5878,13 @@ function url()
/**
* Returns the node's class identifier
*
* @return string|bool|string|null
* @return string|bool|null
*/
public function classIdentifier()
{
if ( $this->ClassIdentifier === null )
{
$object = $this->object();
$this->ClassIdentifier = $object->contentClassIdentifier();
$this->ClassIdentifier = $this->object()->contentClassIdentifier();
}

return $this->ClassIdentifier;
Expand Down

0 comments on commit 11212c5

Please sign in to comment.