O GoConqr está de visual novo! Conte para nós o que você achou.

Mapa mental

Making your own data types and typeclasses

Santiago Cárdenas Inglês

Conteúdo do mapa

Making your own data types and typeclasses

  1. Algebraic data types

    • We can use the keyword data to make our own data types, also we can use the keyword deriving (show) to make the type part of the Show typeclass
  2. Record Sintax

    • We can create whatever object we want with an sintax that is pretty similar to the sintax of the data in the modules
  3. Type parameters

    • We can also use parameters of any type in the construction of any object, using all the previous concepts we can create an even more generic object.
  4. Derived instances

    • Derived instances are like addons that can be added to our objects, so they can be some sort of things, like for example if we derive Eq we can compare, if we derive Show we can print, etc...
  5. Typeclasses

    • We can create our own typleclasses using the keyword class and creating our own rules for the typeclass
  6. Functor Typeclass

    • The functor typeclass can be used like the map function, but in this case the list can have any type of data, and the function will be applied in the corresponding data type that can be applied.

Informações

Descrição
Mapa Mental sobre Making your own data types and typeclasses, criado por Santiago Cárdenas em 27-03-2019.
Visualizações
0
Avaliação

Mais sobre Data Types and Typeclasses

Fale Conosco

Sobre o que é sua mensagem?

O que você acha do novo visual?

Você gostou?