Ubuntu TV Media Scanner
A centralized index for removable media content.
|
Public components of the Ubuntu TV Media Scanner. More...
Namespaces | |
dbus | |
schema | |
Property definitions of the Ubuntu TV Media Scanner. | |
Classes | |
class | CommitPolicy |
A commit policy decides when changes to the media index are written back to the disk. More... | |
class | InstantCommitPolicy |
A CommitPolicy which askes for instant commit of any change. More... | |
class | DelayedCommitPolicy |
A CommitPolicy which delays commits slightly, trying to batch them. More... | |
class | MediaIndexFacade |
class | Wrapper |
A shared smart-pointer for GLib related types. More... | |
class | FileSystemScanner |
class | FileSystemWalker |
class | Filter |
class | QueryStringFilter |
class | SubStringFilter |
class | FullTextFilter |
class | PrefixFilter |
class | ValueFilter |
class | RangeFilter |
class | BooleanFilter |
struct | ListWrapper |
class | Source |
The Source class provides access to the GLib event source mechanism. More... | |
class | Idle |
The Idle class provides access to GLib's idle source mechanism. More... | |
class | Timeout |
The Timeout class provides access to GLib's timeout mechanism. More... | |
class | MediaArtCache |
class | MediaArtDownloader |
class | MediaIndex |
A read-only instance of the media index. More... | |
class | MediaRoot |
class | MediaRootManager |
class | MimeType |
class | MediaInfo |
class | MetadataResolver |
class | Property |
Definition of a property value. More... | |
class | GenericProperty |
This class adds some utilities for property implementations. More... | |
class | DateTimeProperty |
class | NumericProperty |
class | GenericStringProperty |
class | RefreshPolicy |
A refresh policy decides when changes to the media index must be re-read. More... | |
class | InstantRefreshPolicy |
class | Settings |
class | TaskManager |
The TaskManager schedules tasks for running them in a background thread. More... | |
struct | flag_operations |
struct | flag_operations< void > |
class | WritableMediaIndex |
A writable instance of the media index. More... | |
Typedefs | |
typedef std::shared_ptr < CommitPolicy > | CommitPolicyPtr |
typedef std::shared_ptr < MediaArtDownloader > | MediaArtDownloaderPtr |
typedef std::shared_ptr < MediaRootManager > | MediaRootManagerPtr |
typedef std::shared_ptr < MetadataResolver > | MetadataResolverPtr |
typedef std::shared_ptr < TaskManager > | TaskManagerPtr |
typedef boost::filesystem::path | FileSystemPath |
typedef boost::rational< uint32_t > | Fraction |
The relational data type we support. More... | |
typedef boost::posix_time::ptime | DateTime |
The date-time type we support. More... | |
typedef std::wstring | String |
The string type we support. More... | |
typedef GenericStringProperty < DisableFullTextSearch > | StringProperty |
typedef GenericStringProperty < EnableFullTextSearch > | TextProperty |
typedef std::shared_ptr < RefreshPolicy > | RefreshPolicyPtr |
Shared pointer holding a RefreshPolicy. More... | |
Enumerations | |
enum | FullTextSearchMode { DisableFullTextSearch, EnableFullTextSearch } |
Functions | |
template<typename T > | |
T * | shallow_copy (const T *p) |
A type-safe function for creating shallow copies of structures. More... | |
template<typename T , size_t N> | |
static T * | array_copy (const T(&p)[N]) |
A type-safe function for creating shallow copies of pointer arrays. More... | |
template<typename T > | |
Wrapper< T > | wrap (T *p) |
Wraps a pointer to an object by a shared smart-pointer. More... | |
template<typename T > | |
Wrapper< T > | take (T *p) |
Wraps a pointer to an object by a shared smart-pointer. More... | |
template<typename T > | |
Wrapper< T > | wrap_static (const T *p) |
Wraps a statically allocated structure by a shared smart-pointer. More... | |
template<typename T > | |
void | DestroyNotify (gpointer user_data) |
Type-safe destroy notifier. More... | |
template<typename T > | |
void | ClosureNotify (gpointer user_data, GClosure *) |
std::string | to_string (const GError *error) |
Describes a GError . More... | |
std::string | to_string (const GstCaps *caps) |
Describes GStreamer capabilities. More... | |
template<typename BoxedType > | |
GParamSpec * | MakeParamSpecBoxed (const char *name, const char *nick, const char *blurb, GParamFlags flags) |
Creates a GParamSpec for boxed types. More... | |
bool | CheckLocaleFacets (const std::locale &loc=std::locale()) |
std::locale | SetupLocale (const std::string &id=std::string()) |
std::locale | SetupLocale (const std::locale &base, const std::string &id) |
std::wstring | ToUnicode (const std::string &str, const std::locale &loc=std::locale()) |
std::string | FromUnicode (const std::wstring &str, const std::locale &loc=std::locale()) |
template<typename T > | |
T | operator| (T a, T b) |
template<typename T > | |
T | operator& (T a, T b) |
template<typename T > | |
T | operator~ (T a) |
void | abort_with_backtrace () |
abort_with_backtrace Prints a backtrace and aborts then. More... | |
std::string | safe_string (const char *str) |
Safely constructs a std::string from potential null pointers. More... | |
std::string | take_string (char *str) |
Safely constructs a std::string from potential null pointers and then frees the pointer. More... | |
std::wstring | safe_wstring (const char *str) |
Safely constructs a std::wstring from potential null pointers. More... | |
template<typename KeyType , typename ValueType > | |
std::map< KeyType, ValueType > & | operator<< (std::map< KeyType, ValueType > &target, const typename std::map< KeyType, ValueType >::value_type &element) |
Conveniently fills the std::map target with elements. More... | |
template<typename T > | |
std::vector< T > & | operator<< (std::vector< T > &target, const T &element) |
Conveniently fills the std::vector target with elements. More... | |
template<typename T > | |
std::vector< T > | operator<< (const std::vector< T > &source, const T &element) |
Conveniently creates a copy of the std::vector source , and then pushes element to its end. More... | |
std::ostream & | operator<< (std::ostream &os, const class Property &p) |
Prints a property to a regular I/O stream. More... | |
Public components of the Ubuntu TV Media Scanner.
typedef boost::posix_time::ptime mediascanner::DateTime |
The date-time type we support.
typedef boost::filesystem::path mediascanner::FileSystemPath |
typedef boost::rational<uint32_t> mediascanner::Fraction |
The relational data type we support.
Fractions are used for instance to preciscely describe a photo's exposure time.
Shared pointer holding a RefreshPolicy.
typedef std::wstring mediascanner::String |
The string type we support.
We use std::wstring instead of std::string to match Lucene++.
void mediascanner::abort_with_backtrace | ( | ) |
abort_with_backtrace Prints a backtrace and aborts then.
Useful for std::set_terminate().
|
static |
A type-safe function for creating shallow copies of pointer arrays.
T | The array's element type. |
N | The number of elements in the array. |
p | A pointer to the array to copy. |
g_memdup()
. bool mediascanner::CheckLocaleFacets | ( | const std::locale & | loc = std::locale() ) |
|
inline |
|
inline |
Type-safe destroy notifier.
This function can be used as destroy notifier for GLib functions. It automatically invokes the proper delete
operator of T
.
T | The type of the object to destroy. |
user_data | A pointer to the object to destroy. |
|
inline |
|
inline |
Creates a GParamSpec
for boxed types.
This function is useful in static variable initialization to defer G_TYPE_*
calls that could lead to warnings about the missing g_type_init()
invocation.
BoxedType | G_TYPE_BOXED derived type of this property. |
name | Canonical name of the property specified. |
nick | Nick name for the property specified. |
blurb | Description of the property specified. |
flags | Flags for the property specified. |
|
inline |
|
inline |
Conveniently fills the std::map target
with elements.
target | The map to fill. |
element | The element to fill in. |
map
|
inline |
Conveniently fills the std::vector target
with elements.
vector | The vector to fill. |
element | The element to fill in. |
vec
|
inline |
Conveniently creates a copy of the std::vector source
, and then pushes element
to its end.
source | The vector to fill. |
element | The element to fill in. |
std::ostream& mediascanner::operator<< | ( | std::ostream & | os, |
const class Property & | p | ||
) |
Prints a property to a regular I/O stream.
This is useful in the context of boost::locale::format and logging.
os | The target stream |
s | The property to print |
os
logging
|
inline |
|
inline |
|
inline |
Safely constructs a std::string from potential null pointers.
str | A nul terminated string, or null . |
std::wstring mediascanner::safe_wstring | ( | const char * | str) |
Safely constructs a std::wstring from potential null pointers.
str | A nul terminated string, or null . |
std::locale mediascanner::SetupLocale | ( | const std::string & | id = std::string() ) |
std::locale mediascanner::SetupLocale | ( | const std::locale & | base, |
const std::string & | id | ||
) |
|
inline |
A type-safe function for creating shallow copies of structures.
T | The structure's type. |
p | A pointer to the structure to copy. |
g_memdup()
.
|
inline |
Wraps a pointer to an object by a shared smart-pointer.
This function takes ownership of the object. It therefore doesn't increase the object's reference count.
T | The type of the object to wrap. |
p | The pointer to the object to wrap. |
|
inline |
Safely constructs a std::string from potential null pointers and then frees the pointer.
str | A nul terminated string, or null . |
std::string mediascanner::to_string | ( | const GError * | error) |
Describes a GError
.
The returned string contains the error domain, the error code, and of course the error message.
error | The error to describe, or null |
std::string mediascanner::to_string | ( | const GstCaps * | caps) |
Describes GStreamer capabilities.
caps | The capabilities to describe, or null |
|
inline |
|
inline |
Wraps a pointer to an object by a shared smart-pointer.
This function doesn't take ownership of the object. It therefore does increase the object's reference count.
T | The type of the object to wrap. |
p | The pointer to the object to wrap. |
|
inline |
Wraps a statically allocated structure by a shared smart-pointer.
This function creates a shallow copy of the structure and then takes ownership of that copy.
T | The type of the structure to wrap. |
p | The pointer to the structure to wrap. |