An overlay is an endpoint that defines and manages a relationship between a host space and a wrapped space. The overlay endpoint defines a set of identifiers that resolve to it
All requests destined for the wrapped space must first arrive at the overlay endpoint; there is no other way for requests to enter a wrapped space.
An overlay is implemented by a single physical endpoint. It may surface one or more logical endpoints within the host space. The set of logical endpoints surfaced is determined by the nature of the relationship with the wrapped space. For example, a transparent overlay will surface all logical endpoints in the wrapped space faithfully.
An overlay is declared with the overlay element which must have a space child element and must have either a class or prototype reference in a child element:
The wrapped space declaration is a full standard space and may contain any regular space elements.
The overlay's wrapped space is effectively exactly the same as a rootspace, however it is entirely encapsulated by the overlay and is not known to any other space, and is not even even known to the kernel. Therefore the wrapped space cannot be accessed by an import - the only route into the wrapped space is through the overlay endpoint.
The wrapped space may contain other overlays which in turn would have their own wrapped spaces. There is no limit to the depth to which overlays may be nested. If you have the need for nested overlay's you may find the branch-merge endpoint provides a convenient tool for implementing some common wrapped overlay patterns.
A wrapped space supports the name attribute to give the wrapped space a human readable name.