Expand description
GenApi node system: typed feature access backed by register IO.
What a node caches, and how its register is addressed, are the node map’s
business, not the API’s (ADR-0030): read a value through NodeMap, and
a register’s address with NodeMap::register_address.
ⓘ
// A formula's cached value and generation are private (backlog API-07).
fn peek(node: &viva_genapi::SkNode) -> bool {
node.cache.borrow().is_some()
}ⓘ
// So is a register's.
fn peek(node: &viva_genapi::RegisterNode) -> bool {
node.cache.borrow().is_some()
}ⓘ
// A node's addressing is `viva_genapi_xml::Addressing`, which keeps
// changing; it is not part of this crate's API (backlog API-02).
fn terms(node: &viva_genapi::IntegerNode) -> bool {
node.addressing.is_some()
}Re-exports§
pub use persistence::Configuration;pub use persistence::LoadReport;pub use persistence::PersistencePlan;pub use swissknife::AstNode;pub use swissknife::EvalMode;pub use swissknife::Value;pub use swissknife::VarAttr;
Modules§
- persistence
- Saving a camera’s configuration and restoring it: GenICam’s
<Streamable>features (ADR-0028). - swissknife
- GenApi formula parser and evaluator.
Structs§
- BitField
- Bitfield metadata describing a sub-range of a register payload.
- Boolean
Node - Boolean feature metadata.
- Category
Node - Category node describing child feature names.
- Chunk
Data - The chunks of one stream buffer, by chunk ID: what a nodemap’s chunk ports read.
- Command
Node - Command feature metadata.
- Converter
Node - Converter node transforming a raw register value to/from a float feature value via two formulas.
- Document
Identity - Which camera a document describes, and which revision of the document it
is: the
<RegisterDescription>attributes of GenICam Standard v2.1.1 §2.7. - Enum
Entry Decl - Declaration for a single enumeration entry.
- Enum
Node - Enumeration feature metadata and mapping tables.
- Feature
State - The live state of one feature, read from the device in a single call.
- Float
Node - Floating point feature metadata.
- Formula
Var - One variable a formula reads: the identifier it appears as, the node behind it, and which property of that node it denotes.
- Ignored
Element - A child element of a node that the parser read past without interpreting it: the node loaded, but whatever the element says was not taken into account.
- IntConverter
Node - IntConverter node transforming a raw register value to/from an integer feature value via two formulas.
- Integer
Node - Integer feature metadata extracted from the XML description.
- Manual
Clock - A clock that moves only when told to: for tests, and for a host without
a system clock, which advances it from its own (a browser’s
performance.now(), say). - NodeMap
- Runtime nodemap built from an
XmlModelcapable of reading and writing feature values via aRegisterIotransport. - Node
Meta - Shared metadata present on every GenICam node.
- NullIo
- No-op register I/O that returns zeroed data for reads and ignores writes.
- Predicate
Refs - References to predicate provider nodes used for runtime gating.
- Register
Node <Register>node: raw byte-array access to a register block.- SkNode
- SwissKnife node evaluating an arithmetic expression referencing other nodes.
- Skipped
Node - A node element that could not be parsed and was left out of the model.
- String
Node - A string feature: a
<StringReg>, which reads a register, or a<String>, which holds a value or reads and writes the node its<pValue>names (GenICam Standard v2.1.1 §2.8.11, §2.8.12). - System
Clock - The system’s monotonic clock,
std::time::Instant. - Value
Range - The current bounds of a numeric feature.
Enums§
- Access
Direction - Which way an access was refused.
- Access
Mode - Access privileges for a GenICam node as described in the XML.
- Byte
Order - Byte order used to interpret a multi-byte register payload.
- Caching
Mode <Cachable>: whether a register’s value may be answered from a cache.- Command
Value Src - Where a
<Command>takes the value it writes. - Enum
Value Src - Source of the numeric value backing an enumeration entry.
- Feature
Value - A feature’s current value, typed by the node that holds it.
- Float
Encoding - Byte-level encoding of the payload behind a
<Float>/<FloatReg>node. - GenApi
Error - Error type produced by GenApi operations.
- Node
- Node kinds supported by the Tier-1 subset.
- Port
Kind - What a
<Port>gives access to. - Range
Violation - How a value falls outside what a node accepts.
- Representation
- Recommended UI representation for a numeric feature.
- Sign
- Whether a register’s bits are interpreted as a signed or unsigned integer.
- SkOutput
- Output type of a SwissKnife expression node.
- Slope
- How a converter’s
<FormulaFrom>moves with its raw value. - Visibility
- Visibility level controlling which users see a feature.
Traits§
- Clock
- A monotonic time source.
- Register
Io - Register access abstraction backed by transports such as GVCP/GenCP.