|
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<configSections>
<section name="unity" type="Microsoft.Practices.Unity.Configuration.UnityConfigurationSection, Microsoft.Practices.Unity.Configuration, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</configSections>
<unity>
<typeAliases>
<!-- Lifetime manager types -->
<typeAlias alias="singleton" type="Microsoft.Practices.Unity.ContainerControlledLifetimeManager, Microsoft.Practices.Unity"/>
<typeAlias alias="external" type="Microsoft.Practices.Unity.ExternallyControlledLifetimeManager, Microsoft.Practices.Unity"/>
<!-- Custom object types -->
<typeAlias alias="IEmployee" type="NotificationLibrary.IEmployee, NotificationLibrary"/>
<typeAlias alias="IManager" type="NotificationLibrary.IManager, NotificationLibrary"/>
<typeAlias alias="IPerson" type="NotificationLibrary.IPerson, NotificationLibrary"/> <!--used as a parameter in objects-->
<typeAlias alias="MySingletonEmployee" type="NotificationLibrary.IEmployee, NotificationLibrary" />
</typeAliases>
<containers>
<container name="containerOne">
<types>
<!-- Default (un-named) mapping for IEmployee to IEmployee-->
<type type="IEmployee" mapTo="IEmployee"/>
<!-- Default (un-named) mapping for ILogger to MyLogger -->
<type type="ILogger" mapTo="MySingletonEmployee">
<lifetime type="singleton"/>
</type>
<!-- Named mapping for IEmployee to MySingletonEmployee-->
<type type="IEmployee" mapTo="MySingletonEmployee" name="SingleTonEmployee">
<lifetime type="singleton"/>
</type>
<!-- Named mapping for IEmployee to MySingletonEmployee-->
<type type="IEmployee" mapTo="MySingletonEmployee" name="NonSingletonEmployee">
<lifetime type="external"/>
</type>
</types>
</container>
</containers>
</unity>
<system.web>
<compilation debug="true" targetFramework="4.0" />
</system.web>
</configuration>
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.