|
libscratchcpp
A library for C++ based Scratch project players
|
The Field class represents a Scratch block field. More...
#include <scratchcpp/field.h>
Public Member Functions | |
| Field (const std::string &name, const Value &value, std::shared_ptr< Entity > valuePtr=nullptr) | |
| Field (const std::string &name, const Value &value, const std::string &valueId) | |
| Field (const std::string &name, const Value &value, const char *valueId) | |
| Field (const Field &)=delete | |
| const std::string & | name () const |
| const Value & | value () const |
| std::shared_ptr< Entity > | valuePtr () const |
| void | setValuePtr (const std::shared_ptr< Entity > &newValuePtr) |
| const std::string & | valueId () const |
The Field class represents a Scratch block field.
| Field::Field | ( | const std::string & | name, |
| const Value & | value, | ||
| std::shared_ptr< Entity > | valuePtr = nullptr ) |
Constructs Field.
| Field::Field | ( | const std::string & | name, |
| const Value & | value, | ||
| const std::string & | valueId ) |
Constructs Field.
| Field::Field | ( | const std::string & | name, |
| const Value & | value, | ||
| const char * | valueId ) |
Constructs Field.
|
delete |
| const std::string & Field::name | ( | ) | const |
Returns the name of the field.
| void Field::setValuePtr | ( | const std::shared_ptr< Entity > & | newValuePtr | ) |
Sets the value pointer.
| const Value & Field::value | ( | ) | const |
Returns the value of the field.
| const std::string & Field::valueId | ( | ) | const |
Returns the ID of the value (e. g. a variable).
| std::shared_ptr< Entity > Field::valuePtr | ( | ) | const |
Returns a pointer to the value (e. g. a variable).