mysql_handler/handler.rs
1// Copyright (C) 2026 ren-yamanashi
2//
3// This program is free software; you can redistribute it and/or modify
4// it under the terms of the GNU General Public License, version 2.0,
5// as published by the Free Software Foundation.
6//
7// This program is designed to work with certain software (including
8// but not limited to OpenSSL) that is licensed under separate terms,
9// as designated in a particular file or component or in included license
10// documentation. The authors of this program hereby grant you an additional
11// permission to link the program and your derivative works with the
12// separately licensed software that they have either included with
13// the program or referenced in the documentation.
14//
15// This program is distributed in the hope that it will be useful,
16// but WITHOUT ANY WARRANTY; without even the implied warranty of
17// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18// GNU General Public License for more details.
19//
20// You should have received a copy of the GNU General Public License
21// along with this program; if not, see <https://www.gnu.org/licenses/>.
22
23//! `rust__handler__*` callbacks invoked by the C++ shim, split by handler-API
24//! category. Each submodule holds the callbacks for one section of
25//! `docs/api/handler.md`.
26//!
27//! # Safety (every callback in these submodules)
28//!
29//! - `ctx` comes from `rust__create_engine` and has not been destroyed; the
30//! C++ shim guards every callback against null on its side, so each Rust
31//! callback requires non-null.
32//! - The shim never calls a callback for the same `ctx` from two threads
33//! concurrently, so `&mut *ctx` is sound inside each callback.
34//! - Pointer/length pairs are valid for the call only; engines must not
35//! retain them.
36
37#[doc(hidden)]
38pub mod bulk_load;
39#[doc(hidden)]
40pub mod bulk_operations;
41#[doc(hidden)]
42pub mod caps;
43#[doc(hidden)]
44pub mod caps_features;
45#[doc(hidden)]
46pub mod cost;
47#[doc(hidden)]
48pub mod cost_time;
49#[doc(hidden)]
50pub mod error_handling;
51#[doc(hidden)]
52pub mod fulltext;
53#[doc(hidden)]
54pub mod hints;
55#[doc(hidden)]
56pub mod index_admin;
57#[doc(hidden)]
58pub mod index_basic;
59#[doc(hidden)]
60pub mod index_pushed;
61#[doc(hidden)]
62pub mod index_range;
63#[doc(hidden)]
64pub mod inplace_alter;
65#[doc(hidden)]
66pub mod limits;
67#[doc(hidden)]
68pub mod locking;
69#[doc(hidden)]
70pub mod maintenance;
71#[doc(hidden)]
72pub mod metadata;
73#[doc(hidden)]
74pub mod misc;
75#[doc(hidden)]
76pub mod mrr;
77#[doc(hidden)]
78pub mod open_close;
79#[doc(hidden)]
80pub mod parallel_scan;
81#[doc(hidden)]
82pub mod properties;
83#[doc(hidden)]
84pub mod pushdown;
85#[doc(hidden)]
86pub mod read_removal_autoinc;
87#[doc(hidden)]
88pub mod records;
89#[doc(hidden)]
90pub mod row_operations;
91#[doc(hidden)]
92pub mod sampling;
93#[doc(hidden)]
94pub mod scan;
95#[doc(hidden)]
96pub mod statistics;
97#[doc(hidden)]
98pub mod table_lifecycle;
99
100// Internal helper shared by the capability callbacks; not a callback module
101mod report;