All IoC containers supported by Lamino provide a facility whereby a sub-configuration is loaded from an external file. This facility enables some separation of concerns but has the following shortcomings:

  • There is no way to reuse this sub-configuration more than one time
  • There is no way to hide internals from the importer

Adding those two capabilities brings to life the notion of components. A component provides services to its importer (exported services) and requests services (imported services) from it.



The syntax to import a component builds on the existing syntax for importing, but it adds optional directives for hiding and renaming services exported by the component, and providing imported services to it (all subsequent examples in Windsor Castle):

<include uri="WidsorComponent.xml">
	<hiding object="OtherPublicComponentToBeHidden"/>
	<renaming object="ExplicitlyPublicComponent" as="Compo1"/>
	<renaming object="ImplicitlyPublicComponent" as="Compo2"/>
	<providing object="NewObject" as="External"/>

Using this capability allows one to instantiate (import) the same component more than once, without objects in the many instances conflicting with one another.


A component is basically just a fragment of configuration. The only modification of the syntax is the ability to mark objects as public or hidden:

		<component id="ExplicitlyPublicComponent" visibility="public">
				<Property3>foobar original</Property3>
		<component id="ImplicitlyPublicComponent">
				<Property6>foobaz original</Property6>
		<component id="OtherPublicComponentToBeHidden"/>
		<component id="Hidden" visibility="private">
				<Property5>baz original</Property5>

Hidden objects cannot conflict with other objects of the importing configuration.

Extending a component, to create a derived component, is done as described in the page about Layering.