Make `Hydrabadger::state` public.

This commit is contained in:
c0gent 2018-10-17 11:09:12 -07:00
parent 8fe128f4b5
commit d1f615bd90
No known key found for this signature in database
GPG Key ID: 9CC25E71A743E892
3 changed files with 3 additions and 3 deletions

View File

@ -181,7 +181,7 @@ impl<T: Contribution> Hydrabadger<T> {
}
/// Returns a reference to the inner state.
pub(crate) fn state(&self) -> RwLockReadGuard<State<T>> {
pub fn state(&self) -> RwLockReadGuard<State<T>> {
self.inner.state.read()
}

View File

@ -21,7 +21,7 @@ pub const WIRE_MESSAGE_RETRY_MAX: usize = 10;
/// A HoneyBadger input or message.
#[derive(Clone, Debug)]
pub(crate) enum InputOrMessage<T> {
pub enum InputOrMessage<T> {
Input(Input<T>),
Message(Uid, Message),
}

View File

@ -67,7 +67,7 @@ impl From<usize> for StateDsct {
// TODO: Make this into a struct and move the `state_dsct: AtomicUsize` field
// into it.
//
pub(crate) enum State<T: Contribution> {
pub enum State<T: Contribution> {
Disconnected {},
DeterminingNetworkState {
ack_queue: Option<SegQueue<(Uid, Ack)>>,