TT Client Library 1.0.0
C++ library for Tandem Tales clients.
Loading...
Searching...
No Matches
tt::Start Class Reference

The start message is sent from the server to a client when a partner has been found and their session begins. More...

#include <tt/io/Start.h>

Inheritance diagram for tt::Start:
Collaboration diagram for tt::Start:

Public Member Functions

std::string toString () const override
 Returns a string representation of this object.
std::string type () const override
 Type used for JSON deserialization.
Public Member Functions inherited from tt::Message
 Message ()
 Constructs a message.
const Client * getClient () const
 Returns the tt::Client who sent this message, or null if this message was sent by the server.
void setClient (const Client *client)
 Sets the tt::Client who sent this message.

Public Attributes

Role role
 The role the recipient of this message will have in the session.
std::unique_ptr< World > world
 The story world in which the session will take place.

Detailed Description

The start message is sent from the server to a client when a partner has been found and their session begins.

Author
Gage Birchmeier

Member Function Documentation

◆ toString()

std::string tt::Start::toString ( ) const
overridevirtual

Returns a string representation of this object.

Returns
a string describing this object

Reimplemented from tt::Message.

◆ type()

std::string tt::Start::type ( ) const
inlineoverridevirtual

Type used for JSON deserialization.

Implements tt::Message.

Member Data Documentation

◆ world

std::unique_ptr<World> tt::Start::world

The story world in which the session will take place.

Note that this is an exposed unique_ptr. This is because the Client will take ownership of the World object after it is received. This pointer will be invalid after the Client moves its value.


The documentation for this class was generated from the following files: