URL v0.4.1 URL.Mailto View Source
Parses a mailto
URL
Link to this section Summary
Functions
Parse a URI with the :scheme
of “mailto”
Link to this section Types
Link to this section Functions
Link to this function
parse(uri)
View Source
parse(URI.t()) :: URL.Mailto.t() | {:error, {module(), binary()}}
Parse a URI with the :scheme
of “mailto”
Example
iex> mailto = URI.parse("mailto:user@%E7%B4%8D%E8%B1%86.example.org?subject=Test&body=NATTO")
iex> URL.Mailto.parse(mailto)
%URL.Mailto{
params: %{"body" => "NATTO", "subject" => "Test"},
to: ["user@納豆.example.org"]
}