Iray SDK API nvidia_logo_transpbg.gif Up
idatabase.h
Go to the documentation of this file.
1/***************************************************************************************************
2 * Copyright 2025 NVIDIA Corporation. All rights reserved.
3 **************************************************************************************************/
6
7#ifndef MI_NEURAYLIB_IDATABASE_H
8#define MI_NEURAYLIB_IDATABASE_H
9
11#include <mi/neuraylib/version.h> // for MI_NEURAYLIB_DEPRECATED_ENUM_VALUE
12
13namespace mi {
14
15namespace neuraylib {
16
17class IScope;
18
209class IDatabase : public
210 mi::base::Interface_declare<0x814ae637,0xde35,0x4870,0x8e,0x5b,0x7e,0x28,0x9d,0x30,0xfb,0x82>
211{
212public:
217 virtual IScope* get_global_scope() const = 0;
218
236 virtual IScope* create_scope( IScope* parent, Uint8 privacy_level = 0, bool temp = false) = 0;
237
255 const char* name, IScope* parent = nullptr, Uint8 privacy_level = 0) = 0;
256
261 virtual IScope* get_scope( const char* id) const = 0;
262
267 virtual IScope* get_named_scope( const char* name) const = 0;
268
281 virtual Sint32 remove_scope( const char* id) const = 0;
282
285
290
295
299 PRIORITY_HIGH = 2
300 MI_NEURAYLIB_DEPRECATED_ENUM_VALUE(PRIORITY_FORCE_32_BIT, 0xffffffffU)
301 };
302
319
342 virtual void lock( Uint32 lock_id) = 0;
343
353 virtual Sint32 unlock( Uint32 lock_id) = 0;
354};
355 // end group mi_neuray_database_access
357
358} // namespace neuraylib
359
360} // namespace mi
361
362#endif // MI_NEURAYLIB_IDATABASE_H
Mixin class template for deriving new interface declarations.
Definition: interface_declare.h:43
This interface is used to interact with the distributed database.
Definition: idatabase.h:211
virtual IScope * get_scope(const char *id) const =0
Looks up a scope by ID.
virtual void lock(Uint32 lock_id)=0
Acquires a DB lock.
virtual void garbage_collection(Garbage_collection_priority priority=PRIORITY_MEDIUM)=0
Triggers a synchronous garbage collection run.
Garbage_collection_priority
Priorities for synchronous garbage collection runs.
Definition: idatabase.h:284
@ PRIORITY_MEDIUM
Medium priority for synchronous garbage collection runs.
Definition: idatabase.h:294
@ PRIORITY_HIGH
High priority for synchronous garbage collection runs.
Definition: idatabase.h:299
@ PRIORITY_LOW
Low priority for synchronous garbage collection runs.
Definition: idatabase.h:289
virtual IScope * create_scope(IScope *parent, Uint8 privacy_level=0, bool temp=false)=0
Creates a new unnamed scope.
virtual Sint32 remove_scope(const char *id) const =0
Removes a scope with the specified ID.
virtual IScope * create_or_get_named_scope(const char *name, IScope *parent=nullptr, Uint8 privacy_level=0)=0
Creates a new named scope (or retrieves an existing one).
virtual Sint32 unlock(Uint32 lock_id)=0
Releases a previously obtained DB lock.
virtual IScope * get_named_scope(const char *name) const =0
Looks up a scope by name.
virtual IScope * get_global_scope() const =0
Returns the global scope which is the root of a tree of scopes.
A scope is the context which determines the visibility of database elements.
Definition: iscope.h:44
unsigned char Uint8
8-bit unsigned integer.
Definition: types.h:47
int Sint32
32-bit signed integer.
Definition: types.h:46
unsigned int Uint32
32-bit unsigned integer.
Definition: types.h:49
Mixin class template for deriving new interface declarations.
Common namespace for APIs of NVIDIA Advanced Rendering Center GmbH.
Definition: neuraylib.h:179
Major and minor version number and an optional qualifier.