repod/lib/Db/Note.php

33 lines
665 B
PHP
Raw Normal View History

2023-06-22 18:10:30 +00:00
<?php
2023-06-23 07:44:48 +00:00
2023-06-22 18:10:30 +00:00
declare(strict_types=1);
namespace OCA\RePod\Db;
use JsonSerializable;
use OCP\AppFramework\Db\Entity;
/**
* @method getId(): int
* @method getTitle(): string
* @method setTitle(string $title): void
* @method getContent(): string
* @method setContent(string $content): void
* @method getUserId(): string
* @method setUserId(string $userId): void
*/
class Note extends Entity implements JsonSerializable {
protected string $title = '';
protected string $content = '';
protected string $userId = '';
public function jsonSerialize(): array {
return [
'id' => $this->id,
'title' => $this->title,
'content' => $this->content
];
}
}