Skip to content

Commit 164c8ea

Browse files
committed
separate registration by convention intro platform-specific assemblies
update the nuget package to include rbc binaries
1 parent 3355ae3 commit 164c8ea

27 files changed

+987
-233
lines changed

source/NuGet/Unity.nuspec

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
<group targetFramework="win8">
1414
<dependency id="CommonServiceLocator" version="1.2.0" />
1515
</group>
16+
<group targetFramework="wp80">
17+
<dependency id="CommonServiceLocator" version="1.2.0" />
18+
</group>
1619
</dependencies>
1720
<description>The Unity Application Block (Unity) is a lightweight extensible dependency injection container with support for constructor, property, and method call injection. It facilitates loosely-coupled design.</description>
1821
<summary>The Unity Application Block (Unity) is a lightweight extensible dependency injection container with support for constructor, property, and method call injection.</summary>
@@ -28,6 +31,21 @@
2831
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.Configuration.dll" target="lib\net45" />
2932
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.Configuration.pdb" target="lib\net45" />
3033
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.Configuration.xml" target="lib\net45" />
34+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.dll" target="lib\net45" />
35+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.pdb" target="lib\net45" />
36+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.xml" target="lib\net45" />
37+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.dll" target="lib\wp80" />
38+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.pdb" target="lib\wp80" />
39+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.xml" target="lib\wp80" />
40+
<file src="bin\WindowsPhone\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.dll" target="lib\wp80" />
41+
<file src="bin\WindowsPhone\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.pdb" target="lib\wp80" />
42+
<file src="bin\WindowsPhone\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.xml" target="lib\wp80" />
43+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.dll" target="lib\win8" />
44+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.pdb" target="lib\win8" />
45+
<file src="bin\Desktop\$Configuration$\Microsoft.Practices.Unity.xml" target="lib\win8" />
46+
<file src="bin\NetCore\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.dll" target="lib\win8" />
47+
<file src="bin\NetCore\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.pdb" target="lib\win8" />
48+
<file src="bin\NetCore\$Configuration$\Microsoft.Practices.Unity.RegistrationByConvention.xml" target="lib\win8" />
3149
<file src="UnityConfiguration30.xsd" target="" />
3250
<file src="NuGet\tools\Unity\install.ps1" target="tools" />
3351
<file src="Unity\Src\**\*.cs" target="src\Unity\Src" />

