go_bridge 1.4.3 go_bridge: ^1.4.3 copied to clipboard
Provides a bridge to call go libraries via FFI and protobuffer encoded messages
Use this package as a library
Depend on it
Run this command:
With Dart:
$ dart pub add go_bridge
With Flutter:
$ flutter pub add go_bridge
This will add a line like this to your package's pubspec.yaml (and run an implicit dart pub get
):
dependencies:
go_bridge: ^1.4.3
Alternatively, your editor might support dart pub get
or flutter pub get
. Check the docs for your editor to learn more.
Import it
Now in your Dart code, you can use:
import 'package:go_bridge/gen/common/basic_error_message.pb.dart';
import 'package:go_bridge/gen/common/basic_error_message.pbenum.dart';
import 'package:go_bridge/gen/common/basic_error_message.pbjson.dart';
import 'package:go_bridge/gen/common/basic_error_message.pbserver.dart';
import 'package:go_bridge/gen/common/primitive_messages.pb.dart';
import 'package:go_bridge/gen/common/primitive_messages.pbenum.dart';
import 'package:go_bridge/gen/common/primitive_messages.pbjson.dart';
import 'package:go_bridge/gen/common/primitive_messages.pbserver.dart';
import 'package:go_bridge/gen/common/response.pb.dart';
import 'package:go_bridge/gen/common/response.pbenum.dart';
import 'package:go_bridge/gen/common/response.pbjson.dart';
import 'package:go_bridge/gen/common/response.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/any.pb.dart';
import 'package:go_bridge/gen/google/protobuf/any.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/any.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/any.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/any_test.pb.dart';
import 'package:go_bridge/gen/google/protobuf/any_test.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/any_test.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/any_test.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/api.pb.dart';
import 'package:go_bridge/gen/google/protobuf/api.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/api.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/api.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/descriptor.pb.dart';
import 'package:go_bridge/gen/google/protobuf/descriptor.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/descriptor.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/descriptor.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/duration.pb.dart';
import 'package:go_bridge/gen/google/protobuf/duration.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/duration.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/duration.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/empty.pb.dart';
import 'package:go_bridge/gen/google/protobuf/empty.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/empty.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/empty.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/field_mask.pb.dart';
import 'package:go_bridge/gen/google/protobuf/field_mask.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/field_mask.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/field_mask.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/map_lite_unittest.pb.dart';
import 'package:go_bridge/gen/google/protobuf/map_lite_unittest.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/map_lite_unittest.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/map_lite_unittest.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/map_proto2_unittest.pb.dart';
import 'package:go_bridge/gen/google/protobuf/map_proto2_unittest.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/map_proto2_unittest.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/map_proto2_unittest.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/map_unittest.pb.dart';
import 'package:go_bridge/gen/google/protobuf/map_unittest.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/map_unittest.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/map_unittest.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/source_context.pb.dart';
import 'package:go_bridge/gen/google/protobuf/source_context.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/source_context.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/source_context.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/struct.pb.dart';
import 'package:go_bridge/gen/google/protobuf/struct.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/struct.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/struct.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto2.pb.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto2.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto2.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto2.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto3.pb.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto3.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto3.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/test_messages_proto3.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/timestamp.pb.dart';
import 'package:go_bridge/gen/google/protobuf/timestamp.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/timestamp.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/timestamp.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/type.pb.dart';
import 'package:go_bridge/gen/google/protobuf/type.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/type.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/type.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_arena.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_arena.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_arena.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_arena.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_custom_options.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_custom_options.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_custom_options.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_custom_options.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_drop_unknown_fields.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_drop_unknown_fields.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_drop_unknown_fields.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_drop_unknown_fields.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_embed_optimize_for.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_embed_optimize_for.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_embed_optimize_for.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_embed_optimize_for.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_empty.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_empty.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_empty.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_empty.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_enormous_descriptor.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_enormous_descriptor.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_enormous_descriptor.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_enormous_descriptor.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_lite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_lite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_lite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_lite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public_lite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public_lite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public_lite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_import_public_lite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_custom_option.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_custom_option.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_custom_option.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_custom_option.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_enum.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_enum.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_enum.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lazy_dependencies_enum.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite_imports_nonlite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite_imports_nonlite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite_imports_nonlite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_lite_imports_nonlite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset_wire_format.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset_wire_format.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset_wire_format.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_mset_wire_format.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_field_presence.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_field_presence.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_field_presence.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_field_presence.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_generic_services.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_generic_services.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_generic_services.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_no_generic_services.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_optimize_for.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_optimize_for.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_optimize_for.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_optimize_for.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum2.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum2.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum2.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_preserve_unknown_enum2.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena_lite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena_lite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena_lite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_arena_lite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_lite.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_lite.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_lite.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_lite.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_optional.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_optional.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_optional.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_proto3_optional.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_well_known_types.pb.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_well_known_types.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_well_known_types.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/unittest_well_known_types.pbserver.dart';
import 'package:go_bridge/gen/google/protobuf/wrappers.pb.dart';
import 'package:go_bridge/gen/google/protobuf/wrappers.pbenum.dart';
import 'package:go_bridge/gen/google/protobuf/wrappers.pbjson.dart';
import 'package:go_bridge/gen/google/protobuf/wrappers.pbserver.dart';
import 'package:go_bridge/helpers.dart';