    @startuml
'https://plantuml.com/class-diagram
title SP4 - Class Diagram

package Question {
    abstract class Question {
        + Answers : String[]
    }

    class MultipleChoice {
    }

    'class CheckboxChoice {'
    '}'

    Question <|-- MultipleChoice
    'Question <|-- CheckboxChoice'
}

class Survey {
    + Questions : Question[]
}

Survey *--"1..*" Question


package IO {
    interface IO {
        + read()
        + save()
    }

    class IOFile {
    }

    class IODatabase {
        + uploadSurvey()
        + getSurvey()
    }

    IO <|.. IOFile
    IO <|.. IODatabase
}

package UI {
    class UI {
        + uistart : UIStart
        + uianswer : UIAnswer
        + uicreate : UICreate
    }

    interface UIStart {
        + UIShowStart()
    }

    interface UIAnswer {
        + UIShowAnswer()
    }

    interface UICreate {
        + UIShowCreate()
    }

    UI *-- UIStart
    UI *-- UIAnswer
    UI *-- UICreate
    package UICommandLine #CCFFCC {
        abstract class UICommandLine {
        }
        class UICommandLineStart {
        }
        class UICommandLineAnswer {
        }
        class UICommandLineCreate {
        }
        UICommandLineStart --|> UICommandLine
        UICommandLineAnswer --|> UICommandLine
        UICommandLineCreate --|> UICommandLine
    }
    package UIJavaFX #99DDFF {
        abstract class UIJavaFX {
        }
        class UIJavaFXStart {
        }
        class UIJavaFXAnswer {
        }
        class UIJavaFXCreate {
        }
        UIJavaFXStart --|> UIJavaFX
        UIJavaFXAnswer --|> UIJavaFX
        UIJavaFXCreate --|> UIJavaFX
    }
    UIStart <|..[#green,thickness=2] UICommandLineStart
    UIStart <|..[#blue,thickness=2] UIJavaFXStart
    UIAnswer <|..[#green,thickness=2] UICommandLineAnswer
    UIAnswer <|..[#blue,thickness=2] UIJavaFXAnswer
    UICreate <|..[#green,thickness=2] UICommandLineCreate
    UICreate <|..[#blue,thickness=2] UIJavaFXCreate
}

class Controller {
    + io : IO
    + ui : UI
    + survey : Survey
}

Controller -- Survey
Controller -- IO
Controller -- UI


@enduml