source/Unity.NetCore.sln

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TestNetAssembly.NetCore", "
1414
EndProject
1515
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity", "Unity\Src\Unity.csproj", "{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}"
1616
EndProject
17+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.RegistrationByConvention.NetCore", "Unity\Src\RegistrationByConvention\Unity.RegistrationByConvention.NetCore.csproj", "{858426D0-79AB-4928-95B9-A1E1725D31D3}"
18+
EndProject
1719
Global
1820
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1921
Debug|Any CPU = Debug|Any CPU
2022
Debug|ARM = Debug|ARM
21-
Debug|Mixed Platforms = Debug|Mixed Platforms
2223
Release|Any CPU = Release|Any CPU
2324
Release|ARM = Release|ARM
24-
Release|Mixed Platforms = Release|Mixed Platforms
2525
EndGlobalSection
2626
GlobalSection(ProjectConfigurationPlatforms) = postSolution
2727
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|Any CPU.ActiveCfg = Debug|x86
@@ -30,52 +30,44 @@ Global
3030
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|ARM.ActiveCfg = Debug|ARM
3131
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|ARM.Build.0 = Debug|ARM
3232
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|ARM.Deploy.0 = Debug|ARM
33-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
34-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|Mixed Platforms.Build.0 = Debug|x86
35-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Debug|Mixed Platforms.Deploy.0 = Debug|x86
3633
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Any CPU.ActiveCfg = Release|x86
3734
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Any CPU.Build.0 = Release|x86
3835
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Any CPU.Deploy.0 = Release|x86
3936
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|ARM.ActiveCfg = Release|ARM
4037
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|ARM.Build.0 = Release|ARM
4138
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|ARM.Deploy.0 = Release|ARM
42-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Mixed Platforms.ActiveCfg = Release|x86
43-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Mixed Platforms.Build.0 = Release|x86
44-
{D8DE13B0-238A-4B1F-8B05-2A54E612E8E8}.Release|Mixed Platforms.Deploy.0 = Release|x86
4539
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
4640
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|Any CPU.Build.0 = Debug|Any CPU
4741
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|ARM.ActiveCfg = Debug|Any CPU
4842
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|ARM.Build.0 = Debug|Any CPU
49-
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
50-
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
5143
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|Any CPU.ActiveCfg = Release|Any CPU
5244
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|Any CPU.Build.0 = Release|Any CPU
5345
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|ARM.ActiveCfg = Release|Any CPU
5446
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|ARM.Build.0 = Release|Any CPU
55-
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
56-
{4CB49AFB-6508-4AE9-A7A8-CBAEE81C51F7}.Release|Mixed Platforms.Build.0 = Release|Any CPU
5747
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
5848
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|Any CPU.Build.0 = Debug|Any CPU
5949
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|ARM.ActiveCfg = Debug|Any CPU
6050
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|ARM.Build.0 = Debug|Any CPU
61-
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
62-
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
6351
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|Any CPU.ActiveCfg = Release|Any CPU
6452
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|Any CPU.Build.0 = Release|Any CPU
6553
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|ARM.ActiveCfg = Release|Any CPU
6654
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|ARM.Build.0 = Release|Any CPU
67-
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
68-
{A2CF2916-F998-4C62-9743-11A7466FE57C}.Release|Mixed Platforms.Build.0 = Release|Any CPU
6955
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
7056
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Any CPU.Build.0 = Debug|Any CPU
7157
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|ARM.ActiveCfg = Debug|Any CPU
72-
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
73-
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
58+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|ARM.Build.0 = Debug|Any CPU
7459
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Any CPU.ActiveCfg = Release|Any CPU
7560
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Any CPU.Build.0 = Release|Any CPU
7661
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|ARM.ActiveCfg = Release|Any CPU
77-
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
78-
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Mixed Platforms.Build.0 = Release|Any CPU
62+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|ARM.Build.0 = Release|Any CPU
63+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
64+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Debug|Any CPU.Build.0 = Debug|Any CPU
65+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Debug|ARM.ActiveCfg = Debug|Any CPU
66+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Debug|ARM.Build.0 = Debug|Any CPU
67+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Release|Any CPU.ActiveCfg = Release|Any CPU
68+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Release|Any CPU.Build.0 = Release|Any CPU
69+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Release|ARM.ActiveCfg = Release|Any CPU
70+
{858426D0-79AB-4928-95B9-A1E1725D31D3}.Release|ARM.Build.0 = Release|Any CPU
7971
EndGlobalSection
8072
GlobalSection(SolutionProperties) = preSolution
8173
HideSolutionNode = FALSE

source/Unity.WindowsPhone.sln

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MissingAssembly.WindowsPhon
1111
EndProject
1212
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity", "Unity\Src\Unity.csproj", "{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}"
1313
EndProject
14+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.RegistrationByConvention.WindowsPhone", "Unity\Src\RegistrationByConvention\Unity.RegistrationByConvention.WindowsPhone.csproj", "{119A2045-4C28-48FF-A828-D7F711B844F2}"
15+
EndProject
1416
Global
1517
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1618
Debug|Any CPU = Debug|Any CPU
@@ -80,15 +82,35 @@ Global
8082
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
8183
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Any CPU.Build.0 = Debug|Any CPU
8284
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|ARM.ActiveCfg = Debug|Any CPU
85+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|ARM.Build.0 = Debug|Any CPU
8386
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
8487
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
8588
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|x86.ActiveCfg = Debug|Any CPU
89+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Debug|x86.Build.0 = Debug|Any CPU
8690
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Any CPU.ActiveCfg = Release|Any CPU
8791
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Any CPU.Build.0 = Release|Any CPU
8892
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|ARM.ActiveCfg = Release|Any CPU
93+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|ARM.Build.0 = Release|Any CPU
8994
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
9095
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|Mixed Platforms.Build.0 = Release|Any CPU
9196
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|x86.ActiveCfg = Release|Any CPU
97+
{EE1F752C-1FAB-41AD-AD63-857D0E62AB6B}.Release|x86.Build.0 = Release|Any CPU
98+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
99+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|Any CPU.Build.0 = Debug|Any CPU
100+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|ARM.ActiveCfg = Debug|Any CPU
101+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|ARM.Build.0 = Debug|Any CPU
102+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
103+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
104+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|x86.ActiveCfg = Debug|Any CPU
105+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Debug|x86.Build.0 = Debug|Any CPU
106+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|Any CPU.ActiveCfg = Release|Any CPU
107+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|Any CPU.Build.0 = Release|Any CPU
108+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|ARM.ActiveCfg = Release|Any CPU
109+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|ARM.Build.0 = Release|Any CPU
110+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
111+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|Mixed Platforms.Build.0 = Release|Any CPU
112+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|x86.ActiveCfg = Release|x86
113+
{119A2045-4C28-48FF-A828-D7F711B844F2}.Release|x86.Build.0 = Release|x86
92114
EndGlobalSection
93115
GlobalSection(SolutionProperties) = preSolution
94116
HideSolutionNode = FALSE

