Skip to content
Permalink
Browse files

Working on the EntityTrait doc blocks

  • Loading branch information...
burzum committed Jan 23, 2017
1 parent 531869c commit 40ba20a6dfd84fdd8a22ade11992f4005ccb2379
Showing with 12 additions and 12 deletions.
  1. +12 −12 src/Datasource/EntityTrait.php
@@ -420,7 +420,7 @@ public function hiddenProperties($properties = null)
/**
* Sets hidden properties.
*
* @param null|array $properties Either an array of properties to treat as virtual or null to get properties
* @param array $properties An array of properties to treat as virtual.
* @param bool $merge Merge the new properties with the existing. By default false.
* @return $this
*/
@@ -1125,16 +1125,10 @@ public function accessible($property, $set = null)
* ### Example:
*
* ```
* $entity->accessible('id', true); // Mark id as not protected
* $entity->accessible('author_id', false); // Mark author_id as protected
* $entity->accessible(['id', 'user_id'], true); // Mark both properties as accessible
* $entity->accessible('*', false); // Mark all properties as protected
* ```
*
* ### Example:
*
* ```
* $entity->accessible('id'); // Returns whether it can be set or not
* $entity->setAccess('id', true); // Mark id as not protected
* $entity->setAccess('author_id', false); // Mark author_id as protected
* $entity->setAccess(['id', 'user_id'], true); // Mark both properties as accessible
* $entity->setAccess('*', false); // Mark all properties as protected
* ```
*
* @param string|array $property single or list of properties to change its accessibility
@@ -1163,6 +1157,12 @@ public function setAccess($property, $set)
/**
* Checks if a property is accessible
*
* ### Example:
*
* ```
* $entity->isAccessible('id'); // Returns whether it can be set or not
* ```
*
* @param string $property Property name to check
* @return bool
*/
@@ -1178,7 +1178,7 @@ public function isAccessible($property)
/**
* Returns the alias of the repository from which this entity came from.
*
* @return string|self
* @return string
*/
public function getSource()
{

0 comments on commit 40ba20a

Please sign in to comment.
You can’t perform that action at this time.