Commit 5e2995e1 authored by Bart Boone's avatar Bart Boone 🤞🏼

WIP: Nuget-packages bijgewerkt

Visual Studio gaf opmerkingen op de LifeTimeManagers. Die moesten een abtract class implementeren, waardoor er in drie classes twee methods bij gekomen zijn. GetValue() vond ik in de base class, dat is normaal gezien in orde, maar met OnCreateLifetimeManager() zit ik vast. Daar staat nu een NotImplementedException, maar ik weet niet of dat een probleem is. De unit tests geven geen problemen aan.
parent 768a91d0
......@@ -31,18 +31,8 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Practices.ServiceLocation, Version=1.3.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.LoginService\packages\CommonServiceLocator.1.3\lib\portable-net4+sl5+netcore45+wpa81+wp8\Microsoft.Practices.ServiceLocation.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Practices.Unity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.RegistrationByConvention, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.RegistrationByConvention.dll</HintPath>
<Reference Include="CommonServiceLocator, Version=2.0.3.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\CommonServiceLocator.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
......@@ -52,6 +42,27 @@
<Reference Include="System.Data" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Xml" />
<Reference Include="Unity.Abstractions, Version=3.3.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Unity.Configuration, Version=5.2.1.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.Container, Version=5.8.6.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Container.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception, Version=5.5.1.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception.Configuration, Version=5.1.4.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.RegistrationByConvention, Version=2.1.5.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.RegistrationByConvention.dll</HintPath>
</Reference>
<Reference Include="Unity.ServiceLocation, Version=2.1.2.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.ServiceLocation.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Factory.cs" />
......
......@@ -18,7 +18,7 @@
using System;
using System.Diagnostics;
using Microsoft.Practices.Unity;
using Unity;
namespace Chiro.Cdf.Ioc.Factory
{
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="CommonServiceLocator" version="1.3" targetFramework="net45" />
<package id="Unity" version="4.0.1" targetFramework="net45" />
<package id="CommonServiceLocator" version="2.0.3" targetFramework="net45" />
<package id="Unity" version="5.8.6" targetFramework="net45" />
</packages>
\ No newline at end of file
......@@ -39,18 +39,33 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Practices.Unity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.RegistrationByConvention, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.RegistrationByConvention.dll</HintPath>
<Reference Include="CommonServiceLocator, Version=2.0.3.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\CommonServiceLocator.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Configuration" />
<Reference Include="Unity.Abstractions, Version=3.3.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Unity.Configuration, Version=5.2.1.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.Container, Version=5.8.6.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Container.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception, Version=5.5.1.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception.Configuration, Version=5.1.4.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.RegistrationByConvention, Version=2.1.5.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.RegistrationByConvention.dll</HintPath>
</Reference>
<Reference Include="Unity.ServiceLocation, Version=2.1.2.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.ServiceLocation.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="UnityDiContainer.cs" />
......
......@@ -19,8 +19,8 @@
using System;
using System.Configuration;
using System.Diagnostics;
using Microsoft.Practices.Unity;
using Microsoft.Practices.Unity.Configuration;
using Unity;
namespace Chiro.Cdf.Ioc
{
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="CommonServiceLocator" version="1.3" targetFramework="net45" />
<package id="Unity" version="4.0.1" targetFramework="net45" />
<package id="CommonServiceLocator" version="2.0.3" targetFramework="net45" />
<package id="Unity" version="5.8.6" targetFramework="net45" />
</packages>
\ No newline at end of file
......@@ -41,17 +41,8 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Practices.ServiceLocation, Version=1.3.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\CommonServiceLocator.1.3\lib\portable-net4+sl5+netcore45+wpa81+wp8\Microsoft.Practices.ServiceLocation.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.RegistrationByConvention, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.RegistrationByConvention.dll</HintPath>
<Reference Include="CommonServiceLocator, Version=2.0.3.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\CommonServiceLocator.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
......@@ -61,6 +52,27 @@
<Reference Include="System.ServiceModel">
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
<Reference Include="Unity.Abstractions, Version=3.3.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Unity.Configuration, Version=5.2.1.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.Container, Version=5.8.6.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Container.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception, Version=5.5.1.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception.Configuration, Version=5.1.4.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.RegistrationByConvention, Version=2.1.5.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.RegistrationByConvention.dll</HintPath>
</Reference>
<Reference Include="Unity.ServiceLocation, Version=2.1.2.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.ServiceLocation.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Extentions.cs" />
......
......@@ -15,11 +15,12 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
using System;
using System.ServiceModel;
using System.ServiceModel.Description;
using System.Messaging;
using Microsoft.Practices.Unity;
using Unity.Attributes;
// LET OP! De klasses in dit project hebben niets te maken met ServiceHelper, wel met de
// implementatie van onze message queue services.
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="CommonServiceLocator" version="1.3" targetFramework="net45" />
<package id="Unity" version="4.0.1" targetFramework="net45" />
<package id="CommonServiceLocator" version="2.0.3" targetFramework="net45" />
<package id="Unity" version="5.8.6" targetFramework="net45" />
</packages>
\ No newline at end of file
......@@ -35,25 +35,33 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Practices.ServiceLocation, Version=1.3.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.LoginService\packages\CommonServiceLocator.1.3\lib\portable-net4+sl5+netcore45+wpa81+wp8\Microsoft.Practices.ServiceLocation.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Practices.Unity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.LoginService\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.LoginService\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.Configuration.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Practices.Unity.RegistrationByConvention, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.LoginService\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.RegistrationByConvention.dll</HintPath>
<Private>True</Private>
<Reference Include="CommonServiceLocator, Version=2.0.3.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\CommonServiceLocator.dll</HintPath>
</Reference>
<Reference Include="System.Configuration" />
<Reference Include="System.Core" />
<Reference Include="System.ServiceModel" />
<Reference Include="Unity.Abstractions, Version=3.3.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Unity.Configuration, Version=5.2.1.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.Container, Version=5.8.6.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Container.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception, Version=5.5.1.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception.Configuration, Version=5.1.4.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.Interception.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.RegistrationByConvention, Version=2.1.5.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.RegistrationByConvention.dll</HintPath>
</Reference>
<Reference Include="Unity.ServiceLocation, Version=2.1.2.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\..\tools\Chiro.CiviSync\packages\Unity.5.8.6\lib\net45\Unity.ServiceLocation.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="GlobalSuppressions.cs" />
......
......@@ -15,15 +15,21 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
using System.ServiceModel;
using System.ServiceModel;
using Unity.Lifetime;
namespace Chiro.Cdf.UnityWcfExtensions
{
/// <summary>
/// Unity lifetime manager to support <see cref="System.ServiceModel.IContextChannel"/>.
/// Unity lifetime manager to support <see cref="IContextChannel"/>.
/// </summary>
public class UnityContextChannelLifetimeManager : UnityWcfLifetimeManager<IContextChannel>
{
public override object GetValue(ILifetimeContainer container = null)
{
return this.FindExtension().FindInstance(this.key);
}
/// <summary>
/// Returns the appropriate extension for the current lifetime manager.
/// </summary>
......@@ -32,5 +38,10 @@ protected override UnityWcfExtension<IContextChannel> FindExtension()
{
return UnityContextChannelExtension.Current;
}
protected override LifetimeManager OnCreateLifetimeManager()
{
throw new System.NotImplementedException();
}
}
}
......@@ -15,15 +15,22 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
using System.ServiceModel;
using System.ServiceModel;
using Unity.Lifetime;
namespace Chiro.Cdf.UnityWcfExtensions
{
/// <summary>
/// Unity lifetime manager to support <see cref="System.ServiceModel.InstanceContext"/>.
/// Unity lifetime manager to support <see cref="InstanceContext"/>.
/// </summary>
public class UnityInstanceContextLifetimeManager : UnityWcfLifetimeManager<InstanceContext>
{
public override object GetValue(ILifetimeContainer container = null)
{
return this.FindExtension().FindInstance(this.key);
}
/// <summary>
/// Returns the appropriate extension for the current lifetime manager.
/// </summary>
......@@ -32,5 +39,10 @@ protected override UnityWcfExtension<InstanceContext> FindExtension()
{
return UnityInstanceContextExtension.Current;
}
protected override LifetimeManager OnCreateLifetimeManager()
{
throw new System.NotImplementedException();
}
}
}
......@@ -15,7 +15,8 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
using System.ServiceModel;
using System.ServiceModel;
using Unity.Lifetime;
namespace Chiro.Cdf.UnityWcfExtensions
{
......@@ -24,6 +25,11 @@ namespace Chiro.Cdf.UnityWcfExtensions
/// </summary>
public class UnityOperationContextLifetimeManager : UnityWcfLifetimeManager<OperationContext>
{
public override object GetValue(ILifetimeContainer container = null)
{
throw new System.NotImplementedException();
}
/// <summary>
/// Returns the appropriate extension for the current lifetime manager.
/// </summary>
......@@ -32,5 +38,10 @@ protected override UnityWcfExtension<OperationContext> FindExtension()
{
return UnityOperationContextExtension.Current;
}
protected override LifetimeManager OnCreateLifetimeManager()
{
throw new System.NotImplementedException();
}
}
}
......@@ -15,7 +15,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
using System.ServiceModel;
using System.ServiceModel;
using Unity.Lifetime;
namespace Chiro.Cdf.UnityWcfExtensions
{
......@@ -24,6 +26,11 @@ namespace Chiro.Cdf.UnityWcfExtensions
/// </summary>
public class UnityServiceHostBaseLifetimeManager : UnityWcfLifetimeManager<ServiceHostBase>
{
public override object GetValue(ILifetimeContainer container = null)
{
return this.FindExtension().FindInstance(this.key);
}
/// <summary>
/// Returns the appropriate extension for the current lifetime manager.
/// </summary>
......@@ -32,5 +39,10 @@ protected override UnityWcfExtension<ServiceHostBase> FindExtension()
{
return UnityServiceHostBaseExtension.Current;
}
protected override LifetimeManager OnCreateLifetimeManager()
{
throw new System.NotImplementedException();
}
}
}
......@@ -19,7 +19,8 @@
using System;
using System.Globalization;
using System.ServiceModel;
using Microsoft.Practices.Unity;
using Unity;
using Unity.Lifetime;
namespace Chiro.Cdf.UnityWcfExtensions
{
......@@ -33,7 +34,7 @@ public abstract class UnityWcfLifetimeManager<T> : LifetimeManager
/// <summary>
/// Key for Unity to use for the associated object's instance.
/// </summary>
private readonly Guid key = Guid.NewGuid();
protected readonly Guid key = Guid.NewGuid();
/// <summary>
/// Gets the currently registered UnityWcfExtension for this lifetime manager.
......@@ -57,7 +58,7 @@ private UnityWcfExtension<T> Extension
/// Gets the object instance for the given key from the currently registered extension.
/// </summary>
/// <returns>The object instance associated with the given key. If no instance is registered, null is returned.</returns>
public override object GetValue()
public object GetValue()
{
return this.Extension.FindInstance(this.key);
}
......@@ -65,7 +66,7 @@ public override object GetValue()
/// <summary>
/// Removes the object instance for the given key from the currently registered extension.
/// </summary>
public override void RemoveValue()
public void RemoveValue()
{
// Not called, but just in case.
this.Extension.RemoveInstance(this.key);
......@@ -75,7 +76,7 @@ public override void RemoveValue()
/// Associates the supplied object instance with the given key in the currently registered extension.
/// </summary>
/// <param name="newValue">The object to register in the currently registered extension.</param>
public override void SetValue(object newValue)
public void SetValue(object newValue)
{
this.Extension.RegisterInstance(this.key, newValue);
}
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="CommonServiceLocator" version="1.3" targetFramework="net45" />
<package id="Unity" version="4.0.1" targetFramework="net45" />
<package id="CommonServiceLocator" version="2.0.3" targetFramework="net45" />
<package id="Unity" version="5.8.6" targetFramework="net45" />
</packages>
\ No newline at end of file
Subproject commit 2eaa4d5627997408d7c2bb5adca64a331c7695d2
Subproject commit 75c4017f3ebbdbc4d5004d9a9270296b0e1b0195
......@@ -113,11 +113,11 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
<bindingRedirect oldVersion="0.0.0.0-5.2.6.0" newVersion="5.2.6.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
......
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\packages\NUnit.3.10.1\build\NUnit.props" Condition="Exists('..\packages\NUnit.3.10.1\build\NUnit.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
......@@ -19,6 +20,8 @@
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
<RestorePackages>true</RestorePackages>
<TargetFrameworkProfile />
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
......@@ -38,16 +41,23 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Castle.Core, Version=4.1.1.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc, processorArchitecture=MSIL">
<HintPath>..\packages\Castle.Core.4.1.1\lib\net45\Castle.Core.dll</HintPath>
<Reference Include="Castle.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc, processorArchitecture=MSIL">
<HintPath>..\packages\Castle.Core.4.2.1\lib\net45\Castle.Core.dll</HintPath>
</Reference>
<Reference Include="Moq, Version=4.7.99.0, Culture=neutral, PublicKeyToken=69f491c39445e920, processorArchitecture=MSIL">
<HintPath>..\packages\Moq.4.7.99\lib\net45\Moq.dll</HintPath>
<Reference Include="Moq, Version=4.8.0.0, Culture=neutral, PublicKeyToken=69f491c39445e920, processorArchitecture=MSIL">
<HintPath>..\packages\Moq.4.8.2\lib\net45\Moq.dll</HintPath>
</Reference>
<Reference Include="nunit.framework, Version=3.8.1.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
<HintPath>..\packages\NUnit.3.8.1\lib\net45\nunit.framework.dll</HintPath>
<Reference Include="nunit.framework, Version=3.10.1.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
<HintPath>..\packages\NUnit.3.10.1\lib\net45\nunit.framework.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Threading.Tasks.Extensions, Version=4.1.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.Threading.Tasks.Extensions.4.3.0\lib\portable-net45+win8+wp8+wpa81\System.Threading.Tasks.Extensions.dll</HintPath>
</Reference>
<Reference Include="System.ValueTuple, Version=4.0.2.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>..\packages\System.ValueTuple.4.4.0\lib\netstandard1.0\System.ValueTuple.dll</HintPath>
</Reference>
</ItemGroup>
<Choose>
<When Condition="('$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == '') and '$(TargetFrameworkVersion)' == 'v3.5'">
......@@ -104,6 +114,12 @@
</Choose>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\NUnit.3.10.1\build\NUnit.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\NUnit.3.10.1\build\NUnit.props'))" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Castle.Core" version="4.1.1" targetFramework="net45" />
<package id="Moq" version="4.7.99" targetFramework="net45" />
<package id="NUnit" version="3.8.1" targetFramework="net45" />
<package id="Castle.Core" version="4.2.1" targetFramework="net45" />
<package id="Moq" version="4.8.2" targetFramework="net45" />
<package id="NUnit" version="3.10.1" targetFramework="net45" />
<package id="System.Threading.Tasks.Extensions" version="4.3.0" targetFramework="net45" />
<package id="System.ValueTuple" version="4.4.0" targetFramework="net45" />
</packages>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="..\packages\NUnit.3.10.1\build\NUnit.props" Condition="Exists('..\packages\NUnit.3.10.1\build\NUnit.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
......@@ -17,6 +18,8 @@
<IsCodedUITest>False</IsCodedUITest>
<TestProjectType>UnitTest</TestProjectType>
<TargetFrameworkProfile />
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
......@@ -36,13 +39,15 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="AutoMapper, Version=6.1.1.0, Culture=neutral, PublicKeyToken=be96cd2c38ef1005, processorArchitecture=MSIL">
<HintPath>..\packages\AutoMapper.6.1.1\lib\net45\AutoMapper.dll</HintPath>
<Reference Include="AutoMapper, Version=6.2.2.0, Culture=neutral, PublicKeyToken=be96cd2c38ef1005, processorArchitecture=MSIL">
<HintPath>..\packages\AutoMapper.6.2.2\lib\net45\AutoMapper.dll</HintPath>
</Reference>
<Reference Include="nunit.framework, Version=3.8.1.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
<HintPath>..\packages\NUnit.3.8.1\lib\net45\nunit.framework.dll</HintPath>
<Reference Include="Microsoft.CSharp" />
<Reference Include="nunit.framework, Version=3.10.1.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
<HintPath>..\packages\NUnit.3.10.1\lib\net45\nunit.framework.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Runtime.Serialization" />
</ItemGroup>
<Choose>
<When Condition="('$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == '') and '$(TargetFrameworkVersion)' == 'v3.5'">
......@@ -106,6 +111,12 @@
</Choose>
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\NUnit.3.10.1\build\NUnit.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\NUnit.3.10.1\build\NUnit.props'))" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
......
......@@ -4,11 +4,11 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
<bindingRedirect oldVersion="0.0.0.0-5.2.6.0" newVersion="5.2.6.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="AutoMapper" version="6.1.1" targetFramework="net45" />
<package id="NUnit" version="3.8.1" targetFramework="net45" />
<package id="AutoMapper" version="6.2.2" targetFramework="net45" />
<package id="NUnit" version="3.10.1" targetFramework="net45" />
</packages>
\ No newline at end of file
......@@ -31,11 +31,12 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="AutoMapper, Version=6.1.1.0, Culture=neutral, PublicKeyToken=be96cd2c38ef1005, processorArchitecture=MSIL">
<HintPath>..\packages\AutoMapper.6.1.1\lib\net45\AutoMapper.dll</HintPath>
<Reference Include="AutoMapper, Version=6.2.2.0, Culture=neutral, PublicKeyToken=be96cd2c38ef1005, processorArchitecture=MSIL">
<HintPath>..\packages\AutoMapper.6.2.2\lib\net45\AutoMapper.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="AutoMapper" version="6.1.1" targetFramework="net45" />
<package id="AutoMapper" version="6.2.2" targetFramework="net45" />
</packages>
\ No newline at end of file
......@@ -108,11 +108,11 @@
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
<bindingRedirect oldVersion="0.0.0.0-5.2.6.0" newVersion="5.2.6.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0" />
<bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Practices.ServiceLocation" publicKeyToken="31bf3856ad364e35" culture="neutral" />
......
......@@ -41,17 +41,8 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Practices.ServiceLocation, Version=1.3.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\CommonServiceLocator.1.3\lib\portable-net4+sl5+netcore45+wpa81+wp8\Microsoft.Practices.ServiceLocation.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Practices.Unity.RegistrationByConvention, Version=4.0.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.4.0.1\lib\net45\Microsoft.Practices.Unity.RegistrationByConvention.dll</HintPath>
<Reference Include="CommonServiceLocator, Version=2.0.3.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.5.8.6\lib\net45\CommonServiceLocator.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration.Install" />
......@@ -62,6 +53,27 @@
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
<Reference Include="System.ServiceProcess" />
<Reference Include="Unity.Abstractions, Version=3.3.0.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.5.8.6\lib\net45\Unity.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Unity.Configuration, Version=5.2.1.0, Culture=neutral, PublicKeyToken=6d32ff45e0ccc69f, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.5.8.6\lib\net45\Unity.Configuration.dll</HintPath>
</Reference>
<Reference Include="Unity.Container, Version=5.8.6.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.5.8.6\lib\net45\Unity.Container.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception, Version=5.5.1.0, Culture=neutral, PublicKeyToken=489b6accfaf20ef0, processorArchitecture=MSIL">
<HintPath>..\packages\Unity.5.8.6\lib\net45\Unity.Interception.dll</HintPath>
</Reference>
<Reference Include="Unity.Interception.Configuration, Version=5.1.4.0, Culture=ne