Skill 2.1: Create typesValue and reference typesCreating value typesCreating reference typesSkill 2.2: Consume typesBoxing and unboxingCast typesSkill 2.3: Enforce encapsulationAccess modifiersEnforce encapsulation by using propertiesEnforce encapsulation by using accessorsEnforce encapsulation by using explicit interface implementationSkill 2.4: Create and implement a class hierarchyDesign and implement an interfaceInherit from a base classCreate and implement classes based on the IComparable, IEnumerable, IDisposable, and IUnknown interfacesSkill 2.5: Find, execute, and create types at runtime by using reflectionCreate and apply attributesRead attributesUsing reflectionGenerate code at runtime by using CodeDOM and Lambda expressionsUse types from the System.Reflection namespaceSkill 2.6: Manage the object life cycleGarbage collection in .NETManage unmanaged resourcesImplement IDisposable, including interaction with finalizationManage IDisposable by using the Using statementManage finalization and garbage collectionSkill 2.7: Manipulate stringsThe string typeManipulate strings by using the StringBuilder, StringWriter, and StringReader classesSearch stringsEnumerate string methodsFormat stringsUse string interpolationThought experiments1 Creating types2 Consuming types3 Enforce encapsulation4 Create and implement a class hierarchy5 Find, execute, and create types at runtime by using reflection6 Manage the object life cycle7 Manipulate stringsThought experiment answers1 Creating types2 Consuming types3 Enforce encapsulation4 Create and implement a class hierarchy5 Find, execute, and create types at runtime by using reflection6 Manage the object life cycle7 Manipulate stringsChapter summary