XmlNotation constructor

const XmlNotation({
  1. required String name,
  2. bool isSystem = false,
  3. bool isPublic = false,
  4. String? publicId,
  5. String? uri,
})

A notation declaration, as known as an unparsed entity.

name must not be null or empty.

Either isSystem or isPublic must be true, but not both.

publicId must be null if isPublic is false.

uri must not be null if isSystem is true, but is optional if isPublic is true.

Implementation

const XmlNotation({
  required this.name,
  this.isSystem = false,
  this.isPublic = false,
  this.publicId,
  this.uri,
})  : assert(name.length > 0),
      assert((isSystem && !isPublic) || (!isSystem && isPublic)),
      assert(publicId == null || isPublic),
      assert(!isSystem || uri != null);