Using Generics in C#
52mBeginner2018-08-16
Authors

Robby Millsap
Senior Software Engineer at Trek Bicycle
Course details
Generics were introduced to C# 2.0 in 2005. They allow programmers to write general-purpose code that is type safe, without writing a tedious amount of type-specific data structures. Similar to C++ templates, generics reduce the amount of type checking required to build reusable code and make you a much more productive C# programmer. This course is designed to introduce the beginning programmer to the concept of generics and show how to use them for greater reusability in popular design patterns. Instructor Robby Millsap covers the history and purpose of generics, as well as concepts such as type scoping, constraints, and collections. In chapter two, he demonstrates how to incorporate generics into actual architecture, following design patterns such as service locator, visitor, and observer.
Skills covered
C#PersonaProgramming LanguagesMicrosoftSoftware Development
Concepts
0. Introduction
- 01 - Using generics to make your code safer and more valuable
- 02 - What you should know
- 03 - Exercise files
1. Overview
- 04 - History
- 05 - Problem statement
- 06 - Introducing generics
- 07 - Type scoping
- 08 - Constraints
- 09 - Collections
2. Architecting in Generics
- 10 - Introduction
- 11 - Service locator
- 12 - Visitor
- 13 - Observer
Conclusion
- 14 - What we learned