2017-01-24 01:47:14 -05:00
|
|
|
<?php
|
|
|
|
|
/**
|
2024-05-23 03:26:56 -04:00
|
|
|
* SPDX-FileCopyrightText: 2017 Nextcloud GmbH and Nextcloud contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
2017-01-24 01:47:14 -05:00
|
|
|
*/
|
|
|
|
|
namespace OCP\Contacts\ContactsMenu;
|
|
|
|
|
|
|
|
|
|
use JsonSerializable;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Apps should use the IActionFactory to create new action objects
|
|
|
|
|
*
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
|
|
|
|
interface IAction extends JsonSerializable {
|
|
|
|
|
/**
|
|
|
|
|
* @param string $icon absolute URI to an icon
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
2022-03-22 07:39:23 -04:00
|
|
|
public function setIcon(string $icon);
|
2017-01-24 01:47:14 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return string localized action name, e.g. 'Call'
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
2022-03-22 07:39:23 -04:00
|
|
|
public function getName(): string;
|
2017-01-24 01:47:14 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @param string $name localized action name, e.g. 'Call'
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
2022-03-22 07:39:23 -04:00
|
|
|
public function setName(string $name);
|
2017-01-24 01:47:14 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @param int $priority priorize actions, high order ones are shown on top
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
2022-03-22 07:39:23 -04:00
|
|
|
public function setPriority(int $priority);
|
2017-01-24 01:47:14 -05:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return int priority to priorize actions, high order ones are shown on top
|
|
|
|
|
* @since 12.0
|
|
|
|
|
*/
|
2022-03-22 07:39:23 -04:00
|
|
|
public function getPriority(): int;
|
2021-10-18 12:19:37 -04:00
|
|
|
|
|
|
|
|
/**
|
2021-10-20 08:43:45 -04:00
|
|
|
* @param string $appId
|
2021-10-18 12:19:37 -04:00
|
|
|
* @since 23.0.0
|
|
|
|
|
*/
|
2021-10-20 08:43:45 -04:00
|
|
|
public function setAppId(string $appId);
|
2021-10-18 12:19:37 -04:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return string
|
|
|
|
|
* @since 23.0.0
|
|
|
|
|
*/
|
2021-10-20 08:43:45 -04:00
|
|
|
public function getAppId(): string;
|
2017-01-24 01:47:14 -05:00
|
|
|
}
|