rhailib/examples
2025-06-04 04:47:55 +03:00
..
Cargo.toml add rhailib package 2025-06-04 04:47:55 +03:00
example_math_worker.rs add rhailib package 2025-06-04 04:47:55 +03:00
example_string_worker.rs add rhailib package 2025-06-04 04:47:55 +03:00
README.md add rhailib package 2025-06-04 04:47:55 +03:00

Rhailib Examples

This directory contains end-to-end examples demonstrating the usage of the rhailib project, showcasing how the client, engine, and worker crates interact.

Available Examples

  • example_math_worker.rs: This example demonstrates a worker that performs mathematical operations. It shows how to define Rhai scripts that call Rust functions exposed by the worker, process the results, and interact with the rhailib engine and client.
  • example_string_worker.rs: This example showcases a worker focused on string manipulations. Similar to the math worker, it illustrates the setup for defining Rhai scripts, registering Rust functions for string operations, and the overall flow of execution within the rhailib ecosystem.

These examples serve as a practical guide to understanding the core functionalities and integration patterns within the rhailib project.