更新时间:2021-06-18 19:06:01
封面
版权信息
Packt Upsell
Why subscribe?
PacktPub.com
Contributors
About the authors
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Download the color images
Conventions used
Get in touch
Reviews
Reactive Programming Model – Overview and History
Event-driven programming model
Event-driven programming on X Windows
Event-driven programming on Microsoft Windows
Event-driven programming under Qt
Event-driven programming under MFC
Other event-driven programming models
Limitations of classical event processing models
Reactive programming model
Functional reactive programming
The key interfaces of a reactive program
Pull-versus push-based reactive programming
The IEnumerable/IObservable duality
Converting events to IObservable<T>
The philosophy of our book
Summary
A Tour of Modern C++ and its Key Idioms
The key concerns of the C++ programming language
Zero cost abstraction
Expressivity
Substitutability
Enhancements to C++ for writing better code
Type deduction and inference
Uniform initialization of variables
Variadic templates
Rvalue references
Move semantics
Smart pointers
Lambda functions
Functors and Lambdas
Composition currying and partial function application
Function wrappers
Composing functions together with the pipe operator
Miscellaneous features
Fold expressions
Variant type
Other important topics
Range-based for loops and observables
Language-Level Concurrency and Parallelism in C++
What is concurrency?
Hello World of concurrency (using std::thread)
Managing threads
Thread launch
Thread join
Passing arguments into a thread
Using Lambdas
Ownership management
Sharing data between threads
Mutexes
Avoiding deadlock
Locking with std::unique_lock
Condition variables
A thread-safe stack data structure
Asynchronous and Lock-Free Programming in C++
Task-based parallelism in C++
Future and promise
std::packaged_task
std::async
C++ memory model
Memory access and concurrency
The modification contract
Atomic operations and types in C++
Atomic types
std::atomic_flag
std::atomic<bool>
Standard atomic integral types
std::atomic<T*> – pointer arithmetic
std::atomic<> primary class template
Memory ordering
Sequential consistency
Acquire-release ordering
Relaxed ordering
A lock-free data structure queue
Introduction to Observables
The GoF Observer pattern
The limitations of the GoF Observer pattern
A holistic look at GoF patterns
The OOP programming model and hierarchies
A Composite/Visitor pattern for expression processing