-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Binding to TagLib C library.
--
-- TagLib is a library for reading and editing the meta-data of several
-- popular audio formats. Currently it supports both ID3v1 and ID3v2 for
-- MP3 files, Ogg Vorbis comments and ID3 tags and Vorbis comments in
-- FLAC, MPC, Speex, WavPack and TrueAudio files.
@package libtagc
@version 0.11.1
module Audio.TagLib.TagLib
type TagFile = ForeignPtr Void
type Tag = TagPtr
type AudioProperties = AudioPropertiesPtr
-- | Creates a TagFile file based on filename, TagLib will
-- try to guess the file type. Return Nothing if the file type
-- cannot be determined or the file cannot opened.
tagFileOpen :: ByteString -> IO (Maybe TagFile)
-- | Save file to disk.
tagFileSave :: TagFile -> IO Bool
-- | Returns True if the file is open and readble and valid
-- information for the Tag and AudioProperties was found.
tagFileIsValid :: TagFile -> IO Bool
-- | Returns Tag associated with this file.
tagFileGetTag :: TagFile -> IO (Maybe Tag)
-- | Returns AudioProperties associated with this file.
tagFileGetAudioProperties :: TagFile -> IO (Maybe AudioProperties)
-- | Returns a string with this tag's album.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetAlbum :: Tag -> IO String
-- | Set tag's album.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetAlbum :: Tag -> String -> IO ()
-- | Returns a string with this tag's artist.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetArtist :: Tag -> IO String
-- | Set tag's artist.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetArtist :: Tag -> String -> IO ()
-- | Returns a string with this tag's comment.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetComment :: Tag -> IO String
-- | Set tag's comment.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetComment :: Tag -> String -> IO ()
-- | Returns a string with this tag's genre.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetGenre :: Tag -> IO String
-- | Set tag's genre.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetGenre :: Tag -> String -> IO ()
-- | Returns a string with this tag's title.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetTitle :: Tag -> IO String
-- | Set tag's title.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetTitle :: Tag -> String -> IO ()
-- | Returns a string with this tag's track.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetTrack :: Tag -> IO Int
-- | Set tag's track.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetTrack :: Tag -> Int -> IO ()
-- | Returns a string with this tag's year.
--
-- NOTE: by default this string should be UTF8 encoded.
tagGetYear :: Tag -> IO Int
-- | Set tag's year.
--
-- NOTE: by default this string should be UTF8 encoded.
tagSetYear :: Tag -> Int -> IO ()
-- | Returns the bitrate of the file in kb/s.
audioPropertiesGetBitRate :: AudioProperties -> IO Int
-- | Returns the duration of the file in seconds.
audioPropertiesGetDuration :: AudioProperties -> IO Int
-- | Returns the sample rate of the file in Hz.
audioPropertiesGetSampleRate :: AudioProperties -> IO Int
-- | Returns the number of channels in the audio stream.
audioPropertiesGetChannels :: AudioProperties -> IO Int