资 源 简 介
Introduction
Gear is a .NET library which supports a composable object model. Instead of relying on subclassing to customize the behavior of base classes Gear relies on composition of private implementations into aggregated objects which expose interfaces.
Concepts
Boss - These are the objects in the Gear object model. Bosses contain one or more implementations which expose interfaces. The only way to interact with the implementations is via the interfaces it exposes. Interfaces are dynamically queried at runtime.
Interface - These are normal C# interfaces. To preserve forward compatibility you should not remove or change methods in a published interface although you can add new methods.
Implementation - These are normal C# concrete classes. They should be marked internal and must implement one or more interfaces. There is no way to access an implementation in an boss other than via reflection.
ObjectModel - This is a static cl