1
0
mirror of https://github.com/actix/actix-extras.git synced 2025-02-17 16:43:30 +01:00
actix-extras/src/lib.rs

132 lines
2.8 KiB
Rust
Raw Normal View History

2017-12-06 11:00:39 -08:00
//! Actix web is a small, fast, down-to-earth, open source rust web framework.
2017-10-06 21:48:14 -07:00
2017-11-24 10:28:43 -08:00
#![cfg_attr(actix_nightly, feature(
specialization, // for impl ErrorResponse for std::error::Error
))]
2017-10-06 21:48:14 -07:00
#[macro_use]
extern crate log;
extern crate time;
extern crate bytes;
2017-10-07 21:48:00 -07:00
extern crate sha1;
2017-10-16 19:21:24 -07:00
extern crate regex;
2017-10-06 21:48:14 -07:00
#[macro_use]
extern crate futures;
extern crate tokio_io;
2017-10-29 06:05:31 -07:00
extern crate tokio_core;
2017-10-08 14:56:51 -07:00
2017-11-15 20:06:28 -10:00
extern crate failure;
#[macro_use] extern crate failure_derive;
extern crate cookie;
2017-10-06 21:48:14 -07:00
extern crate http;
extern crate httparse;
extern crate http_range;
2017-10-18 23:43:50 -07:00
extern crate mime;
2017-10-16 01:19:23 -07:00
extern crate mime_guess;
extern crate url;
2017-11-10 13:26:12 -08:00
extern crate libc;
2017-11-15 20:06:28 -10:00
extern crate serde;
extern crate serde_json;
2017-11-06 01:24:49 -08:00
extern crate flate2;
extern crate brotli2;
extern crate percent_encoding;
extern crate smallvec;
2017-10-06 21:48:14 -07:00
extern crate actix;
extern crate h2 as http2;
2017-10-06 21:48:14 -07:00
2017-12-03 18:51:52 -08:00
#[cfg(test)]
#[macro_use] extern crate serde_derive;
2017-11-15 20:06:28 -10:00
#[cfg(feature="tls")]
extern crate native_tls;
#[cfg(feature="tls")]
extern crate tokio_tls;
#[cfg(feature="openssl")]
extern crate openssl;
#[cfg(feature="openssl")]
extern crate tokio_openssl;
2017-10-06 21:48:14 -07:00
mod application;
2017-10-23 23:25:32 -07:00
mod body;
2017-10-06 21:48:14 -07:00
mod context;
mod date;
2017-11-06 16:23:58 -08:00
mod encoding;
mod httprequest;
2017-10-15 09:33:17 -07:00
mod httpresponse;
2017-10-08 20:16:48 -07:00
mod payload;
2017-12-05 17:09:15 -08:00
mod info;
2017-12-04 16:09:22 -08:00
mod route;
2017-12-06 16:26:27 -08:00
mod router;
mod param;
2017-10-06 21:48:14 -07:00
mod resource;
// mod recognizer;
2017-12-04 14:53:40 -08:00
mod handler;
2017-11-24 22:15:52 -08:00
mod pipeline;
2017-10-06 21:48:14 -07:00
mod server;
mod channel;
2017-10-07 21:48:00 -07:00
mod wsframe;
mod wsproto;
2017-11-02 12:54:09 -07:00
mod h1;
mod h2;
mod h1writer;
2017-11-04 09:07:44 -07:00
mod h2writer;
2017-10-07 21:48:00 -07:00
pub mod fs;
2017-10-09 23:07:32 -07:00
pub mod ws;
2017-11-15 20:06:28 -10:00
pub mod error;
2017-10-06 21:48:14 -07:00
pub mod httpcodes;
2017-10-18 23:43:50 -07:00
pub mod multipart;
2017-11-09 22:08:54 -08:00
pub mod middlewares;
2017-12-04 13:32:05 -08:00
pub mod pred;
2017-11-28 19:49:17 -08:00
pub use error::{Error, Result};
2017-11-06 16:23:58 -08:00
pub use encoding::ContentEncoding;
2017-11-10 13:42:32 -08:00
pub use body::{Body, Binary};
2017-11-26 22:53:28 -08:00
pub use application::Application;
pub use httprequest::{HttpRequest, UrlEncoded};
2017-11-26 22:53:28 -08:00
pub use httpresponse::HttpResponse;
2017-11-15 20:06:28 -10:00
pub use payload::{Payload, PayloadItem};
2017-12-04 14:53:40 -08:00
pub use handler::{Reply, Json, FromRequest};
2017-12-04 16:09:22 -08:00
pub use route::Route;
pub use resource::Resource;
2017-10-06 21:48:14 -07:00
pub use server::HttpServer;
pub use context::HttpContext;
2017-10-14 10:40:58 -07:00
// re-exports
pub use http::{Method, StatusCode, Version};
2017-11-26 22:53:28 -08:00
pub use cookie::Cookie;
2017-12-06 07:49:01 -08:00
#[doc(hidden)]
#[cfg(feature="tls")]
pub use native_tls::Pkcs12;
2017-12-06 07:49:01 -08:00
#[doc(hidden)]
#[cfg(feature="openssl")]
pub use openssl::pkcs12::Pkcs12;
2017-12-06 17:06:40 -08:00
pub mod dev {
//! The `actix-web` prelude for library developers
//!
//! The purpose of this module is to alleviate imports of many common actix traits
//! by adding a glob import to the top of actix heavy modules:
//!
//! ```
//! # #![allow(unused_imports)]
//! use actix_web::dev::*;
//! ```
// dev specific
pub use info::ConnectionInfo;
pub use handler::Handler;
pub use router::{Router, Pattern};
2017-12-06 17:06:40 -08:00
pub use pipeline::Pipeline;
pub use channel::{HttpChannel, HttpHandler, IntoHttpHandler};
// pub use recognizer::RouteRecognizer;
pub use param::{FromParam, Params};
2017-12-06 17:06:40 -08:00
pub use cookie::CookieBuilder;
pub use http_range::HttpRange;
pub use httpresponse::HttpResponseBuilder;
}