hasImmutable property

  1. @override
bool get hasImmutable
inherited

Whether the element has an annotation of the form @immutable.

Implementation

@override
bool get hasImmutable {
  var metadata = this.metadata;
  for (var i = 0; i < metadata.length; i++) {
    var annotation = metadata[i];
    if (annotation.isImmutable) {
      return true;
    }
  }
  return false;
}