net-cat 0.2.0

Minimal hand-rolled HTTP/1.1 client over std::net::TcpStream. Plain HTTP in v0; v0.2.0 adds an optional `tls` feature that wires rustls + webpki-roots Mozilla CA bundle so `https://` URLs work via the same `fetch` / `exchange` entry points. No external HTTP crate; framing and parsing are local. No `mut` beyond FFI carve-outs (`TcpStream::read_to_end`, rustls `Stream::new(&mut conn, &mut sock)`). Sixth sub-crate of a Servo-replacement webview runtime targeting Tauri.
//! Minimal hand-rolled HTTP/1.1 client.
//!
//! # Example
//!
//! ```
//! # fn main() -> Result<(), net_cat::Error> {
//! use net_cat::{Method, Request, Url};
//!
//! let url = Url::parse("http://example.com/")?;
//! let request = Request::new(Method::Get, url).with_header("Accept", "text/html");
//! // `fetch(&request)` would perform a real network call -- doctest is
//! // offline-safe, so it's elided.
//! assert_eq!(request.method().as_str(), "GET");
//! # Ok(())
//! # }
//! ```

#![cfg_attr(docsrs, feature(doc_auto_cfg))]
#![allow(clippy::similar_names)]

pub mod error;
pub mod fetch;
pub mod headers;
pub mod method;
pub mod request;
pub mod response;
#[cfg(feature = "tls")]
pub mod tls;
pub mod transport;
pub mod url;

pub use error::Error;
pub use fetch::fetch;
pub use headers::Headers;
pub use method::Method;
pub use request::Request;
pub use response::Response;
pub use url::Url;