mirror of
https://github.com/godotengine/godot.git
synced 2026-01-06 10:11:57 +03:00
Expose type validator from Dictionary and allow testing without error
- Now you can get the ContainerTypeValidate from a Dictionary (both for keys and for values). - ContainerTypeValidate exposes a validator function that does not show any error in case of failure. This allows testing values before trying to use them in Dictionary.
This commit is contained in:
@@ -40,6 +40,7 @@
|
||||
class Variant;
|
||||
|
||||
struct ContainerType;
|
||||
struct ContainerTypeValidate;
|
||||
struct DictionaryPrivate;
|
||||
struct StringLikeVariantComparator;
|
||||
struct VariantHasher;
|
||||
@@ -121,6 +122,8 @@ public:
|
||||
StringName get_typed_value_class_name() const;
|
||||
Variant get_typed_key_script() const;
|
||||
Variant get_typed_value_script() const;
|
||||
const ContainerTypeValidate &get_key_validator() const;
|
||||
const ContainerTypeValidate &get_value_validator() const;
|
||||
|
||||
void make_read_only();
|
||||
bool is_read_only() const;
|
||||
|
||||
Reference in New Issue
Block a user