My latest Pluralsight course is now available online:
Explore practical solutions to ten common problems that can be solved quite effectively with Visual C++.
Visual C++ has a bad reputation for productivity when compared with its .NET counterparts in the Visual Studio family. While I won’t argue with the fact that simple tasks can often be a little more complicated in C++, the benefits are often worthwhile. From faster and more responsive apps to dramatically reduced memory usage and more predictable resource management. These are all critical factors when producing apps for a new generation of increasingly mobile devices.
In this course you’re going to discover many techniques to search, sort and generate text and XML. You’ll discover effective ways to access the web, communicate with web sockets, and access databases on Windows Azure. You’re going to learn how to master long file paths, layered windows, and how to use SQLite. You’ll discover that writing high-DPI applications needn’t be hard and how to apply cryptography to keep the bad guys out. There’s something here for everyone!
Here’s a quick summary.
1. Searching and Sorting Text
Study the topic of searching and sorting text with an emphasis on modern C++, performance, and efficiency. Tradeoffs include accuracy, performance, and simplicity. You’ll learn about modern libraries, concurrency, regular expressions, and memory mapped files. We’ll consider performance analysis and how slow regex and stream I/O really is.
2. Downloading Files with Internet Explorer
Explore some fundamental options provided by the browser to download content from the web. If you want to wield a lot of downloading power with very little effort then this might be what you need. You’ll learn about the browser cache, streams, status and progress reporting, and even how to manipulate console output.
3. Reading and Writing XML
Learn how to use a fast and lightweight XML parser provided by Windows. Discover how to use the XmlLite library, a blazingly fast and efficient way to process and produce XML documents with ease. You’ll learn about error handling, reading and finding elements, creating temporary files and streams. RSS and HTML are used as a simple example to illustrate various aspects of the XmlLite library.
4. Using WebSockets
Learn how to enable bidirectional communication over the web with the WebSocket protocol. We’ll knock together a quick WebSocket server in C# and then dive into the WinHTTP API to discover how you can easily tame the WebSocket protocol from C++. WinHTTP is a classic C-style API so, as always, you’ll discover how to bring it to life with modern C++.
5. Using Databases on Windows Azure
Discover how to use ODBC to create and interact with a SQL database on Windows Azure. Learn how to set up a database server on Windows Azure and how to create databases programmatically from C++. ODBC is particularly troublesome for C++ developers and you’ll learn how to bring it under submission with modern C++. Database servers tend to provide unique error handling challenges. Learn how to harvest good error and information diagnostics, execute statements, work with tables and cursors, and how to bind columns for simplicity.
6. Using SQLite Databases
Discover how to use SQLite, a completely self-contained, serverless, zero-configuration, SQL database engine. SQLite is an open source, public domain library. Find out how to get it and compile it as part of your C++ project. It has its own quirky C-style API but thankfully modern C++ comes to the rescue again. Discover how to create databases, reliably retrieve error information, and execute statements. You’ll also learn how to create statement objects for greater control and simplicity.
7. Working with File Paths
Master long file paths, safe and elegant path management, and recursive directory creation and deletion. Path management is a complex topic that covers security threats and mitigations. Discover how to avoid many pitfalls. Learn what MAX_PATH really means and get to know a safe alternative that provides respite from security concerns, great support for long file paths, better error information, and much more.
8. Creating Layered Windows
Layered windows provide the unique capability of rendering a window where portions of the window’s bounding rectangle are transparent or at least not fully opaque. You’ll learn the essentials of window creation and management. You’ll learn about window regions, simple transparency, color keys, and more. Finally, you’ll discover how to employ Direct2D’s excellent interop services to render a layered window efficiently.
9. Writing High-DPI Applications
Discover how to write beautiful, high-DPI apps that take advantage of the latest per-monitor and dynamic DPI support in Windows. What does High-DPI mean for apps running on Windows 8.1? Discover the new user controls, the legacy of DPI management on Windows, the concept and practicalities of DPI awareness, and the future of high-DPI scaling and responsiveness on Windows.
10. Applying Cryptography
Discover how to use cryptography effectively in your applications, with random number generation, hash functions, and encryption. The sinister art of cryptography need not be out of your reach. This module focuses on the practicalities of cryptography in C++. You’ll learn about algorithm providers, secure random number generation, hashing and hash functions, keys, encryption, and decryption.
If you’d like to follow along you can download the exercise files or simply grab handle.h and debug.h from dx.codeplex.com.
Have you missed one of my previous courses? Master the essentials of COM, DirectX with C++, and even C programming!