Ase::Value struct

Value type used to interface with various property types.

Public functions

auto as_array() const →  const ValueS&
Retrive a non-empty array if Value contains a non-empty array.
auto as_double() const →  double
Convert Value to double or return 0.
auto as_int() const →  int64
Convert Value to int64 or return 0.
auto as_string() const →  String
Convert Value to a string, not very useful for RECORD or ARRAY.
auto count() const →  size_t
Number of elements in a RECORD or ARRAY Value.
void filter(const std::function<bool(const ValueField&)>& pred)
Recursively purge/remove RECORD elements iff to pred (recordfield) == true.
auto has(const String& key) const →  bool
Check for a named field in a RECORD.
auto is_numeric(bool boolisnumeric = true) const →  bool
Checks if Value is a DOUBLE, INT64, or BOOL.
auto keys() const →  StringS
List the field names of a RECORD Value.
auto repr() const →  String
Convert Value to a string representation, useful for debugging.