9 lines
396 B
Elixir
9 lines
396 B
Elixir
# thank you PSPDFKit-people: https://pspdfkit.com/blog/2018/how-to-parse-xml-documents-in-elixir/
|
|
|
|
defmodule Weather.XML do
|
|
import Record
|
|
|
|
defrecord(:xmlElement, extract(:xmlElement, from_lib: "xmerl/include/xmerl.hrl"))
|
|
defrecord(:xmlAttribute, extract(:xmlAttribute, from_lib: "xmerl/include/xmerl.hrl"))
|
|
defrecord(:xmlText, extract(:xmlText, from_lib: "xmerl/include/xmerl.hrl"))
|
|
end |