Abstract

This chapter discusses the programming structures and starts with the discussion of the String class in C#. Just like in Java, strings are special objects with the special support of the language. In many instances, the only difference between a member of the Java string class java.lang.string and the C# class System.String is in the capitalization of the method name. Both System.String and the data type string can be used interchangeably. The reason for this is that Microsoft has aliased the string data type to the System.String class. Most of the Java string methods are included in the C# string class, as well as some other methods. This chapter goes over String creation, and then proceeds into the StringBuilder class, which is very much like Java's StringBuffer. It also discusses the RegEx class, which permits the use of regular expressions, a very powerful feature that was Perl's claim to fame. This chapter introduces the basic flow controls of the C# language and the ‘for each’ statement. Some of the collection classes provided by the .NET framework are examined. It discusses arrays and a new feature not found in Java, called Indexers.

Full Text
Paper version not known

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.