Interface constructor
Interface(
- String name
Implementation
Interface(this.name) {
if (Platform.isIOS || Platform.isMacOS) {
_runtime = InterfaceRuntimeObjC();
} else if (Platform.isAndroid) {
_runtime = InterfaceRuntimeJava();
} else {
throw 'Platform not supported: ${Platform.localeName}';
}
_nativeObjectPointer = _runtime.nativeObjectPointerForInterfaceName(name);
if (_nativeObjectPointer == nullptr) {
throw 'Pointer of native object is nullptr!';
}
_methodTable = _runtime.methodTableWithInterfaceName(name);
}