123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203 |
- <?php
- declare(strict_types=1);
- namespace OCP\Accounts;
- use OCP\IUser;
- interface IAccountManager {
-
- public const SCOPE_PRIVATE = 'v2-private';
-
- public const SCOPE_LOCAL = 'v2-local';
-
- public const SCOPE_FEDERATED = 'v2-federated';
-
- public const SCOPE_PUBLISHED = 'v2-published';
-
- public const VISIBILITY_PRIVATE = 'private';
-
- public const VISIBILITY_CONTACTS_ONLY = 'contacts';
-
- public const VISIBILITY_PUBLIC = 'public';
-
- public const ALLOWED_SCOPES = [
- self::SCOPE_PRIVATE,
- self::SCOPE_LOCAL,
- self::SCOPE_FEDERATED,
- self::SCOPE_PUBLISHED,
- self::VISIBILITY_PRIVATE,
- self::VISIBILITY_CONTACTS_ONLY,
- self::VISIBILITY_PUBLIC,
- ];
- public const PROPERTY_AVATAR = 'avatar';
- public const PROPERTY_DISPLAYNAME = 'displayname';
- public const PROPERTY_DISPLAYNAME_LEGACY = 'display-name';
- public const PROPERTY_PHONE = 'phone';
- public const PROPERTY_EMAIL = 'email';
- public const PROPERTY_WEBSITE = 'website';
- public const PROPERTY_ADDRESS = 'address';
- public const PROPERTY_TWITTER = 'twitter';
- public const PROPERTY_FEDIVERSE = 'fediverse';
-
- public const PROPERTY_ORGANISATION = 'organisation';
-
- public const PROPERTY_ROLE = 'role';
-
- public const PROPERTY_HEADLINE = 'headline';
-
- public const PROPERTY_BIOGRAPHY = 'biography';
-
- public const PROPERTY_PROFILE_ENABLED = 'profile_enabled';
-
- public const ALLOWED_PROPERTIES = [
- self::PROPERTY_AVATAR,
- self::PROPERTY_DISPLAYNAME,
- self::PROPERTY_PHONE,
- self::PROPERTY_EMAIL,
- self::PROPERTY_WEBSITE,
- self::PROPERTY_ADDRESS,
- self::PROPERTY_TWITTER,
- self::PROPERTY_FEDIVERSE,
- self::PROPERTY_ORGANISATION,
- self::PROPERTY_ROLE,
- self::PROPERTY_HEADLINE,
- self::PROPERTY_BIOGRAPHY,
- self::PROPERTY_PROFILE_ENABLED,
- ];
- public const COLLECTION_EMAIL = 'additional_mail';
- public const NOT_VERIFIED = '0';
- public const VERIFICATION_IN_PROGRESS = '1';
- public const VERIFIED = '2';
-
- public function getAccount(IUser $user): IAccount;
-
- public function updateAccount(IAccount $account): void;
-
- public function searchUsers(string $property, array $values): array;
- }
|