Nextcloud PHP API (master)

Entity
in package

Read onlyYes
FinalYes

Attribute for marking a class as an entity mapped to some database table.

#[Entity(name: 'my_entity')]
final class MyEntity {
    #[Column(name: 'my_column', type: ColumnType::String, default: '')]
    public string $myColumn = '';
}
Tags
since
35.0.0
Attributes
#[Attribute]
\Attribute::TARGET_CLASS
#[Consumable]
$since: '35.0.0'

Table of Contents

Properties

$name  : non-empty-string

Methods

__construct()  : mixed

Properties

$name

public non-empty-string $name

The name of the table in the database.

Methods

__construct()

public __construct(string $name) : mixed
Parameters
$name : string
Tags
since
35.0.0
On this page

Search results