Audacity 3.2.0
|
RAII for lv2 resources. More...
#include <memory>
#include <wx/string.h>
#include "lilv/lilv.h"
Go to the source code of this file.
Classes | |
struct | Lilv_deleter< Type, f > |
Generate deleter classes for smart pointers to lv2 resources. More... | |
Typedefs | |
template<typename Type , void(*)(Type *) f> | |
using | Lilv_ptr = std::unique_ptr< Type, Lilv_deleter< Type, f > > |
Generate classes of smart pointers to lv2 resources. More... | |
using | LilvCharsPtr = Lilv_ptr< char, free_chars > |
using | LilvNodePtr = Lilv_ptr< LilvNode, lilv_node_free > |
Functions | |
static void | free_chars (char *p) |
wxString | LilvString (const LilvNode *node) |
wxString | LilvStringMove (LilvNode *node) |
RAII for lv2 resources.
Audacity: A Digital Audio Editor
Paul Licameli split from LV2Symbols.h
Definition in file LV2Utils.h.
using Lilv_ptr = std::unique_ptr<Type, Lilv_deleter<Type, f> > |
Generate classes of smart pointers to lv2 resources.
Definition at line 26 of file LV2Utils.h.
using LilvCharsPtr = Lilv_ptr<char, free_chars> |
Definition at line 29 of file LV2Utils.h.
using LilvNodePtr = Lilv_ptr<LilvNode, lilv_node_free> |
A smart pointer to LilvNode, which is essentially a variant type much used in the lv2 API
Definition at line 33 of file LV2Utils.h.
|
inlinestatic |
Definition at line 28 of file LV2Utils.h.
|
inline |
Use when lilv.h comments "must not be freed" or we use the node elsewhere, or the node pointer is from iterating a LilvNodes collection
Definition at line 37 of file LV2Utils.h.
Referenced by LV2EffectsModule::FindModulePaths(), LV2EffectBase::GetFactoryPresets(), LV2EffectBase::GetPath(), LilvStringMove(), and LV2Ports::LV2Ports().
|
inline |
Use when lilv.h comments "Returned value must be freed by the caller." We free it in this function. Name suggests C++ move semantics applied to node
, but only C types used
Definition at line 45 of file LV2Utils.h.
References LilvString(), and str.
Referenced by LV2FeaturesList::GetPluginSymbol(), LV2EffectBase::GetVendor(), and LV2Ports::LV2Ports().