$darkmode
cloe::utility::ResourceLoader Class Reference

#include <resource_handler.hpp>

Public Member Functions

 ResourceLoader (Resource r)
 
std::string to_string () const
 

Friends

void to_json (cloe::Json &j, const ResourceLoader &c)
 

Detailed Description

Makes the resource available as a string normally loading it from the static incbin resource or in debug mode reading it from disk at each access. The resource can made available as Json object.

Friends And Related Function Documentation

◆ to_json

void to_json ( cloe::Json &  j,
const ResourceLoader c 
)
friend

Serializes a loaded resource as Json object. In case the resource does not have Json content, its content is serialized as a key value pair {'filepath': 'content'}.


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