[][src]Enum juno::protocol::BaseProtocol

pub enum BaseProtocol {
    JsonProtocol {
        module_id: String,
    },
    MsgPackProtocol {
        module_id: String,
    },
}

Variants

JsonProtocol

Fields of JsonProtocol

module_id: String
MsgPackProtocol

Fields of MsgPackProtocol

module_id: String

Methods

impl BaseProtocol[src]

pub fn default() -> Self[src]

pub fn from(other: &Self) -> Self[src]

pub fn generate_request_id(&self) -> String[src]

pub fn get_module_id(&self) -> &String[src]

pub fn set_module_id(&mut self, new_module_id: String)[src]

pub fn initialize(
    &mut self,
    module_id: String,
    version: String,
    dependencies: HashMap<String, String>
) -> BaseMessage
[src]

pub fn register_hook(&self, hook: String) -> BaseMessage[src]

pub fn trigger_hook(&self, hook: String) -> BaseMessage[src]

pub fn declare_function(&self, function: String) -> BaseMessage[src]

pub fn call_function(
    &self,
    function: String,
    arguments: HashMap<String, Value>
) -> BaseMessage
[src]

pub fn encode(&self, req: BaseMessage) -> Buffer[src]

pub fn decode(&self, data: &[u8]) -> BaseMessage[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.