Ubuntu TV Media Scanner
A centralized index for removable media content.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Static Public Attributes | List of all members
mediascanner::Property::MetadataKey Class Reference

#include <mediascanner/property.h>

Public Types

typedef std::function
< GParamSpec *()> 
SpecFunction
 Functions of this kind are used to register custom metadata keys. More...
 

Public Member Functions

 MetadataKey (GrlKeyID id)
 
 MetadataKey (const SpecFunction &make_spec)
 
GrlKeyID id () const
 
bool is_custom () const
 
std::string name () const
 
std::string description () const
 A human-readable description of this property. This is used only to generate documentation. More...
 
GType gtype () const
 The type of the data stored in this property, such as G_TYPE_STRING, G_TYPE_UINT, etc. This is used only to generate documentation. More...
 
bool RegisterCustomKey ()
 
const GListrelation () const
 

Static Public Attributes

static const GrlKeyID kPending
 Grilo metadata key for properties with pending custom metadata keys. More...
 
static const GrlKeyID kInvalid
 Invalid Grilo metadata key. More...
 

Member Typedef Documentation

Functions of this kind are used to register custom metadata keys.

Constructor & Destructor Documentation

mediascanner::Property::MetadataKey::MetadataKey ( GrlKeyID  id)
inline
mediascanner::Property::MetadataKey::MetadataKey ( const SpecFunction make_spec)
inlineexplicit

Member Function Documentation

std::string mediascanner::Property::MetadataKey::description ( ) const

A human-readable description of this property. This is used only to generate documentation.

GType mediascanner::Property::MetadataKey::gtype ( ) const

The type of the data stored in this property, such as G_TYPE_STRING, G_TYPE_UINT, etc. This is used only to generate documentation.

GrlKeyID mediascanner::Property::MetadataKey::id ( ) const
inline
bool mediascanner::Property::MetadataKey::is_custom ( ) const
inline
std::string mediascanner::Property::MetadataKey::name ( ) const
bool mediascanner::Property::MetadataKey::RegisterCustomKey ( )
const GList* mediascanner::Property::MetadataKey::relation ( ) const

Member Data Documentation

const GrlKeyID mediascanner::Property::MetadataKey::kInvalid
static

Invalid Grilo metadata key.

const GrlKeyID mediascanner::Property::MetadataKey::kPending
static

Grilo metadata key for properties with pending custom metadata keys.

Custom metadata keys need lazy initialization since they rely on the GObject type system which must be initialized with g_type_init(), or any other function such as grl_init() that implicitly calls this function.