Invision Power Services, Inc. * @copyright (c) Invision Power Services, Inc. * @license https://www.invisioncommunity.com/legal/standards/ * @package Invision Community * @subpackage * @since 11/16/2023 */ namespace IPS\Extensions; /* To prevent PHP errors (extending class does not exist) revealing path */ use LogicException; if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) ) { header( ( $_SERVER['SERVER_PROTOCOL'] ?? 'HTTP/1.0' ) . ' 403 Forbidden' ); exit; } abstract class CommunityEnhancementsAbstract { /** * @brief Enhancement is enabled? */ public bool $enabled = FALSE; /** * @brief IPS-provided enhancement? */ public bool $ips = FALSE; /** * @brief Enhancement has configuration options? */ public bool $hasOptions = TRUE; /** * @brief Icon data */ public string $icon = ""; /** * Edit * * @return void */ abstract public function edit() : void; /** * Enable/Disable * * @param $enabled bool Enable/Disable * @return void * @throws LogicException */ abstract public function toggle( bool $enabled ) : void; }