NAP
Resource Class Reference

#include <nap/resource.h>

Public Member Functions

 Resource ()
 
- Public Member Functions inherited from Object
 Object ()
 
virtual ~Object ()
 
virtual bool init (utility::ErrorState &errorState)
 
virtual void onDestroy ()
 
 Object (Object &)=delete
 
Objectoperator= (const Object &)=delete
 
 Object (Object &&)=delete
 
Objectoperator= (Object &&)=delete
 

Additional Inherited Members

- Static Public Member Functions inherited from Object
static bool isIDProperty (rtti::Instance &object, const rtti::Property &property)
 
- Public Attributes inherited from Object
std::string mID
 Property: 'mID' unique name of the object. Used as an identifier by the system. More...
 

Detailed Description

A resource is a small, stand-alone building block that can be authored in JSON. Resources are used to load an image from disk, define a three-dimensional shape, create a render window, etc. Derive from this class to create your own resource and implement the init() call to initialize the object after de-serialization. Override the onDestroy() method to perform additional clean-up steps.

Inheritance diagram for Resource:
[legend]
Collaboration diagram for Resource:
[legend]

Constructor & Destructor Documentation

◆ Resource()

Resource ( )