1027c6af4SGreg Roach<?php 2027c6af4SGreg Roach/** 3027c6af4SGreg Roach * webtrees: online genealogy 4*8fcd0d32SGreg Roach * Copyright (C) 2019 webtrees development team 5027c6af4SGreg Roach * This program is free software: you can redistribute it and/or modify 6027c6af4SGreg Roach * it under the terms of the GNU General Public License as published by 7027c6af4SGreg Roach * the Free Software Foundation, either version 3 of the License, or 8027c6af4SGreg Roach * (at your option) any later version. 9027c6af4SGreg Roach * This program is distributed in the hope that it will be useful, 10027c6af4SGreg Roach * but WITHOUT ANY WARRANTY; without even the implied warranty of 11027c6af4SGreg Roach * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12027c6af4SGreg Roach * GNU General Public License for more details. 13027c6af4SGreg Roach * You should have received a copy of the GNU General Public License 14027c6af4SGreg Roach * along with this program. If not, see <http://www.gnu.org/licenses/>. 15027c6af4SGreg Roach */ 16027c6af4SGreg Roachdeclare(strict_types=1); 17027c6af4SGreg Roach 18027c6af4SGreg Roachnamespace Fisharebest\Webtrees\Module; 19027c6af4SGreg Roach 20027c6af4SGreg Roach/** 21027c6af4SGreg Roach * Interface ModuleInterface - Classes and libraries for module system 22027c6af4SGreg Roach */ 23027c6af4SGreg Roachinterface ModuleInterface 24027c6af4SGreg Roach{ 25027c6af4SGreg Roach /** 26027c6af4SGreg Roach * Create a new module. 27027c6af4SGreg Roach * 28027c6af4SGreg Roach * @param string $directory Where is this module installed 29027c6af4SGreg Roach */ 30027c6af4SGreg Roach public function __construct(string $directory); 31027c6af4SGreg Roach 32027c6af4SGreg Roach /** 33027c6af4SGreg Roach * How should this module be labelled on tabs, menus, etc.? 34027c6af4SGreg Roach * 35027c6af4SGreg Roach * @return string 36027c6af4SGreg Roach */ 37027c6af4SGreg Roach public function getTitle(): string; 38027c6af4SGreg Roach 39027c6af4SGreg Roach /** 40027c6af4SGreg Roach * A sentence describing what this module does. 41027c6af4SGreg Roach * 42027c6af4SGreg Roach * @return string 43027c6af4SGreg Roach */ 44027c6af4SGreg Roach public function getDescription(): string; 45027c6af4SGreg Roach 46027c6af4SGreg Roach /** 47027c6af4SGreg Roach * What is the default access level for this module? 48027c6af4SGreg Roach * 49027c6af4SGreg Roach * Some modules are aimed at admins or managers, and are not generally shown to users. 50027c6af4SGreg Roach * 51027c6af4SGreg Roach * @return int Returns one of: Auth::PRIV_HIDE, Auth::PRIV_PRIVATE, Auth::PRIV_USER, Auth::PRIV_NONE 52027c6af4SGreg Roach */ 53027c6af4SGreg Roach public function defaultAccessLevel(): int; 54027c6af4SGreg Roach 55027c6af4SGreg Roach /** 56027c6af4SGreg Roach * Provide a unique internal name for this module 57027c6af4SGreg Roach * 58027c6af4SGreg Roach * @return string 59027c6af4SGreg Roach */ 60027c6af4SGreg Roach public function getName(): string; 61027c6af4SGreg Roach} 62