at_commands/
lib.rs

1// Copyright 2020 The Fuchsia Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5/// Export all the lowlevel types in one module to simplify generated code.
6mod lowlevel {
7    mod arguments;
8    mod command;
9    mod response;
10
11    pub mod write_to;
12
13    pub use arguments::{Argument, Arguments, DelimitedArguments};
14    pub use command::Command;
15    pub use response::{HardcodedError, Response};
16}
17
18mod generated {
19    pub mod translate;
20    pub mod types;
21}
22
23// Reexport all the highlevel types in one module to simplify generated code.
24mod highlevel {
25    pub use crate::generated::types::{Command, Success};
26    pub use crate::response::{HardcodedError, Response};
27}
28
29mod translate {
30    pub use crate::generated::translate::{lower_command, raise_command};
31    pub use crate::translate_response::{lower_response, raise_response};
32}
33
34mod parser {
35    mod arguments_parser;
36    pub mod command_grammar;
37    pub mod command_parser;
38    pub mod common;
39    pub mod response_grammar;
40    pub mod response_parser;
41}
42
43mod response;
44mod serde;
45mod translate_response;
46mod translate_util;
47
48// Reexport generated high level types and functions for use by clients.
49pub use generated::translate::*;
50pub use generated::types::*;
51pub use response::*;
52pub use serde::*;