source/Unity.sln

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.WebApi", "Unity.WebAp
5252
EndProject
5353
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.WebIntegration.Tests", "Unity\Tests\Unity.WebIntegration.Tests\Unity.WebIntegration.Tests.csproj", "{60FBCE14-8B46-468A-9C67-3F7445B37455}"
5454
EndProject
55+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.RegistrationByConvention", "Unity\Src\RegistrationByConvention\Unity.RegistrationByConvention.csproj", "{10CFF71B-A9D4-44D2-B5CB-B363E5E15976}"
56+
EndProject
5557
Global
5658
GlobalSection(SolutionConfigurationPlatforms) = preSolution
5759
Debug|Any CPU = Debug|Any CPU
@@ -126,6 +128,10 @@ Global
126128
{60FBCE14-8B46-468A-9C67-3F7445B37455}.Debug|Any CPU.Build.0 = Debug|Any CPU
127129
{60FBCE14-8B46-468A-9C67-3F7445B37455}.Release|Any CPU.ActiveCfg = Release|Any CPU
128130
{60FBCE14-8B46-468A-9C67-3F7445B37455}.Release|Any CPU.Build.0 = Release|Any CPU
131+
{10CFF71B-A9D4-44D2-B5CB-B363E5E15976}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
132+
{10CFF71B-A9D4-44D2-B5CB-B363E5E15976}.Debug|Any CPU.Build.0 = Debug|Any CPU
133+
{10CFF71B-A9D4-44D2-B5CB-B363E5E15976}.Release|Any CPU.ActiveCfg = Release|Any CPU
134+
{10CFF71B-A9D4-44D2-B5CB-B363E5E15976}.Release|Any CPU.Build.0 = Release|Any CPU
129135
EndGlobalSection
130136
GlobalSection(SolutionProperties) = preSolution
131137
HideSolutionNode = FALSE
@@ -137,6 +143,7 @@ Global
137143
{80F7399F-B221-465F-97C9-4B9FC0E2F67F} = {25EB396B-2527-4B42-8037-C364A038856B}
138144
{1FB1A6FE-1898-4E72-906E-1C160AB50F2F} = {25EB396B-2527-4B42-8037-C364A038856B}
139145
{E6A503F3-1B1D-4008-98EE-7EACA66DFB05} = {25EB396B-2527-4B42-8037-C364A038856B}
146+
{10CFF71B-A9D4-44D2-B5CB-B363E5E15976} = {25EB396B-2527-4B42-8037-C364A038856B}
140147
{E979857E-CDE5-4D36-9AE8-8FFF4F75AE89} = {36634874-C16A-4F0C-9717-51C1D3D1FEBE}
141148
{25E09D23-F407-4A61-8446-E5FBD6F689B8} = {36634874-C16A-4F0C-9717-51C1D3D1FEBE}
142149
{3FC0084C-6077-4F87-8A51-2F755C83D7C8} = {36634874-C16A-4F0C-9717-51C1D3D1FEBE}

source/Unity/Src/Properties/Resources.Designer.cs

Lines changed: 0 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

