ITalkBackend.php 898 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. namespace OCP\Talk;
  8. use OCP\IUser;
  9. /**
  10. * Interface for the Talk app to implement
  11. *
  12. * Other apps must not implement nor use this interface in any way. Use the
  13. * broker instead
  14. *
  15. * @see IBroker
  16. * @since 24.0.0
  17. */
  18. interface ITalkBackend {
  19. /**
  20. * @param string $name
  21. * @param IUser[] $moderators
  22. * @param IConversationOptions $options configuration for the conversation
  23. *
  24. * @return IConversation
  25. * @since 24.0.0
  26. */
  27. public function createConversation(string $name,
  28. array $moderators,
  29. IConversationOptions $options): IConversation;
  30. /**
  31. * Delete a conversation by id
  32. *
  33. * @param string $id conversation id
  34. *
  35. * @return void
  36. * @since 26.0.0
  37. */
  38. public function deleteConversation(string $id): void;
  39. }