Gcode.Model.Comment (gcode v0.4.1)

A G-code comment.

Link to this section Summary

Functions

Initialise a comment.

Link to this section Types

Specs

error() :: {:comment_error, String.t()}

Specs

t() :: %Gcode.Model.Comment{comment: String.t()}

Link to this section Functions

Specs

init(String.t()) :: Gcode.Result.t(t(), error())

Initialise a comment.

Example

iex> "Doc, in the carpark, with plutonium"
...> |> Comment.init()
{:ok, %Comment{comment: "Doc, in the carpark, with plutonium"}}