DartBridgePlatform class

Platform adapter bridge for fundamental C++ → Dart operations.

Provides: logging, file operations, secure storage, clock. Matches Swift's CppBridge+PlatformAdapter.swift exactly.

C++ code cannot directly:

  • Write to disk
  • Access secure storage (Keychain/KeyStore)
  • Get current time
  • Route logs to native logging system

This bridge provides those capabilities via C function callbacks.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

instance DartBridgePlatform
Singleton instance for bridge accessors
final
isRegistered bool
Check if the adapter is registered.
no setter
servicesRegistered bool
Whether platform services availability callback has been registered.
no setter

Static Methods

register() → void
Register platform adapter with C++. Must be called FIRST during SDK init (before any C++ operations).
registerServices() Future<void>
Register the platform services availability callback with C++. Matches Swift's CppBridge.Platform.register() callback wiring for Foundation Models / System TTS / System STT availability checks.
unregister() → void
Unregister platform adapter (called during shutdown).