camel_component_api/
lib.rs1pub mod bundle;
11pub mod component;
12pub mod component_context;
13pub mod consumer;
14pub mod endpoint;
15pub mod producer;
16pub mod registrar;
17
18pub use bundle::ComponentBundle;
19pub use component::Component;
20pub use component_context::{ComponentContext, NoOpComponentContext};
21pub use consumer::{
22 ConcurrencyModel, Consumer, ConsumerContext, ExchangeEnvelope, SecurityContext,
23};
24pub use endpoint::{Endpoint, PollingConsumer};
25pub use producer::ProducerContext;
26pub use registrar::ComponentRegistrar;
27
28pub use camel_api::{
30 AsyncHealthCheck, Body, BodyType, BoxProcessor, CamelError, CheckResult, Exchange,
31 HealthStatus, Message, RouteAction, RouteStatus, RuntimeCommand, RuntimeCommandBus,
32 RuntimeCommandResult, RuntimeHandle, RuntimeQuery, RuntimeQueryBus, RuntimeQueryResult,
33 StreamBody, StreamMetadata, Value,
34};
35
36pub use camel_endpoint::{UriComponents, UriConfig, parse_uri};
38pub mod uri {
41 pub fn parse_bool_param(s: &str) -> Result<bool, String> {
44 match s.to_lowercase().as_str() {
45 "true" | "1" | "yes" => Ok(true),
46 "false" | "0" | "no" => Ok(false),
47 _ => Err(format!("invalid boolean value: '{}'", s)),
48 }
49 }
50}