Class Controller

  • Direct Known Subclasses:
    DownloadController, TermsExtractorController

    public abstract class Controller
    extends Object
    The Controller class is the abstract class for all the controllers. It contains the name of the controller and the execute method.
    • Field Detail

      • name

        public final String name
        The name of the controller.
    • Constructor Detail

      • Controller

        Controller​(String name)
        Controller constructor.
        Parameters:
        name - the name of the controller
    • Method Detail

      • execute

        public abstract Either<Failure,​Success> execute​(Context context)
        The execute method is used to execute the controller.
        Parameters:
        context - the context of the controller
        Returns:
        Either a Failure or a Success