Senzing C++ SDK
C++ SDK for Senzing v4, patterned after the official C# SDK
Loading...
Searching...
No Matches
SzEnvironment.hpp
Go to the documentation of this file.
1// SzEnvironment.hpp -- abstract interface mirroring C# Senzing.Sdk.SzEnvironment.
2//
3// The environment is the factory and lifecycle owner for the subsystem
4// instances (Product, Engine, ConfigManager, Diagnostic). Each Get* accessor
5// lazily creates and caches a single env-owned instance and returns a non-owning
6// reference; the returned references are invalid after Destroy().
7#ifndef SENZING_SDK_SZENVIRONMENT_HPP
8#define SENZING_SDK_SZENVIRONMENT_HPP
9
10#include <cstdint>
11
17
18namespace senzing::sdk {
19
22public:
23 virtual ~SzEnvironment() = default;
24
27 virtual SzProduct& GetProduct() = 0;
28
30 virtual SzEngine& GetEngine() = 0;
31
34
37
39 virtual int64_t GetActiveConfigID() = 0;
40
42 virtual void Reinitialize(int64_t configID) = 0;
43
45 virtual void Destroy() = 0;
46
48 virtual bool IsDestroyed() = 0;
49
65 virtual SzLogging& GetLogging() = 0;
66};
67
68} // namespace senzing::sdk
69
70#endif // SENZING_SDK_SZENVIRONMENT_HPP
Manages persisted Senzing configurations and the default config registry.
Definition SzConfigManager.hpp:18
Diagnostic operations against the Senzing repository.
Definition SzDiagnostic.hpp:11
The core Senzing entity-resolution engine.
Definition SzEngine.hpp:28
Factory + lifecycle for the Senzing SDK subsystems.
Definition SzEnvironment.hpp:21
virtual SzDiagnostic & GetDiagnostic()=0
Returns the env-owned SzDiagnostic (lazily created).
virtual SzEngine & GetEngine()=0
Returns the env-owned SzEngine (lazily created).
virtual void Reinitialize(int64_t configID)=0
Reinitializes the engine/diagnostic with the given configuration ID.
virtual int64_t GetActiveConfigID()=0
Returns the currently active configuration ID.
virtual SzLogging & GetLogging()=0
Returns the logging interface: native libSzLogging callbacks, levels, formats and the default output.
virtual ~SzEnvironment()=default
virtual bool IsDestroyed()=0
Returns true once Destroy() has been initiated/completed.
virtual void Destroy()=0
Destroys the environment and all owned subsystems. Idempotent.
virtual SzConfigManager & GetConfigManager()=0
Returns the env-owned SzConfigManager (lazily created).
virtual SzProduct & GetProduct()=0
Returns the env-owned SzProduct (lazily created).
Senzing native logging (libSzLogging).
Definition SzLogging.hpp:657
Provides access to the Senzing product version and license metadata.
Definition SzProduct.hpp:10
Definition SzCoreConfig.hpp:20