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

The report message is sent from an agent to the server to indicate the value of a question on a survey about the session they are playing. More...

#include <tt/io/Report.h>

Inheritance diagram for tt::Report:
Collaboration diagram for tt::Report:

Public Member Functions

 Report (const std::string &item, const std::string &value, const std::string &comment)
 Constructs a new report message.
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

std::string item
 The name or ID of the survey question.
std::string value
 The answer the agent gives to the survey question.
std::string comment
 A comment provided by the agent explaining their answer, or empty if the question does not allow comments or the agent does not provide one.

Detailed Description

The report message is sent from an agent to the server to indicate the value of a question on a survey about the session they are playing.

Author
Gage Birchmeier

Constructor & Destructor Documentation

◆ Report()

tt::Report::Report ( const std::string & item,
const std::string & value,
const std::string & comment )

Constructs a new report message.

Parameters
itemthe name or ID of the survey question
valuethe answer the agent gives to the question
commenta comment explaining the answer, or empty

Member Function Documentation

◆ toString()

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

Returns a string representation of this object.

Returns
a string describing this object

Reimplemented from tt::Message.

◆ type()

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

Type used for JSON deserialization.

Implements tt::Message.


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