source/Unity/Src/Properties/Resources.resx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -168,12 +168,6 @@
168168
<data name="ConstructorParameterResolutionFailed" xml:space="preserve">
169169
<value>The parameter {0} could not be resolved when attempting to call constructor {1}.</value>
170170
</data>
171-
<data name="DuplicateTypeMappingException" xml:space="preserve">
172-
<value>An attempt to override an existing mapping was detected for type {1} with name "{0}", currently mapped to type {2}, to type {3}.</value>
173-
</data>
174-
<data name="ExceptionNullAssembly" xml:space="preserve">
175-
<value>The set of assemblies contains a null element.</value>
176-
</data>
177171
<data name="ExceptionNullParameterValue" xml:space="preserve">
178172
<value>Parameter type inference does not work for null values. Indicate the parameter type explicitly using a properly configured instance of the InjectionParameter or InjectionParameter&lt;T&gt; classes.</value>
179173
</data>
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information.
2+
3+
using System;
4+
using System.Diagnostics.CodeAnalysis;
5+
using System.Runtime.Serialization;
6+
7+
namespace Microsoft.Practices.Unity
8+
{
9+
[SuppressMessage("Microsoft.Usage", "CA2240:ImplementISerializableCorrectly", Justification = "Implementing serialization with the new transparent approach")]
10+
[Serializable]
11+
partial class DuplicateTypeMappingException
12+
{
13+
#region Serialization Support
14+
15+
partial void RegisterSerializationHandler()
16+
{
17+
this.SerializeObjectState += (s, e) =>
18+
{
19+
e.AddSerializedState(new DuplicateTypeMappingExceptionSerializationData(this.name, this.mappedFromType, this.currentMappedToType, this.newMappedToType));
20+
};
21+
}
22+
23+
[Serializable]
24+
private struct DuplicateTypeMappingExceptionSerializationData : ISafeSerializationData
25+
{
26+
private string name;
27+
private string mappedFromType;
28+
private string currentMappedToType;
29+
private string newMappedToType;
30+
31+
public DuplicateTypeMappingExceptionSerializationData(string name, string mappedFromType, string currentMappedToType, string newMappedToType)
32+
{
33+
this.name = name;
34+
this.mappedFromType = mappedFromType;
35+
this.currentMappedToType = currentMappedToType;
36+
this.newMappedToType = newMappedToType;
37+
}
38+
39+
public void CompleteDeserialization(object deserialized)
40+
{
41+
var exception = (DuplicateTypeMappingException)deserialized;
42+
exception.name = this.name;
43+
exception.mappedFromType = this.mappedFromType;
44+
exception.currentMappedToType = this.currentMappedToType;
45+
exception.newMappedToType = this.newMappedToType;
46+
}
47+
}
48+
49+
#endregion
50+
}
51+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information.
2+
3+
using System;
4+
using System.Reflection;
5+
using System.Security;
6+
7+
[assembly: CLSCompliant(true)]
8+
[assembly: AssemblyProduct("Microsoft Unity Application Block")]
9+
[assembly: AssemblyCompany("Microsoft Corporation")]
10+
11+
#if !WINDOWS_PHONE && !NETFX_CORE
12+
[assembly: AllowPartiallyTrustedCallers]
13+
#endif
14+
15+
#if DEBUG
16+
[assembly: AssemblyConfiguration("Debug")]
17+
#else
18+
[assembly: AssemblyConfiguration("Release")]
19+
#endif
20+
[assembly: AssemblyCopyright("Copyright © 2011,2012 Microsoft Corporation.")]
21+
[assembly: AssemblyTrademark("")]
22+
[assembly: AssemblyCulture("")]
23+
24+
[assembly: AssemblyVersion("3.0.0.0")]
25+
[assembly: AssemblyFileVersion("3.0.1311.0")]
26+
[assembly: AssemblyInformationalVersion("3.0.1311-prerelease")]
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information.
2+
3+
using System.Reflection;
4+
using System.Resources;
5+
using System.Runtime.InteropServices;
6+
// General Information about an assembly is controlled through the following
7+
// set of attributes. Change these attribute values to modify the information
8+
// associated with an assembly.
9+
[assembly: AssemblyTitle("")]
10+
[assembly: AssemblyDescription("")]
11+
12+
// Setting ComVisible to false makes the types in this assembly not visible
13+
// to COM components. If you need to access a type in this assembly from
14+
// COM, set the ComVisible attribute to true on that type.
15+
[assembly: ComVisible(false)]
16+
17+
[assembly: NeutralResourcesLanguage("en")]

0 commit comments

Comments
 (0)