type property

String get type
override

The type of content.

You can use this in a switch to handle the various types (see the static expectedType getters), or you can use isText, isImage, isAudio and isEmbeddedResource to determine the type and then do the cast.

Implementation

String get type {
  final type = _value['type'] as String;
  assert(type == expectedType);
  return type;
}