Dynamic Operations
To finish off our overview of DynamicObject
and DynamicMetaObject
, let’s take a quick look at the various operations that can be specialized by overriding a method on those base classes. Some of those operations have a C# notation, whereas others exist in dynamic languages only:
Binary operations, such as mathematical logical operators and (in)equality operators. For example, a + b
, a > b
, a && b
.
Unary operations, such as logical negation or complement or numeric minus or plus. For example, -a
, !a
.
Getting and setting members ...
Get C# 5.0 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.