Yes, one would use higher order functions, as is common in Erlang, Elixir, OCaml, Elm, etc.
Elixir does have protocols, but they are extremely limited compared to type classes, traits, etc, and they're uncommonly used compared to writing concrete code.