usesTimestamps property

bool get usesTimestamps
inherited

Whether this model uses timestamps after applying ignore scopes.

Implementation

bool get usesTimestamps {
  if (!timestamps) return false;
  if (Model.isIgnoringTimestamps(
    runtimeType,
    modelName: _isTracked ? _asAttributes.modelDefinition?.modelName : null,
  )) {
    return false;
  }
  if (_isTracked) {
    final definition = _asAttributes.modelDefinition;
    if (definition != null && !definition.metadata.timestamps) {
      return false;
    }
  }
  return true;
}