Islands Island v0.1.6 Islands.Island View Source
Models an island
in the Game of Islands.
Based on the book Functional Web Development by Lance Halvorsen.
Link to this section Summary
Link to this section Types
Link to this type
coords()
View Source
coords()
View Source
coords() :: MapSet.t(Islands.Coord.t())
coords() :: MapSet.t(Islands.Coord.t())
Link to this type
type()
View Source
type()
View Source
type() :: :atoll | :dot | :l_shape | :s_shape | :square
type() :: :atoll | :dot | :l_shape | :s_shape | :square
Link to this section Functions
Link to this function
forested?(island) View Source
Link to this function
guess(island, guess)
View Source
guess(island, guess)
View Source
guess(t(), Islands.Coord.t()) :: {:hit, t()} | :miss
guess(t(), Islands.Coord.t()) :: {:hit, t()} | :miss
Link to this function
new(type, origin)
View Source
new(type, origin)
View Source
new(type(), Islands.Coord.t()) :: {:ok, t()} | {:error, atom()}
new(type(), Islands.Coord.t()) :: {:ok, t()} | {:error, atom()}
Link to this function