Abstract
In this chapter, you’ll deepen your understanding of the C# programming language by examining a number of more advanced syntactic constructs. To begin, you’ll learn how to implement and use an indexer method. This C# mechanism enables you to build custom types that provide access to internal subitems using an array-like syntax. After you learn how to build an indexer method, you’ll see how to overload various operators (+, −, <, >, and so forth), and how to create custom explicit and implicit conversion routines for your types (and you’ll learn why you might want to do this).
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Rights and permissions
Copyright information
© 2012 Andrew Troelsen
About this chapter
Cite this chapter
Troelsen, A. (2012). Advanced C# Language Features. In: Pro C# 5.0 and the .NET 4.5 Framework. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4302-4234-5_11
Download citation
DOI: https://doi.org/10.1007/978-1-4302-4234-5_11
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4302-4233-8
Online ISBN: 978-1-4302-4234-5
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)