A reference to an element: href="#id" is an element of the same model, href="namespace#id" one of the model with that
namespace, which a model imports (DMN 1.6, 6.3.3). An id is an xsd:ID, which has no #, and a namespace may have one
(https://example.org/m#v2), so the id is what follows the last #.
Summary
Functions
Reads the value of an href. nil for one that names nothing.
Types
Functions
Reads the value of an href. nil for one that names nothing.
iex> Dmn.Model.Reference.parse("#_a1")
%Dmn.Model.Reference{namespace: nil, id: "_a1"}
iex> Dmn.Model.Reference.parse("https://example.org/m#_b2")
%Dmn.Model.Reference{namespace: "https://example.org/m", id: "_b2"}
iex> Dmn.Model.Reference.parse("https://example.org/m#v2#_b2")
%Dmn.Model.Reference{namespace: "https://example.org/m#v2", id: "_b2"}
iex> Dmn.Model.Reference.parse("no-fragment")
nil