[][src]Enum cdrs::frame::frame_response::ResponseBody

pub enum ResponseBody {
    Error(CDRSError),
    Startup,
    Ready(BodyResResultVoid),
    Authenticate(BodyResAuthenticate),
    Options,
    Supported(BodyResSupported),
    Query,
    Result(ResResultBody),
    Prepare,
    Execute,
    Register,
    Event(BodyResEvent),
    Batch,
    AuthChallenge(BodyResAuthChallenge),
    AuthResponse,
    AuthSuccess(BodyReqAuthSuccess),
}

Variants

Error(CDRSError)
Startup
Authenticate(BodyResAuthenticate)
Options
Supported(BodyResSupported)
Query
Prepare
Execute
Register
Batch
AuthChallenge(BodyResAuthChallenge)
AuthResponse
AuthSuccess(BodyReqAuthSuccess)

Methods

impl ResponseBody[src]

pub fn from(bytes: &[u8], response_type: &Opcode) -> Result<ResponseBody>[src]

pub fn into_rows(self) -> Option<Vec<Row>>[src]

pub fn as_rows_metadata(&self) -> Option<RowsMetadata>[src]

pub fn as_cols(&self) -> Option<&BodyResResultRows>[src]

pub fn into_prepared(self) -> Option<BodyResResultPrepared>[src]

It unwraps body and returns BodyResResultPrepared which contains an exact result of PREPARE query. If frame body is not of type Result this method returns None.

pub fn into_set_keyspace(self) -> Option<BodyResResultSetKeyspace>[src]

It unwraps body and returns BodyResResultPrepared which contains an exact result of use keyspace query. If frame body is not of type Result this method returns None.

pub fn into_server_event(self) -> Option<BodyResEvent>[src]

It unwraps body and returns BodyResEvent. If frame body is not of type Result this method returns None.

pub fn get_authenticator<'a>(&'a self) -> Option<&'a str>[src]

Trait Implementations

impl Debug for ResponseBody[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.