1f21dad39SAndreas Gohr<?php 2f21dad39SAndreas Gohr 3f21dad39SAndreas Gohrnamespace dokuwiki\Action; 4f21dad39SAndreas Gohr 5ab583a1bSAndreas Gohruse dokuwiki\Action\Exception\FatalException; 6f21dad39SAndreas Gohr 7ab583a1bSAndreas Gohr/** 8ab583a1bSAndreas Gohr * Class AbstractAliasAction 9ab583a1bSAndreas Gohr * 10ab583a1bSAndreas Gohr * An action that is an alias for another action. Skips the minimumPermission check 11ab583a1bSAndreas Gohr * 12ab583a1bSAndreas Gohr * Be sure to implement preProcess() and throw an ActionAbort exception 13ab583a1bSAndreas Gohr * with the proper action. 14ab583a1bSAndreas Gohr * 15ab583a1bSAndreas Gohr * @package dokuwiki\Action 16ab583a1bSAndreas Gohr */ 17f21dad39SAndreas Gohrabstract class AbstractAliasAction extends AbstractAction { 18f21dad39SAndreas Gohr 19f21dad39SAndreas Gohr /** @inheritdoc */ 20d5d08c05SAndreas Gohr public function minimumPermission() { 21f21dad39SAndreas Gohr return AUTH_NONE; 22f21dad39SAndreas Gohr } 23f21dad39SAndreas Gohr 24*79a2d784SGerrit Uitslag /** 25*79a2d784SGerrit Uitslag * @throws FatalException 26*79a2d784SGerrit Uitslag */ 27ab583a1bSAndreas Gohr public function preProcess() { 28ab583a1bSAndreas Gohr throw new FatalException('Alias Actions need to implement preProcess to load the aliased action'); 29ab583a1bSAndreas Gohr } 30ab583a1bSAndreas Gohr 31f21dad39SAndreas Gohr} 32