// This file is automatically generated, so please do not edit it.
// @generated by `flutter_rust_bridge`@ 2.10.0.

// ignore_for_file: invalid_use_of_internal_member, unused_import, unnecessary_import

import '../frb_generated.dart';
import '../helpers/params.dart';
import '../helpers/result.dart';
import '../helpers/return_value.dart';
import '../helpers/value.dart';
import '../helpers/wrapper.dart';
import 'package:flutter_rust_bridge/flutter_rust_bridge_for_generated.dart';
import 'statement.dart';

// Rust type: RustOpaqueMoi<flutter_rust_bridge::for_generated::RustAutoOpaqueInner<RustConnection>>
abstract class RustConnection implements RustOpaqueInterface {
  Future<ExecuteResult> execute({required String sql, required Params params});

  // HINT: Make it `#[frb(sync)]` to let it become the default constructor of Dart class.
  static Future<RustConnection> newInstance({
    required WrapperArcConnection connection,
  }) => RustLib.instance.api.crateApiConnectionRustConnectionNew(
    connection: connection,
  );

  Future<RustStatement> prepare({required String sql});

  Future<QueryResult> query({required String sql, required Params params});
}
