Knigge.Behaviour (Knigge v1.4.1) View Source

Internal module to work with the supplied behaviour.

Can be used to fetch the behaviour from the Knigge.Options-struct and to access the callbacks defined by the behaviour.

It works whether the module is already compiled or still open, for which it uses Module.open?/1. If the module is still open it directly accesses the module attribute :callback by calling Module.get_attribute/2 and then using Knigge.AST.function_spec_from_callback/1 to transform the AST into a function spec, such as {:my_function, 2} which is being returned as a Keyword list.

Link to this section Summary

Link to this section Functions