Class DBData

java.lang.Object
com.ubs.backend.demo.DBData

public class DBData extends Object
Since:
17.07.2021
Author:
Marc, Magnus, Tim Irmler, Sarah
  • Constructor Details

    • DBData

      public DBData()
  • Method Details

    • getTypeTags

      public List<TypeTag> getTypeTags()
      Returns:
      all set type tags
      Since:
      05.08.2021
    • getTypeTagAnswers

      public List<Answer> getTypeTagAnswers()
      Returns:
      all set type tag answers, like jokes
    • getResults

      public List<Result> getResults()
      Returns:
      all set results with their corresponding tags and answers
      Since:
      17.07.202
    • getBlackList

      public ArrayList<BlacklistEntry> getBlackList()
      Returns:
      all words that should be blacklisted, read from a file (every line one word)
      Since:
      17.07.202
    • getUserLogins

      public List<UserLogin> getUserLogins()
      Returns:
      all set user logins
      Since:
      17.07.202
    • getDefaultQuestions

      public List<DefaultQuestion> getDefaultQuestions()
      Returns:
      all set default questions
      Since:
      17.07.202
    • readFileLines

      private ArrayList<String> readFileLines(String filepath) throws FileNotFoundException, IOException
      Parameters:
      filepath - the path to the file
      Returns:
      a list of words, every line in the file is one entry in the list
      Throws:
      FileNotFoundException - if the file cannot be found
      IOException - if something went wrong