883e80dc5c5c47f5f5a2f5ebcff7538b355a5b9f
4 +--------------------------------------------------------------------+
5 | Copyright CiviCRM LLC. All rights reserved. |
7 | This work is published under the GNU AGPLv3 license with some |
8 | permitted exceptions and without any warranty. For full license |
9 | and copyright information, see https://civicrm.org/licensing |
10 +--------------------------------------------------------------------+
16 * @copyright CiviCRM LLC https://civicrm.org/licensing
23 * Retrieves information about all Api4 entities.
25 * @see \Civi\Api4\Generic\AbstractEntity
29 class Entity
extends Generic\AbstractEntity
{
32 * @param bool $checkPermissions
33 * @return Action\Entity\Get
35 public static function get($checkPermissions = TRUE) {
36 return (new Action\Entity\
Get('Entity', __FUNCTION__
))
37 ->setCheckPermissions($checkPermissions);
41 * @param bool $checkPermissions
42 * @return Generic\BasicGetFieldsAction
44 public static function getFields($checkPermissions = TRUE) {
45 return (new Generic\
BasicGetFieldsAction('Entity', __FUNCTION__
, function() {
49 'description' => 'Entity name',
53 'description' => 'Localized title (singular)',
56 'name' => 'title_plural',
57 'description' => 'Localized title (plural)',
61 'description' => 'Base class for this entity',
62 'options' => ['DAOEntity' => 'DAOEntity', 'BasicEntity' => 'BasicEntity', 'BridgeEntity' => 'BridgeEntity', 'AbstractEntity' => 'AbstractEntity'],
65 'name' => 'description',
66 'description' => 'Description from docblock',
70 'description' => 'Comments from docblock',
74 'description' => 'crm-i icon class associated with this entity',
78 'description' => 'Class name for dao-based entities',
82 'data_type' => 'Array',
83 'description' => 'System paths for accessing this entity',
87 'data_type' => 'Array',
88 'description' => 'Any @see annotations from docblock',
91 }))->setCheckPermissions($checkPermissions);
95 * @param bool $checkPermissions
96 * @return Action\Entity\GetLinks
98 public static function getLinks($checkPermissions = TRUE) {
99 return (new Action\Entity\
GetLinks('Entity', __FUNCTION__
))
100 ->setCheckPermissions($checkPermissions);
106 public static function permissions() {
108 'default' => ['access CiviCRM'],