Lumiera  0.pre.03
»edit your freedom«
Asset::Ident Struct Reference

#include "steam/asset.hpp"

Description

a POD comprised of all the information sufficiently identifying any given Asset.

Definition at line 149 of file asset.hpp.

Public Member Functions

 Ident (const string &n, const Category &cat, const string &o="lumi", const uint ver=1)
 
int compare (Ident const &other) const
 ordering of Assets is based on the ordering of Ident tuples, which are supposed to be unique. More...
 
bool isValid () const
 
 operator string () const
 
bool operator< (Ident const &oi) const
 
bool operator== (Ident const &oi) const
 

Public Attributes

asset::Category category
 primary tree like classification of the asset. More...
 
string name
 element ID, comprehensible but sanitised. More...
 
const string org
 origin or authorship id. More...
 
const uint version
 version number of the thing or concept represented by this asset. More...
 

Member Function Documentation

◆ compare()

int compare ( Asset::Ident const &  oi) const
inline

ordering of Assets is based on the ordering of Ident tuples, which are supposed to be unique.

By using our customised lumiera::P as smart ptr, comparison on P<Asset> ptrs will be automatically forwarded to the Asset comparison operators.

Note
version info is irrelevant

Definition at line 312 of file asset.hpp.

References Asset::Ident::category, Asset::Ident::name, stage::widget::name(), and Asset::Ident::org.

+ Here is the call graph for this function:

◆ operator==()

bool operator== ( Ident const &  oi) const
inline
Note
equality ignores version differences

Definition at line 187 of file asset.hpp.

Member Data Documentation

◆ name

string name

◆ category

asset::Category category

primary tree like classification of the asset.

Includes the distinction of different kinds of Assets, like Media, Audio, Video, Effects...

Definition at line 160 of file asset.hpp.

Referenced by Asset::Ident::compare(), steam::asset::anonymous_namespace{clip.cpp}::createClipIdent(), steam::asset::anonymous_namespace{preview.cpp}::createProxyIdent(), and Asset::~Asset().

◆ org

const string org

origin or authorship id.

Can be a project abbreviation, a package id or just the authors nickname or UID. This allows for the component name to be more generic (e.g. "blur"). Default for all assets provided by the core Lumiera codebase is "lumi".

Definition at line 167 of file asset.hpp.

Referenced by Asset::Ident::compare(), steam::asset::anonymous_namespace{clip.cpp}::createClipIdent(), steam::asset::anonymous_namespace{preview.cpp}::createProxyIdent(), and Asset::~Asset().

◆ version

const uint version

version number of the thing or concept represented by this asset.

Of each unique tuple (name, category, org) there will be only one version in the whole system. Version 0 is reserved for internal purposes. Versions are considered to be ordered, and any higher version is supposed to be fully backwards compatible to all previous versions.

Definition at line 175 of file asset.hpp.

Referenced by steam::asset::anonymous_namespace{clip.cpp}::createClipIdent(), steam::asset::anonymous_namespace{preview.cpp}::createProxyIdent(), and Asset::~Asset().

+ Inheritance diagram for Asset::Ident:
+ Collaboration diagram for Asset::Ident:

The documentation for this struct was generated from the following files: