API Reference
API Reference
Every public item in the crate, grouped by type.
Everything below is re-exported from the crate root, so use flextable::{Table, Value}; is all most code needs.
Types#
| Item | Kind | Description |
|---|---|---|
Table | struct | The table: a shared handle to an array part and a hash part. |
TableRef | struct | A read-only borrowed view of a table, from Table::borrow. |
Value | enum | A dynamic value: nil, boolean, integer, float, string or table. |
Key | enum | An owned, always-valid key. |
KeyRef | enum | A borrowed key used for lookups. |
Error | enum | Why a table operation failed. |
Result | type alias | std::result::Result<T, Error>. |
Traits#
| Item | Description |
|---|---|
AsKey | Anything usable as a key: integers, floats, booleans, strings, tables, Value, Key. |
Iterators#
| Item | Returned by | Yields |
|---|---|---|
Pairs | Table::pairs | (Key, Value) |
IPairs | Table::ipairs | (i64, Value) |
Iter | TableRef::iter | (KeyRef<'a>, &'a Value) |
Macros#
| Item | Description |
|---|---|
table! | Build a table from a list of values or key => value pairs. |
Modules#
The items are also reachable through their modules: flextable::table, flextable::value, flextable::key, flextable::iter and flextable::error. The crate root is the recommended path.
Conventions on these pages#
- Signatures are shown as declared.
K: AsKeymeans any key type;V: Into<Value>(orimpl Into<Value>) means any value type. - Complexity badges give the cost in terms of
n, the number of elements involved. - Methods that take
&selfand change the table do so through interior mutability; see Core Concepts.