# `Behaviour`
[🔗](https://github.com/elixir-lang/elixir/blob/v1.20.0-rc.3/lib/elixir/lib/behaviour.ex#L5)

> This module is deprecated. Use @callback and @macrocallback attributes instead.

Mechanism for handling behaviours.

This module is deprecated. Instead of `defcallback/1` and
`defmacrocallback/1`, the `@callback` and `@macrocallback`
module attributes can be used respectively. See the
documentation for `Module` for more information on these
attributes.

Instead of `MyModule.__behaviour__(:callbacks)`,
`MyModule.behaviour_info(:callbacks)` can be used. `behaviour_info/1`
is documented in `Module`.

# `defcallback`
*macro* 

> This macro is deprecated. Use the @callback module attribute instead.

Defines a function callback according to the given type specification.

# `defmacrocallback`
*macro* 

> This macro is deprecated. Use the @macrocallback module attribute instead.

Defines a macro callback according to the given type specification.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
