Enum tox::core::Event [-]  [+] [src]

pub enum Event {
    FriendRequest(Box<ClientId>, String),
    FriendMessage(i32, String),
    FriendAction(i32, String),
    NameChange(i32, String),
    StatusMessage(i32, String),
    UserStatusVar(i32, UserStatus),
    TypingChange(i32, bool),
    ReadReceipt(i32, u32),
    ConnectionStatusVar(i32, ConnectionStatus),
    GroupInvite(i32, GroupchatType, Vec<u8>),
    GroupMessage(i32, i32, String),
    GroupNamelistChange(i32, i32, ChatChange),
    FileSendRequest(i32, u8, u64, Vec<u8>),
    FileControl(i32, TransferType, u8, ControlType, Vec<u8>),
    FileData(i32, u8, Vec<u8>),
    AvatarInfo(i32, AvatarFormat, Hash),
    AvatarData(i32, AvatarFormat, Hash, Vec<u8>),
}

Tox events enum

Variants

FriendRequest

The first value is the client id, the second is the friend request message

FriendMessage

(fnum, msg) where fnum is the friend number and msg is the received message

FriendAction

(fnum, msg) where fnum is the friend number and msg is the action message

NameChange

(fnum, name) where fnum is the friend number and name is the new friend name

StatusMessage

(fnum, status) where fnum is the friend number and status is the status message

UserStatusVar

(fnum, usrst) where fnum is the friend number and usrst is the friend status

TypingChange

(fnum, is_typing). true value of is_typing means that friend is typing. fnum is the friend number

ReadReceipt
ConnectionStatusVar

(fnum, ConnectionStatus). fnum is the friend number

GroupInvite

(fnum, ty, data) where data is special data what needs to be passed to Tox::join_group method, fnum is the friend number, and ty is the type of the group.

GroupMessage

(gnum, pnum, msg) where gnum is the group number, pnum is the peer number and msg is the message

GroupNamelistChange

(gnum, pnum, ChatChange)

FileSendRequest

(fnum, fid, fisize, finame)

FileControl

(fnum, TranserType, fid, ControlType, data)

FileData

(fnum, fid, data)

AvatarInfo

(fnum, AvatarFormat, Hash)

AvatarData

(fnum, AvatarFormat, Hash, data)

Trait Implementations

Derived Implementations

impl Clone for Event

fn clone(&self) -> Event

fn clone_from(&mut self, source: &Self)