91 string pipeID = isnil(arg)?
"Black Hole" : arg[1];
92 string streamID = 2>arg.size()?
"teststream" : arg[2];
95 normaliseID (streamID);
97 retrieveSimpleDefault (pipeID);
98 retrieveConstrainedDefault (pipeID, streamID);
99 failureCreatesNewDefault();
107 retrieveSimpleDefault (
string)
114 CHECK (pipe2 == pipe1);
116 CHECK (pipe2 == pipe1);
118 CHECK (pipe2 == pipe1);
120 CHECK (pipe2 == pipe1);
122 CHECK (pipe2 == pipe1);
127 retrieveConstrainedDefault (
string pID,
string sID)
131 "stream-ID \"%s\" not suitable for test, because " 132 "the default-pipe \"%s\" happens to have the same " 133 "stream-ID. We need it to be different",
134 sID.c_str(), pID.c_str()
137 string query_for_sID{
"stream("+sID+
")"};
140 CHECK (pipe2 != pipe1);
146 failureCreatesNewDefault()
150 string new_pID =
_Fmt{
"dummy_%s_%i"}
156 CHECK (!find (query_for_new));
158 CHECK ( find (query_for_new));
160 CHECK (pipe1 != pipe2);
180 CHECK (2 == pipe1.use_count());
181 hash = pipe1->getID();
188 CHECK ( aMang.
known (assetID));
190 CHECK (!aMang.
known (assetID));
193 CHECK (!find(query_for_pID));
195 CHECK ( find(query_for_pID));
Utilities to support working with predicate queries.
Steam-Layer Interface: Asset Lookup and Organisation.
A "processing pipe" represented as Asset.
Framework for classification of media streams.
Basic and generic representation of an internal query.
bool define(lib::P< TAR > const &, Query< TAR > const &=Query< TAR >())
register the given object as default, after ensuring it fulfils the query.
void normaliseID(string &id)
ensure standard format for a given id string.
void remove(IDA id)
remove the given asset from the internal DB.
Facade for the Asset subsystem.
static session::SessManager & current
access point to the current Session
Steam-Layer implementation namespace root.
A front-end for using printf-style formatting.
DefaultsAccess defaults
manages default configured objects
Namespace of Session and user visible high-level objects.
structural asset corresponding to the part of the model forming a processing pipe for generating medi...
static lib::Depend< AssetManager > instance
get at the system-wide asset manager instance.
void verifyRemoval()
verify the defaults manager holds only weak refs, so if an object goes out of scope, any defaults entries are purged silently
lib::P< STRU > newInstance(Symbol nameID="")
invoke the factory to create new Structural Asset.
static StructFactory retrieve
storage for the static StructFactory instance
Token or Atom with distinct identity.
Marker types to indicate a literal string and a Symbol.
Simple test class runner.
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...
Superinterface describing especially bookkeeping properties.
Steam-Layer Interface: Assets.
static PPipe query(string const &properties)
convenience shortcut for retrieving default configured pipes
Customised refcounting smart pointer template, built upon std::shared_ptr, but forwarding type relati...
key abstraction: structural asset Created automatically as a sideeffect of building the structure of ...
Primary Interface to the current Session.
Asset representation of structural elements within the model.
Generic interface to express a query for specifically typed result elements exposing some capabilitie...
thin wrapper around a size_t hash ID used as primary key for all Asset objects.