diff options
Diffstat (limited to 'lib/chessh/ssh/screens/screen.ex')
-rw-r--r-- | lib/chessh/ssh/screens/screen.ex | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/chessh/ssh/screens/screen.ex b/lib/chessh/ssh/screens/screen.ex new file mode 100644 index 0000000..be6e00e --- /dev/null +++ b/lib/chessh/ssh/screens/screen.ex @@ -0,0 +1,15 @@ +defmodule Chessh.SSH.Client.Screen do + @callback render(state :: Chessh.SSH.Client.State.t() | any()) :: any() + @callback handle_input(action :: any(), state :: Chessh.SSH.Client.State.t()) :: + Chessh.SSH.Client.State.t() + + defmacro __using__(_) do + quote do + @behaviour Chessh.SSH.Client.Screen + + @ascii_chars Application.compile_env!(:chessh, :ascii_chars_json_file) + |> File.read!() + |> Jason.decode!() + end + end +end |