Skip to main content

Crate sword_core

Crate sword_core 

Source

Modules§

layers

Macros§

inventory_submit

Structs§

ByteConfig
Byte size configuration with raw string representation
ComponentRegistry
Config
Application configuration loaded from TOML files.
ConfigRegistrar
A struct that holds a function to register a config type. Used by the inventory system to collect all config types at compile time.
DependencyContainer
A container for managing dependencies and their builders.
ProviderRegistry
State
Application state container for type-safe dependency injection and data sharing.
TimeConfig
Time duration configuration with raw string representation

Enums§

ConfigError
DependencyInjectionError

Traits§

Build
Base trait for any component that can be constructed from the application State.
Component
Trait for injectable components that can be automatically constructed by the dependency container with automatic dependency resolution.
ConfigItem
Trait for configuration section types.
FromState
FromStateArc
HasDeps
Trait for components that have dependencies on other components.
Provider
Marker trait for pre-instantiated dependencies (providers).

Type Aliases§

Injectable
Pointer to dyn Any element. It retrieves dynamic capabilites to the dependency container. Basically represents Any element.

Attribute Macros§

config
Defines a configuration struct for the application. This macro generates the necessary code to deserialize the struct from the configuration toml file.
injectable
Marks a struct as injectable.