PolyAmory.__using__

You're seeing just the macro __using__, go back to PolyAmory module for more information.
Link to this macro

__using__(opts)

View Source (macro)

Arguments

  • types: Keyword list of {name, type}. The name is stored in the database in order to identify what type to use in runtime.
  • type_field: Name of the field used to the type of that particular object. Default is :__type__.

Example

defmodule PolyAmory.TestChannelData do
  use PolyAmory, types: [
    sms: TestSmsChannel,
    email: TestEmailChannel,
  ]
end