Go Recipes pp 53-74 | Cite as

Structs and Interfaces

  • Shiju Varghese
Chapter

Abstract

When you write programs, the type system of your choice of language is very important. Types allow you to organize your application data in a structured way that can be persisted into various data stores. When you write applications, especially business applications, you organize your application data using various types and persist the values of those types into persistence storage. When you write applications with Go, it is important to understand its type system and its design philosophy. Go provides various built-in types such as int, uint, float64, string, and bool. Data structures for storing collections of values such as arrays, slices, and maps are known as composite types because they are made up of other types—built-in types and user-defined types. In addition to the built-in types provided by Go, you can create your own types by combining with other types. This chapter contains recipes for user-defined types in Go.

Keywords

Developer Type Order Struct Code Block Design Philosophy Pointer Receiver 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Copyright information

© Shiju Varghese 2016

Authors and Affiliations

  • Shiju Varghese
    • 1
  1. 1.Chettiyadan HouseCheranalloorIndia

Personalised recommendations