. */ declare(strict_types=1); namespace FireflyIII\Import\Prerequisites; use FireflyIII\User; use Illuminate\Http\Request; use Illuminate\Support\MessageBag; /** * Interface PrerequisitesInterface */ interface PrerequisitesInterface { /** * Returns view name that allows user to fill in prerequisites. * * @return string */ public function getView(): string; /** * Returns any values required for the prerequisites-view. * * @return array */ public function getViewParameters(): array; /** * Returns if this import method has any special prerequisites such as config * variables or other things. * * @return bool */ public function hasPrerequisites(): bool; /** * Set the user for this Prerequisites-routine. Class is expected to implement and save this. * * @param User $user */ public function setUser(User $user): void; /** * @param Request $request * * @return MessageBag */ public function storePrerequisites(Request $request): MessageBag; }