parseString static method

List<XmlEntity>? parseString(
  1. String string, {
  2. bool trimWhitespace = true,
  3. int start = 0,
  4. int? stop,
})
override

Returns all DTD Entities found in string.

string must not be null.

start and stop refer to the indexes of the identified DTD Entities. Only matches found between start and stop will be returned. start must not be null and must be >= 0. stop may be null, but must be >= start if provided.

Returns null if no valid DTD entities are found.

Implementation

static List<XmlEntity>? parseString(
  String string, {
  bool trimWhitespace = true,
  int start = 0,
  int? stop,
}) {
  assert(start >= 0);
  assert(stop == null || stop >= start);
  return StringParser.parse<XmlEntity>(
    input: string,
    delimiter: Delimiters.entity,
    getNode: _getEntity,
    trimWhitespace: trimWhitespace,
    start: start,
    stop: stop,
  );
}