ocarina/core/tags/artist.cpp

33 lines
516 B
C++
Raw Normal View History

/**
* Copyright 2014 (c) Anna Schumaker.
*/
#include <core/tags/artist.h>
static database<struct artist> artist_db;
artist :: artist() : GenericTag() {}
artist :: artist(const std::string &name)
: GenericTag(name)
{
}
void tags :: init_artist_db()
{
db_init(&artist_db, "artist.db", true);
db_load(&artist_db);
}
struct artist *artist_find(const std::string &name)
{
return db_find(&artist_db, name.c_str());
}
struct artist *artist_get(const unsigned int index)
{
return db_at(&artist_db, index);
}