The Webfeed Flutter package for Appeto SDK.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 regels
564 B

  1. import 'package:xml/xml.dart';
  2. class Text {
  3. final String type;
  4. final String lang;
  5. final String start;
  6. final String end;
  7. final String value;
  8. Text({
  9. this.type,
  10. this.lang,
  11. this.start,
  12. this.end,
  13. this.value,
  14. });
  15. factory Text.parse(XmlElement element) {
  16. if (element == null) {
  17. return null;
  18. }
  19. return Text(
  20. type: element.getAttribute('type'),
  21. lang: element.getAttribute('lang'),
  22. start: element.getAttribute('start'),
  23. end: element.getAttribute('end'),
  24. value: element.text,
  25. );
  26. }
  27. }