secop_core/lib.rs
1// -----------------------------------------------------------------------------
2// Rust SECoP playground
3//
4// This program is free software; you can redistribute it and/or modify it under
5// the terms of the GNU General Public License as published by the Free Software
6// Foundation; either version 2 of the License, or (at your option) any later
7// version.
8//
9// This program is distributed in the hope that it will be useful, but WITHOUT
10// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
12// details.
13//
14// You should have received a copy of the GNU General Public License along with
15// this program; if not, write to the Free Software Foundation, Inc.,
16// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17//
18// Module authors:
19// Georg Brandl <g.brandl@fz-juelich.de>
20//
21// -----------------------------------------------------------------------------
22//
23//! The main entry point and crate definitions.
24
25pub mod types;
26pub mod proto;
27pub mod server;
28pub mod client;
29pub mod config;
30pub mod module;
31pub mod errors;
32
33// Hack to allow the derives to derive stuff in this crate.
34// Does not need to be public for that.
35mod secop_core {
36 pub use crate::errors;
37 pub use crate::types;
38}
39
40/// Re-exports mostly everything needed for writing modules.
41pub mod prelude {
42 pub use crate::errors::{Error, ErrorKind, Result};
43 pub use crate::module::{ModInternals, ModuleBase, Module};
44 pub use crate::config::{ServerConfig, ModuleConfig};
45 pub use crate::client::Client;
46 pub use crate::types::{TypeDesc, Null, Bool, Double, DoubleFrom,
47 DoubleRange, Int, Blob, Str, ArrayOf,
48 Tuple2, Tuple3, Tuple4, Tuple5, Tuple6,
49 Enum, StatusConst, StatusType, Status};
50}