A reference over an object in the scripting environment. More...
Public Member Functions | |
ScriptObjectReference () noexcept | |
ScriptObjectReference (ScriptObjectInterpreterReference *reference) noexcept | |
ScriptObjectReference (const ScriptObjectView &other) noexcept | |
ScriptObjectReference (const ScriptObjectReference &other) noexcept | |
ScriptObjectReference (ScriptObjectReference &&other) noexcept | |
~ScriptObjectReference () | |
ScriptObjectInterpreterReference * | getInterpreterReference () const |
FUNCTION_PARAMETER_TYPE | getType () const |
ScriptObjectReference & | operator= (const ScriptObjectView &other) noexcept |
ScriptObjectReference & | operator= (const ScriptObjectReference &other) noexcept |
ScriptObjectReference & | operator= (ScriptObjectReference &&other) noexcept |
A reference over an object in the scripting environment.
This class touches the reference counting in the environment, and can prevent an object from being freed. To avoid leak, external code should ensure this reference is only used when needed.
In theory, this class should never be altered by external code. Rather, it will be used as parameters for functions using it.
|
noexcept |
Default constructor.
|
noexcept |
Constructor from an interpreter specific reference.
reference | The reference to keep. |
|
noexcept |
Constructor from a view over the data.
other | The view to construct the reference from. |
|
noexcept |
Copy constructor.
other | The reference to copy from. |
|
noexcept |
Move constructor.
other | The reference to take over. |
nkScripts::ScriptObjectReference::~ScriptObjectReference | ( | ) |
Destructor.
ScriptObjectInterpreterReference* nkScripts::ScriptObjectReference::getInterpreterReference | ( | ) | const |
FUNCTION_PARAMETER_TYPE nkScripts::ScriptObjectReference::getType | ( | ) | const |
|
noexcept |
View assignment operator.
other | The view to construct a reference from. |
|
noexcept |
Copy assignment operator.
other | The reference to copy from. |
|
noexcept |
Move assignment operator.
other | The reference to move. |