setAttribute method

void setAttribute(
  1. String key,
  2. dynamic value
)
inherited

Set a given attribute on the model.

Values are stored as-is; casting to Dart types happens lazily in getAttribute and serialization to DB format happens in toDatabaseMap.

Implementation

void setAttribute(String key, dynamic value) {
  _attributes[key] = value;
  _computedCache.clear();
}