package shakuhachi
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha256=7d07b9c7edcd5f5cee242facf4260272c56e56eb34b897888299ceece3e61d57
sha512=305f97d253d39f3b9d260e018d45f2563bea911cb164ad4d40c450e6c21081f1e7cde68203f9be6633b6933e1bad39da8405b99e8ace58adcc07758d37b8f2fd
doc/shakuhachi.libs/Skhclibs/Collection/index.html
Module Skhclibs.CollectionSource
Operations on a shakuhachi collection.
type of a collection
open' config opens the collection with configuration provided by config.
realpath collection path returns
pathifpathis absolute (eg. starts with / on unix).- music_directory +
pathifpathis relative.
val database :
?mode:[ `NO_CREATE | `READONLY ] ->
?uri:bool ->
?memory:bool ->
?mutex:[ `FULL | `NO ] ->
?cache:[ `PRIVATE | `SHARED ] ->
?vfs:string ->
t ->
SkhcDb.Database.tdatabase collection returns a database handler associated with collection.
see Sqlite3.db_open for details of all optional arguments.
val with_database :
?mode:[ `NO_CREATE | `READONLY ] ->
?uri:bool ->
?memory:bool ->
?mutex:[ `FULL | `NO ] ->
?cache:[ `PRIVATE | `SHARED ] ->
?vfs:string ->
t ->
(SkhcDb.Database.t -> 'a) ->
'awith_database collection f runs f with a database handler associated with collection. SkhcDb.Database.close is guaranteed to be called whether f completes normaly or raises an exception. with_database discards any results or exceptions of SkhcDb.Database.close.
see Sqlite3.db_open for details of all optional arguments.
config collection returns the configuration used when calling open'.
dir_artist collection metadata returns the directory name of where should be collected the artist's albums according to metadata. The path returned is relative to configuration's music_directory.
dir_artist_absolute collection metadata is dir_artist but returns the absolute path instead of the relative one.
dir_album collection metadata returns the directory name of where should be collected the album's songs according to metadata. The path returned is relative to configuration's music_directory. Since shakuhachi stores songs in a artist/album directory structure, this function calls dir_artist underneath.
dir_album_absolute collection metadata is dir_album but returns the absolute path instead of the relative one.