globjects
2.0.0.690708773bba
Strict OpenGL objects wrapper.
|
String source associated to a file. More...
#include <globjects/include/globjects/base/File.h>
Public Member Functions | |
File (const std::string &filePath, bool binary=true) | |
virtual | ~File () |
virtual std::string | string () const override |
virtual std::string | shortInfo () const override |
const std::string & | filePath () const |
void | reload () |
Public Member Functions inherited from globjects::AbstractStringSource | |
virtual std::vector< std::string > | strings () const |
std::vector< const AbstractStringSource * > | flatten () const |
virtual void | flattenInto (std::vector< const AbstractStringSource * > &vector) const |
Public Member Functions inherited from globjects::Changeable | |
Changeable () | |
virtual | ~Changeable () |
void | changed () const |
void | registerListener (ChangeListener *listener) |
void | deregisterListener (ChangeListener *listener) |
Protected Member Functions | |
void | loadFileContent () const |
Protected Attributes | |
std::string | m_filePath |
bool | m_binary |
std::string | m_source |
bool | m_valid |
Protected Attributes inherited from globjects::Changeable | |
std::set< ChangeListener * > | m_listeners |
Additional Inherited Members | |
Static Public Member Functions inherited from globjects::Instantiator< File > | |
static std::unique_ptr< File > | create (Args &&...args) |
static std::unique_ptr< File > | fromId (gl::GLuint id, Args &&...args) |
String source associated to a file.
The file path of a File can be queried using filePath(); To reload the contents from a file, use reload().
globjects::File::File | ( | const std::string & | filePath, |
bool | binary = true |
||
) |
|
virtual |
|
overridevirtual |
Implements globjects::AbstractStringSource.
|
overridevirtual |
Reimplemented from globjects::AbstractStringSource.
const std::string& globjects::File::filePath | ( | ) | const |
void globjects::File::reload | ( | ) |
|
protected |
|
protected |
|
protected |
|
mutableprotected |
|
mutableprotected |