/**
 * Metadata for audio. Not thread-safe.
 * @author yunya
 *
 */

package zero1hd.rhythmbullet.audio.metadata;

import com.badlogic.gdx.files.FileHandle;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.utils.Disposable;

public interface AudioMetadata extends Disposable {
	/**
	 * Load the album art data in to memory.
	 * Will not load if already loaded.
	 */
	public void loadAlbumCover();
	
	/**
	 * Unloads album art from memory.
	 * Requires OpenGL context.
	 */
	public void unloadAlbumCover();

	/**
	 * 
	 * @return the author for the song in the metadata.
	 */
	public String getAuthor();
	
	/**
	 * 
	 * @return the title of the song in the metadata, or if it doesn't exist, the filename without extension and _ is given.
	 */
	public String getTitle();
	
	/**
	 * 
	 * @return the length of the song with proper fomatting.
	 */
	public String getDuration();
	
	/**
	 * 
	 * @return the length of the song in seconds.
	 */
	public int getLength();
	
	/**
	 * Requires a OpenGL context.
	 * @return the texture. Needs to be loaded before hand or else will return null.
	 */
	public Texture getAlbumCover();
	
	/**
	 * 
	 * @return returns the genre of the song stored in metadata.
	 */
	public String getGenre();
	
	/**
	 * 
	 * @return the filehandle.
	 */
	public FileHandle getFileHandle();
	
	@Override
	public void dispose();
}
