summaryrefslogtreecommitdiffstats
path: root/toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
commit26a029d407be480d791972afb5975cf62c9360a6 (patch)
treef435a8308119effd964b339f76abb83a57c29483 /toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl
parentInitial commit. (diff)
downloadfirefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz
firefox-26a029d407be480d791972afb5975cf62c9360a6.zip
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl')
-rw-r--r--toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl12
1 files changed, 12 insertions, 0 deletions
diff --git a/toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl b/toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl
new file mode 100644
index 0000000000..a6d44ef598
--- /dev/null
+++ b/toolkit/components/uniffi-fixture-callbacks/src/callbacks.udl
@@ -0,0 +1,12 @@
+callback interface Logger {
+ void log(string message);
+ void finished();
+ };
+
+namespace fixture_callbacks {
+ // Log all even numbers in a vec, then call the finished() method
+ void log_even_numbers(Logger logger, sequence<i32> items);
+ // Works exactly the same as `log_even_numbers()`, except we configure this
+ // to run on the main thread in `uniffi-bindgen-gecko-js/config.toml`
+ void log_even_numbers_main_thread(Logger logger, sequence<i32> items);
+};