Class SimpleSongTableModel

    • Constructor Detail

      • SimpleSongTableModel

        public SimpleSongTableModel​(BeaTunes application,
                                    List<AudioSong> songs)
        Parameters:
        application - application
        songs - list of songs
      • SimpleSongTableModel

        public SimpleSongTableModel​(BeaTunes application)
        Parameters:
        application - application
      • SimpleSongTableModel

        public SimpleSongTableModel​(List<AudioSong> songs)
        Parameters:
        songs - list of songs
    • Method Detail

      • setSongs

        public void setSongs​(Collection<AudioSong> songs)
        Sets a collection of songs as the table model content.
        Parameters:
        songs - collection of songs
      • getRowCount

        public int getRowCount()
      • getValueAt

        public AudioSong getValueAt​(int rowIndex)
        Parameters:
        rowIndex - index
        Returns:
        the value at the indicated row or null
      • indexOf

        public int indexOf​(AudioSong object)
        Description copied from interface: FilterTableModel
        First index for object.
        Parameters:
        object - object to look for
        Returns:
        index of the object or -1 if not found
      • indexOf

        public int indexOf​(long id)
        Description copied from interface: FilterTableModel
        First index for object with given id.
        Parameters:
        id - object id
        Returns:
        index of the corresponding object or -1 if not found