Pete's Alley - Typespecs

Written by Rich Morin.

Contents: (hide) (show)

Path:  AreasContentOverviews

Precis:  use of Typespecs in Pete's Alley

This page describes the use of Dialyzer and Typespecs in Pete’s Alley. For background and supplementary information, please see Elixir, etc. - Typespecs.

Applications

Pete’s Alley is composed of several applications. Server is an umbrella app, so it contains no real code. The remaining apps perform the following tasks:

Loosely speaking, these apps occupy three layers:

Modules and Types

Each app has an <AppName>.Types module, defined in an _<app_name>_t.ex file. This module contains only @type, @typep, and @typedoc attributes.

Common

The Common.Types module, located in _common_t.ex, defines types for use throughout Pete’s Alley.

InfoFiles

The InfoFiles.Types module located in _info_files_t.ex, defines types for use in InfoFiles and PhxHttp*.

InfoToml

The InfoToml.Types module, located in _info_toml_t.ex, defines types for use in InfoToml and PhxHttp*.

InfoWeb

The InfoWeb.Types module, located in _info_web_t.ex, defines types for use in InfoWeb and PhxHttp*.

PhxHttp

The PhxHttp.Types module, located in _phx_http_t.ex, defines types for use in PhxHttp*.