ContentLink.parse constructor

ContentLink.parse(
  1. XmlElement element
)

Factory method to parse an XmlElement and create a ContentLink object from it.

The element is an XML element containing the content link information.

Returns the parsed ContentLink object.

Implementation

factory ContentLink.parse(XmlElement element) {
  return ContentLink(
    href: element.getAttribute('href'),
    value: element.innerText,
  );
}