Many people might call them interfaces
, but traits particularly describe which capabilities are expected from an object. Functions for example expect certain traits from the arguments they receive and on the other hand promise to return a value with with one or more traits.
As mentioned before, every object can be expected to own more than one trait at the same time.
- Application
- EventTarget
- DataStorage
- RenderEngine