AzeorthCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
CliCommandHolder Struct Reference

Storage class for commands issued for delayed execution. More...

#include "IWorld.h"

Public Types

using Print = void(*)(void *, std::string_view)
 
using CommandFinished = void(*)(void *, bool success)
 

Public Member Functions

 CliCommandHolder (void *callbackArg, char const *command, Print zprint, CommandFinished commandFinished)
 Construct a new CliCommandHolder object. More...
 
 ~CliCommandHolder ()
 Destroy the CliCommandHolder object. More...
 

Public Attributes

void * m_callbackArg
 
char * m_command
 
Print m_print
 
CommandFinished m_commandFinished
 

Private Member Functions

 CliCommandHolder (CliCommandHolder const &right)=delete
 
CliCommandHolderoperator= (CliCommandHolder const &right)=delete
 

Detailed Description

Storage class for commands issued for delayed execution.

Member Typedef Documentation

◆ CommandFinished

using CliCommandHolder::CommandFinished = void(*)(void*, bool success)

◆ Print

using CliCommandHolder::Print = void(*)(void*, std::string_view)

Constructor & Destructor Documentation

◆ CliCommandHolder() [1/2]

CliCommandHolder::CliCommandHolder ( void *  callbackArg,
char const *  command,
Print  zprint,
CommandFinished  commandFinished 
)

Construct a new CliCommandHolder object.

Parameters
callbackArg
command
zprint
commandFinished
3404 : m_callbackArg(callbackArg), m_command(strdup(command)), m_print(zprint), m_commandFinished(commandFinished)
3405{
3406}
void commandFinished(void *, bool)
Definition: CliRunnable.cpp:87
CommandFinished m_commandFinished
Definition: IWorld.h:46
void * m_callbackArg
Definition: IWorld.h:43
Print m_print
Definition: IWorld.h:45
char * m_command
Definition: IWorld.h:44

◆ ~CliCommandHolder()

CliCommandHolder::~CliCommandHolder ( )

Destroy the CliCommandHolder object.

3409{
3410 free(m_command);
3411}

References m_command.

◆ CliCommandHolder() [2/2]

CliCommandHolder::CliCommandHolder ( CliCommandHolder const &  right)
privatedelete

Member Function Documentation

◆ operator=()

CliCommandHolder & CliCommandHolder::operator= ( CliCommandHolder const &  right)
privatedelete

Member Data Documentation

◆ m_callbackArg

void* CliCommandHolder::m_callbackArg

◆ m_command

char* CliCommandHolder::m_command

◆ m_commandFinished

CommandFinished CliCommandHolder::m_commandFinished

◆ m_print

Print CliCommandHolder::m_print