View Source UkraineTaxidEx.BaseParser behaviour (ukraine_tax_id v0.1.1)

Summary

Types

Options for parsing

Types

options()

@type options() :: [normalize?: boolean(), clean?: boolean()]

Options for parsing:

  • :normalize? - if true, pad the string to the right length (8 for EDRPOU, 10 for ITIN)
  • :clean? - if true, remove non-digit characters

Callbacks

parse(code, options)

@callback parse(code :: String.t(), options :: options()) ::
  {:ok, term()} | {:error, atom()}