Player.parse constructor

Player.parse(
  1. XmlElement element
)

Parse constructor for the Player class, used when 'parsing' a feed

Implementation

factory Player.parse(XmlElement element) => Player(
      url: element.getAttribute('url'),
      width: int.tryParse(element.getAttribute('width') ?? '0'),
      height: int.tryParse(element.getAttribute('height') ?? '0'),
      value: element.innerText,
    );