You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
nextcloud/lib/private/Talk/ConversationOptions.php

34 lines
651 B
PHP

<?php
declare(strict_types=1);
/**
* SPDX-FileCopyrightText: 2022 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace OC\Talk;
use OCP\Talk\IConversationOptions;
class ConversationOptions implements IConversationOptions {
private bool $isPublic;
private function __construct(bool $isPublic) {
$this->isPublic = $isPublic;
}
public static function default(): self {
return new self(false);
}
public function setPublic(bool $isPublic = true): IConversationOptions {
$this->isPublic = $isPublic;
return $this;
}
public function isPublic(): bool {
return $this->isPublic;
}
}