Node.php
32 lines
| 1 | <?php |
| 2 | |
| 3 | namespace Give\Framework\FieldsAPI\Contracts; |
| 4 | |
| 5 | use JsonSerializable; |
| 6 | |
| 7 | interface Node extends JsonSerializable |
| 8 | { |
| 9 | /** |
| 10 | * The primitive node type, one of "field", "element", or "group". |
| 11 | * |
| 12 | * @since 2.22.0 |
| 13 | */ |
| 14 | public function getNodeType(): string; |
| 15 | |
| 16 | /** |
| 17 | * Get the field’s type. |
| 18 | */ |
| 19 | public function getType(): string; |
| 20 | |
| 21 | /** |
| 22 | * Get the node’s name. |
| 23 | */ |
| 24 | public function getName(): string; |
| 25 | |
| 26 | /** |
| 27 | * {@inheritdoc} |
| 28 | */ |
| 29 | #[\ReturnTypeWillChange] |
| 30 | public function jsonSerialize(); |
| 31 | } |
| 32 |