Class PlaylistViewGenerator

java.lang.Object
de.klassenserver7b.danceinterpreter.graphics.util.PlaylistViewGenerator

public class PlaylistViewGenerator extends Object
  • Field Details

    • CELLFORMAT

      private static final String CELLFORMAT
      See Also:
    • log

      private final org.slf4j.Logger log
    • staticSongs

      private com.google.gson.JsonArray staticSongs
    • staticLabels

      private com.google.gson.JsonArray staticLabels
    • playlistViewEnabled

      private boolean playlistViewEnabled
  • Constructor Details

    • PlaylistViewGenerator

      public PlaylistViewGenerator()
  • Method Details

    • loadJsonDefaults

      public void loadJsonDefaults() throws com.google.gson.JsonSyntaxException
      Throws:
      com.google.gson.JsonSyntaxException
    • save

      public boolean save()
    • load

      public boolean load()
    • sendFailedImport

      protected void sendFailedImport()
    • validateJsonObject

      protected boolean validateJsonObject(com.google.gson.JsonObject mainObj)
    • validateSongs

      protected boolean validateSongs(com.google.gson.JsonArray songsArr)
    • validateLabels

      protected boolean validateLabels(com.google.gson.JsonArray labelsArr)
    • loadPlaylistView

      public List<JLabel> loadPlaylistView()
    • loadSongs

      protected List<JLabel> loadSongs()
    • loadStaticSongs

      protected List<JLabel> loadStaticSongs()
    • loadStaticLabels

      protected List<JLabel> loadStaticLabels()
    • openSaveDialogue

      protected File openSaveDialogue() throws IOException
      Throws:
      IOException
    • openOpenDialogue

      protected File openOpenDialogue()
      Returns:
      Throws:
      IllegalStateException
    • addSong

      public void addSong(String title, String artist, String dance)
    • addLabel

      public void addLabel(String text, String format)
    • getStaticSong

      public SongData getStaticSong(int index)
    • getStaticLabel

      public SongData getStaticLabel(int index)
    • isPlaylistViewEnabled

      public boolean isPlaylistViewEnabled()
      Returns:
      the playlistViewEnabled
    • setPlaylistViewEnabled

      public void setPlaylistViewEnabled(boolean playlistViewEnabled)
      Parameters:
      playlistViewEnabled - the playlistViewEnabled to set