Tag class

contains all information about an HTML tag, including:

  • tagname
  • if it is a start- or an end-tag
  • properties (if any)
  • style-properties (if any)
  • the raw length of the tag for offset calculation

Constructors

Tag(String name, String rawTag, Map<String, dynamic> properties, bool isStart, int size)
creates a new tag-representation. and decodes the "style" tag if present
Tag.decodeTag(String tag)
Decodes a random start- or end-tag encountered in HTML. tag is the full tag including brackets, properties, etc.
factory

Properties

endTagSize int
size of the corresponding end-tag. is equal to this.size if isStart is false
no setter
hashCode int
The hash code for this object.
no setterinherited
isStart bool
start, or end-tag
final
name String
tagname (without '<', '/' or '>')
final
properties Map<String, dynamic>
map of properties, mapping the html-key to it's value
final
rawTag String
complete tag includin properties and brackets
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
size int
the raw length of the tag in characters for offset calculation
final
styleProperties Map<String, dynamic>
"style"-property with further split-up values
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
putStyleProperty(String stylePropertyKey, String value) → void
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited