Web Resources:
CppReference.com, CPlusPlus.com, C++ TechLinksGoing Native 2013 - many experts
Herb Sutter's Blog, Herb Sutter on C++11, Herb Sutter keynote - Going Native 2012
Scott Meyer's Blog, S.M. on thread suspension, S.M.: C++11 Sampler
Stroustrup's Home Page, Code Project, Boost Library
Content:
This lecture finishes Abstract Data Types, then presents templates, a type safe replacement for macros. We will show later in the course how templates are used in the Standard Template Library to provide a powerful set of algorithms and data structures.- useful C++ reference
-
Syllabus
Describes topics to be covered, reading material for you to digest before coming to class, and due dates for the assigned projects. Help Session this Friday: 1st group at 9:00 am in CST 4-201, 2nd group at 10:30am
-
Project #1
Resources for Project #1:
Project #1 statement, Project1HelpS17
Project Grade Sheet, Code Analyzer
Project Properties, doc
Project Submissions C++ Survival Guide, doc
Visual Studio help notes, doc
- Top-Down Design, Bottom-up Design, Incremental Development
-
Abstract Data Types
Abstract Data Types Presentation, pptx
What does it take to make objects of your class behave like built in types? STR class
This is a good example of an ADT. It is presented as a nice example. You should prefer the std::string class for all your development work. C++ Operators, ppt vector3D
An example of an Abstract Data Type that is rich in operators. Shows the accepted style for building ADT classes with mathematical operations. -
New style casts:
new-style casts: demo code There are four distinct things the new-style casts provide:-
static_cast:
- converts a foreign type to a type defined by a class with a promotion constructor
- converts an instance of a type that provides a cast operator to a foreign type
-
const_cast:
Provides a non-const reference to a const object. That allows you to apply a non-const function to a const object.
Please don't do that unless you are sure the the non-const function won't change the const object. -
reinterpret_cast:
Treat an instance of one type by the rules of another type. -
dynamic_cast:
Support safe downcasting from a base pointer or reference to a derived pointer or reference.
-
static_cast:
-
Namespaces
Basic information about how namespaces work. We will discuss why you want to use them. - Software Design
-
Design Rules
Design rules and idioms that transcend Object Oriented Design. -
Templates Presentation
Templates are one of the terrific features of the C++ language. They are the basis of the Standard Template Library (STL) and are useful in day-to-day programming. -
These are the most important items from today's lecture:
Abstract Data Types Presentation, pptx
What does it take to make objects of your class behave like built in types? STR class
This is a good example of an ADT. It is presented as a nice example. You should prefer the std::string class for all your development work.