Crossfire Server, Trunk
MessageLoader Class Reference

#include <MessageLoader.h>

+ Inheritance diagram for MessageLoader:
+ Collaboration diagram for MessageLoader:

Public Member Functions

virtual void load (BufferReader *reader, const std::string &filename) override
 
 MessageLoader (Messages *messages)
 
virtual bool willLoad (const std::string &filename) override
 
- Public Member Functions inherited from AssetLoader
virtual ~AssetLoader ()
 

Private Attributes

Messagesm_messages
 

Detailed Description

Definition at line 21 of file MessageLoader.h.

Constructor & Destructor Documentation

◆ MessageLoader()

MessageLoader::MessageLoader ( Messages messages)

Definition at line 22 of file MessageLoader.cpp.

Member Function Documentation

◆ load()

void MessageLoader::load ( BufferReader reader,
const std::string &  filename 
)
overridevirtual

Load assets from the specified reader. Must be implemented.

Parameters
readerreader.
filenamefull filename.

Implements AssetLoader.

Definition at line 25 of file MessageLoader.cpp.

References add_string(), BOOK_BUF, buf, buf_overflow(), bufferreader_current_line(), bufferreader_next_line(), AssetsCollection< T, Key >::define(), fatal(), npc_dialog::filename, find_face(), HUGE_BUF, llevDebug, llevError, llevInfo, LOG(), m_messages, msgbuf, SEE_LAST_ERROR, guild_entry::text, and Ice::tmp.

+ Here is the call graph for this function:

◆ willLoad()

virtual bool MessageLoader::willLoad ( const std::string &  filename)
inlineoverridevirtual

Whether this instance will process or not the specified file.

Parameters
filenamefull file path.
Returns
true if processFile() should be called, false else.

Implements AssetLoader.

Definition at line 25 of file MessageLoader.h.

References Utils::endsWith(), and npc_dialog::filename.

+ Here is the call graph for this function:

Field Documentation

◆ m_messages

Messages* MessageLoader::m_messages
private

Definition at line 32 of file MessageLoader.h.

Referenced by load().


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