From 8faaf64c7c1c14cc91f609570baf94506926e84c Mon Sep 17 00:00:00 2001 From: Steve Bohlen Date: Mon, 7 Jan 2013 19:25:04 -0500 Subject: [PATCH] SPRNET-1536 add SPRNET-CODECONFIG migration sample to reinforce the docs --- .../Spring.CodeConfig.Migration.2008.sln | 32 +++++ .../Spring.CodeConfig.Migration.2010.sln | 32 +++++ .../src/Primes/ConsoleReport.cs | 40 ++++++ .../src/Primes/IOutputFormatter.cs | 9 ++ .../src/Primes/IPrimeGenerator.cs | 8 ++ .../src/Primes/LinqPrimeGenerator.cs | 45 +++++++ .../src/Primes/OutputFormatter.cs | 50 ++++++++ .../src/Primes/PrimeEvaluationEngine.cs | 28 +++++ .../src/Primes/PrimeGenerator.cs | 37 ++++++ .../src/Primes/Primes.2008.csproj | 69 +++++++++++ .../src/Primes/Primes.2010.csproj | 70 +++++++++++ .../src/Primes/Properties/AssemblyInfo.cs | 36 ++++++ .../src/SpringApp/App.config | 6 + .../src/SpringApp/PrimesConfiguration.cs | 32 +++++ .../src/SpringApp/Program.cs | 47 ++++++++ .../src/SpringApp/Properties/AssemblyInfo.cs | 36 ++++++ .../src/SpringApp/SpringApp.2008.csproj | 113 +++++++++++++++++ .../src/SpringApp/SpringApp.2010.csproj | 114 ++++++++++++++++++ .../src/SpringApp/application-context.xml | 19 +++ .../Primes.Tests/Primes.Tests.2008.csproj | 105 ++++++++++++++++ .../Primes.Tests/Primes.Tests.2010.csproj | 106 ++++++++++++++++ .../When_Candidate_Is_Even.cs | 17 +++ .../When_Candidate_Is_Negative.cs | 17 +++ .../EvaluationEngine/When_Candidate_Is_One.cs | 17 +++ .../EvaluationEngine/When_Candidate_Is_Two.cs | 17 +++ .../When_Candidate_Is_Zero.cs | 17 +++ .../When_Constructing_PrimeEvaluator.cs | 17 +++ .../When_Number_is_evaluated.cs | 29 +++++ .../Formatter/When_Constructing_Formatter.cs | 17 +++ .../Formatter/When_Formatting_Output.cs | 63 ++++++++++ .../When_Calculating_Range_Of_Primes.cs | 19 +++ .../Generator/When_Constructing_Generator.cs | 17 +++ .../When_No_Primes_Found_In_Range.cs | 17 +++ .../Primes.Tests/Properties/AssemblyInfo.cs | 36 ++++++ 34 files changed, 1334 insertions(+) create mode 100644 examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2008.sln create mode 100644 examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2010.sln create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/ConsoleReport.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/IOutputFormatter.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/IPrimeGenerator.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/LinqPrimeGenerator.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/OutputFormatter.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeEvaluationEngine.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeGenerator.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2008.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2010.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/Primes/Properties/AssemblyInfo.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/App.config create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/PrimesConfiguration.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Program.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Properties/AssemblyInfo.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2008.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2010.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/application-context.xml create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2008.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2010.csproj create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Even.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Negative.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_One.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Two.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Zero.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Constructing_PrimeEvaluator.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Number_is_evaluated.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Constructing_Formatter.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Formatting_Output.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Calculating_Range_Of_Primes.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Constructing_Generator.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_No_Primes_Found_In_Range.cs create mode 100644 examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Properties/AssemblyInfo.cs diff --git a/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2008.sln b/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2008.sln new file mode 100644 index 00000000..b6a039db --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2008.sln @@ -0,0 +1,32 @@ + +Microsoft Visual Studio Solution File, Format Version 10.00 +# Visual Studio 2008 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Primes", "src\Primes\Primes.2008.csproj", "{865E1A8E-88F3-48D8-869F-B584C5A36740}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Primes.Tests", "test\Primes.Tests\Primes.Tests.2008.csproj", "{32476935-0852-4A11-B938-4D202D8B4454}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpringApp", "src\SpringApp\SpringApp.2008.csproj", "{08A8AC17-E5E1-48FC-9958-76ECA8C08D71}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Debug|Any CPU.Build.0 = Debug|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Release|Any CPU.ActiveCfg = Release|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Release|Any CPU.Build.0 = Release|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Debug|Any CPU.Build.0 = Debug|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Release|Any CPU.ActiveCfg = Release|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Release|Any CPU.Build.0 = Release|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Debug|Any CPU.Build.0 = Debug|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Release|Any CPU.ActiveCfg = Release|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2010.sln b/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2010.sln new file mode 100644 index 00000000..7b6c1bda --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/Spring.CodeConfig.Migration.2010.sln @@ -0,0 +1,32 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Visual Studio 2010 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Primes", "src\Primes\Primes.2010.csproj", "{865E1A8E-88F3-48D8-869F-B584C5A36740}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Primes.Tests", "test\Primes.Tests\Primes.Tests.2010.csproj", "{32476935-0852-4A11-B938-4D202D8B4454}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpringApp", "src\SpringApp\SpringApp.2010.csproj", "{08A8AC17-E5E1-48FC-9958-76ECA8C08D71}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Debug|Any CPU.Build.0 = Debug|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Release|Any CPU.ActiveCfg = Release|Any CPU + {865E1A8E-88F3-48D8-869F-B584C5A36740}.Release|Any CPU.Build.0 = Release|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Debug|Any CPU.Build.0 = Debug|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Release|Any CPU.ActiveCfg = Release|Any CPU + {32476935-0852-4A11-B938-4D202D8B4454}.Release|Any CPU.Build.0 = Release|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Debug|Any CPU.Build.0 = Debug|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Release|Any CPU.ActiveCfg = Release|Any CPU + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/ConsoleReport.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/ConsoleReport.cs new file mode 100644 index 00000000..31b7132c --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/ConsoleReport.cs @@ -0,0 +1,40 @@ +using System; +using System.Collections.Generic; + +namespace Primes +{ + public class ConsoleReport + { + private IOutputFormatter _outputFormatter; + + private IPrimeGenerator _primeGenerator; + + private int _maxNumber; + + public ConsoleReport(IOutputFormatter outputFormatter, IPrimeGenerator primeGenerator) + { + _outputFormatter = outputFormatter; + _primeGenerator = primeGenerator; + } + public IOutputFormatter OutputFormatter + { + set { _outputFormatter = value; } + } + + public int MaxNumber + { + get { return _maxNumber; } + set { _maxNumber = value; } + } + + public void Write() + { + IList results = _outputFormatter.Format(_primeGenerator.GeneratePrimesUpTo(_maxNumber)); + + foreach (string item in results) + { + Console.WriteLine(item); + } + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IOutputFormatter.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IOutputFormatter.cs new file mode 100644 index 00000000..589681a3 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IOutputFormatter.cs @@ -0,0 +1,9 @@ +using System.Collections.Generic; + +namespace Primes +{ + public interface IOutputFormatter + { + IList Format(string input); + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IPrimeGenerator.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IPrimeGenerator.cs new file mode 100644 index 00000000..cbb0aae8 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/IPrimeGenerator.cs @@ -0,0 +1,8 @@ +namespace Primes +{ + public interface IPrimeGenerator + { + string GeneratePrimesUpTo(int max); + } + +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/LinqPrimeGenerator.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/LinqPrimeGenerator.cs new file mode 100644 index 00000000..8640747c --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/LinqPrimeGenerator.cs @@ -0,0 +1,45 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace Primes +{ + public class LinqPrimeGenerator : IPrimeGenerator + { + #region IPrimeGenerator Members + + public string GeneratePrimesUpTo(int maxNumber) + { + + var sb = new StringBuilder(); + + if (maxNumber <= 0) + { + return sb.ToString(); + } + + Func> primeNumbers = max => + from i in Enumerable.Range(2, max - 1) + where Enumerable.Range(2, i - 2).All(j => i%j != 0) + select i; + + IEnumerable result = primeNumbers(maxNumber); + + foreach (int i in result) + { + sb.Append(i.ToString()); + sb.Append(","); + } + + string theString = sb.ToString(); + + if (theString.Contains(",")) + theString = theString.Remove(theString.LastIndexOf(",")); + + return theString; + } + + #endregion + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/OutputFormatter.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/OutputFormatter.cs new file mode 100644 index 00000000..062086d8 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/OutputFormatter.cs @@ -0,0 +1,50 @@ +using System.Collections.Generic; +using System.Text; + +namespace Primes +{ + public class OutputFormatter : IOutputFormatter + { + public IList Format(string input) + { + string[] elements = input.Split(",".ToCharArray()); + + IList result = new List(); + + int lineCount = 0; + + for (int i = 0; i < elements.Length; i += 5) + { + + var sb = new StringBuilder(); + + for (int j = i; j < i + 5; j++) + { + sb.Append(elements[j]); + sb.Append(","); + if (j == elements.Length - 1) + break; + } + + string theString = sb.ToString(); + + if (theString.EndsWith(",")) + theString = theString.Substring(0, theString.Length - 1); + + if (lineCount > 0 && (lineCount % 10 == 0)) + result.Add("Count: " + i); + + lineCount += 1; + + result.Add(theString); + } + + + return result; + } + + + + + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeEvaluationEngine.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeEvaluationEngine.cs new file mode 100644 index 00000000..a2148f34 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeEvaluationEngine.cs @@ -0,0 +1,28 @@ +using System; + +namespace Primes +{ + public class PrimeEvaluationEngine + { + public bool IsPrime(int candidate) + { + if (candidate <= 1) + return false; + + if (candidate == 2) + return true; + + if (candidate % 2 == 0) + return false; + + for (int i = 3; i < Math.Sqrt(candidate); i += 2) + { + if (candidate % i == 0) + return false; + } + + + return true; + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeGenerator.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeGenerator.cs new file mode 100644 index 00000000..396d695a --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/PrimeGenerator.cs @@ -0,0 +1,37 @@ +using System.Text; + +namespace Primes +{ + public class PrimeGenerator : IPrimeGenerator + { + private PrimeEvaluationEngine _primeEvaluationEngine; + + public string GeneratePrimesUpTo(int max) + { + + var sb = new StringBuilder(); + + for (int i = 0; i < max; i++) + { + if (_primeEvaluationEngine.IsPrime(i)) + { + sb.Append(i.ToString()); + sb.Append(","); + } + } + + string theString = sb.ToString(); + + if (theString.Contains(",")) + theString = theString.Remove(theString.LastIndexOf(",")); + + return theString; + } + + + public PrimeGenerator(PrimeEvaluationEngine primeEvaluationEngine) + { + _primeEvaluationEngine = primeEvaluationEngine; + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2008.csproj b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2008.csproj new file mode 100644 index 00000000..510f82cf --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2008.csproj @@ -0,0 +1,69 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Library + Properties + Primes + Primes + v3.5 + 512 + + + 3.5 + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + 3.5 + + + 3.5 + + + 3.5 + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2010.csproj b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2010.csproj new file mode 100644 index 00000000..b191f060 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Primes.2010.csproj @@ -0,0 +1,70 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Library + Properties + Primes + Primes + v4.0 + 512 + + + 3.5 + + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + 3.5 + + + 3.5 + + + 3.5 + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Properties/AssemblyInfo.cs b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..af385635 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/Primes/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Primes")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Primes")] +[assembly: AssemblyCopyright("Copyright © 2009")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("62a3a729-c953-47fb-95a0-6e66956cbe94")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/App.config b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/App.config new file mode 100644 index 00000000..2e501436 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/App.config @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/PrimesConfiguration.cs b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/PrimesConfiguration.cs new file mode 100644 index 00000000..db932a8e --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/PrimesConfiguration.cs @@ -0,0 +1,32 @@ +using System; +using System.Configuration; +using Primes; +using Spring.Context.Attributes; + +namespace SpringApp +{ + [Configuration] + public class PrimesConfiguration + { + [ObjectDef] + public virtual ConsoleReport ConsoleReport() + { + ConsoleReport report = new ConsoleReport(OutputFormatter(), PrimeGenerator()); + + report.MaxNumber = Convert.ToInt32(ConfigurationManager.AppSettings.Get("MaximumNumber")); + return report; + } + + [ObjectDef] + public virtual IOutputFormatter OutputFormatter() + { + return new OutputFormatter(); + } + + [ObjectDef] + public virtual IPrimeGenerator PrimeGenerator() + { + return new PrimeGenerator(new PrimeEvaluationEngine()); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Program.cs b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Program.cs new file mode 100644 index 00000000..5cfe1cbd --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Program.cs @@ -0,0 +1,47 @@ +using System; +using System.Reflection; +using Primes; +using Spring.Context; +using Spring.Context.Attributes; +using Spring.Context.Support; +using Spring.Objects.Factory.Config; +using Spring.Objects.Factory.Support; +using System.Linq; + +namespace SpringApp +{ + class Program + { + static void Main(string[] args) + { + //uncomment this next line to to use XML to assemble the container + //IApplicationContext ctx = CreateContainerUsingXML(); + + //uncomment this next line to to use CodeConfig to assemble the container + IApplicationContext ctx = CreateContainerUsingCodeConfig(); + + ConsoleReport report = ctx["ConsoleReport"] as ConsoleReport; + report.Write(); + + ctx.Dispose(); + + Console.WriteLine("--- hit enter to exit --"); + Console.ReadLine(); + } + + + private static IApplicationContext CreateContainerUsingXML() + { + return new XmlApplicationContext("application-context.xml"); + } + + private static IApplicationContext CreateContainerUsingCodeConfig() + { + CodeConfigApplicationContext ctx = new CodeConfigApplicationContext(); + ctx.ScanAllAssemblies(); + ctx.Refresh(); + return ctx; + } + + } +} diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Properties/AssemblyInfo.cs b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..0985f054 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("SpringApp")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("SpringApp")] +[assembly: AssemblyCopyright("Copyright © 2009")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("d8ce7151-6f8b-4c3b-a0f5-ec8606579384")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2008.csproj b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2008.csproj new file mode 100644 index 00000000..f6ea59c8 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2008.csproj @@ -0,0 +1,113 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71} + Exe + Properties + SpringApp + SpringApp + v3.5 + 512 + + + 3.5 + + publish\ + true + Disk + false + Foreground + 7 + Days + false + false + true + 0 + 1.0.0.%2a + false + false + true + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + False + ..\..\..\..\lib\net\3.5\Common.Logging.dll + + + False + ..\..\..\..\..\bin\net\3.5\debug\Spring.Core.dll + + + + + 3.5 + + + + + + + + + + + Always + Designer + + + + + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Primes + + + + + False + .NET Framework 3.5 SP1 Client Profile + false + + + False + .NET Framework 3.5 SP1 + true + + + False + Windows Installer 3.1 + true + + + + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2010.csproj b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2010.csproj new file mode 100644 index 00000000..886fbe13 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/SpringApp.2010.csproj @@ -0,0 +1,114 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {08A8AC17-E5E1-48FC-9958-76ECA8C08D71} + Exe + Properties + SpringApp + SpringApp + v4.0 + 512 + + + 3.5 + + publish\ + true + Disk + false + Foreground + 7 + Days + false + false + true + 0 + 1.0.0.%2a + false + false + true + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + False + ..\..\..\..\..\bin\net\3.5\debug\Common.Logging.dll + + + False + ..\..\..\..\..\bin\net\3.5\debug\Spring.Core.dll + + + + + 3.5 + + + + + + + + + + + Always + Designer + + + + + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Primes + + + + + False + .NET Framework 3.5 SP1 Client Profile + false + + + False + .NET Framework 3.5 SP1 + true + + + False + Windows Installer 3.1 + true + + + + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/application-context.xml b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/application-context.xml new file mode 100644 index 00000000..09ef5dcd --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/src/SpringApp/application-context.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2008.csproj b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2008.csproj new file mode 100644 index 00000000..b12d4a36 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2008.csproj @@ -0,0 +1,105 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {32476935-0852-4A11-B938-4D202D8B4454} + Library + Properties + Primes + Primes.Tests + v3.5 + 512 + + + 3.5 + + publish\ + true + Disk + false + Foreground + 7 + Days + false + false + true + 0 + 1.0.0.%2a + false + false + true + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + False + ..\..\..\..\..\lib\Net\2.0\nunit.framework.dll + + + + + + + + + + + + + + + + + + + + + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Primes + + + + + False + .NET Framework 3.5 SP1 Client Profile + false + + + False + .NET Framework 3.5 SP1 + true + + + False + Windows Installer 3.1 + true + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2010.csproj b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2010.csproj new file mode 100644 index 00000000..1dcb61db --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes.Tests.2010.csproj @@ -0,0 +1,106 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {32476935-0852-4A11-B938-4D202D8B4454} + Library + Properties + Primes + Primes.Tests + v4.0 + 512 + + + 3.5 + + publish\ + true + Disk + false + Foreground + 7 + Days + false + false + true + 0 + 1.0.0.%2a + false + false + true + + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + False + ..\..\..\..\..\lib\Net\3.5\nunit.framework.dll + + + + + + + + + + + + + + + + + + + + + {865E1A8E-88F3-48D8-869F-B584C5A36740} + Primes + + + + + False + .NET Framework 3.5 SP1 Client Profile + false + + + False + .NET Framework 3.5 SP1 + true + + + False + Windows Installer 3.1 + true + + + + + \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Even.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Even.cs new file mode 100644 index 00000000..3b098e75 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Even.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Candidate_Is_Even + { + [Test] + public void Can_Reject_Candidate() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsFalse(primeEvaluationEngine.IsPrime(8)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Negative.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Negative.cs new file mode 100644 index 00000000..a88c01dd --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Negative.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Candidate_Is_Negative + { + [Test] + public void Can_Reject_Candidate() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsFalse(primeEvaluationEngine.IsPrime(-1)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_One.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_One.cs new file mode 100644 index 00000000..0264b2fe --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_One.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Candidate_Is_One + { + [Test] + public void Can_Reject_Candidate() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsFalse(primeEvaluationEngine.IsPrime(1)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Two.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Two.cs new file mode 100644 index 00000000..61886d43 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Two.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Candidate_Is_Two + { + [Test] + public void Can_Accept_Candidate() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsTrue(primeEvaluationEngine.IsPrime(2)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Zero.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Zero.cs new file mode 100644 index 00000000..a77e82bc --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Candidate_Is_Zero.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Candidate_Is_Zero + { + [Test] + public void Can_Reject_Candidate() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsFalse(primeEvaluationEngine.IsPrime(0)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Constructing_PrimeEvaluator.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Constructing_PrimeEvaluator.cs new file mode 100644 index 00000000..c470f5b6 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Constructing_PrimeEvaluator.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Constructing_PrimeEvaluator + { + [Test] + public void Can_Create_Instance() + { + var primeNumberEngine = new PrimeEvaluationEngine(); + + Assert.IsNotNull(primeNumberEngine); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Number_is_evaluated.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Number_is_evaluated.cs new file mode 100644 index 00000000..41c8e3bc --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/EvaluationEngine/When_Number_is_evaluated.cs @@ -0,0 +1,29 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.EvaluationEngine +{ + [TestFixture] + public class When_Number_is_evaluated + { + private const int NON_PRIME_TEST_VALUE = 35; + + private const int PRIME_TEST_VALUE = 17; + + [Test] + public void Can_Accept_Candidate_When_Prime() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsTrue(primeEvaluationEngine.IsPrime(PRIME_TEST_VALUE)); + } + + [Test] + public void Can_Reject_Candidate_When_Not_Prime() + { + var primeEvaluationEngine = new PrimeEvaluationEngine(); + + Assert.IsFalse(primeEvaluationEngine.IsPrime(NON_PRIME_TEST_VALUE)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Constructing_Formatter.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Constructing_Formatter.cs new file mode 100644 index 00000000..28966e91 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Constructing_Formatter.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.Formatter +{ + [TestFixture] + public class When_Constructing_Formatter + { + [Test] + public void Can_Create_Instance() + { + var outputFormatter = new OutputFormatter(); + + Assert.IsNotNull(outputFormatter); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Formatting_Output.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Formatting_Output.cs new file mode 100644 index 00000000..9878cc5e --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Formatter/When_Formatting_Output.cs @@ -0,0 +1,63 @@ +using System.Collections.Generic; +using NUnit.Framework; +using Primes; + +namespace Tests.Formatter +{ + [TestFixture] + public class When_Formatting_Output + { + private string _generatedPrimes; + + + [TestFixtureSetUp] + public void _TestFixtureSetUp() + { + _generatedPrimes = new PrimeGenerator(new PrimeEvaluationEngine()).GeneratePrimesUpTo(20); + } + + + [Test] + public void Collection_of_Output_Lines_is_Returned() + { + var outputFormatter = new OutputFormatter(); + + IList formattedOutput = outputFormatter.Format(_generatedPrimes); + + Assert.IsAssignableFrom(typeof (List), formattedOutput); + } + + + [Test] + public void Each_Output_Line_Contains_No_More_Than_Five_Items() + { + var outputFormatter = new OutputFormatter(); + + IList formattedOutput = outputFormatter.Format(_generatedPrimes); + + string[] splitPrimes; + + foreach (string item in formattedOutput) + { + splitPrimes = item.Split(",".ToCharArray()); + + Assert.LessOrEqual(splitPrimes.Length, 5); + } + } + + [Test] + public void Every_Tenth_Line_Contains_Count() + { + var generatedPrimes = new PrimeGenerator(new PrimeEvaluationEngine()).GeneratePrimesUpTo(2000); + + var outputFormatter = new OutputFormatter(); + + IList formattedOutput = outputFormatter.Format(generatedPrimes); + + for (int i = 10; i < formattedOutput.Count; i += 11) + { + Assert.IsTrue(formattedOutput[i].Contains("Count:")); + } + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Calculating_Range_Of_Primes.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Calculating_Range_Of_Primes.cs new file mode 100644 index 00000000..268000ed --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Calculating_Range_Of_Primes.cs @@ -0,0 +1,19 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.Generator +{ + [TestFixture] + public class When_Calculating_Range_Of_Primes + { + [Test] + public void Can_Return_Values_Comma_Delimited() + { + var primeGenerator = new PrimeGenerator(new PrimeEvaluationEngine()); + + string actual = primeGenerator.GeneratePrimesUpTo(10); + + Assert.AreEqual("2,3,5,7,9", actual); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Constructing_Generator.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Constructing_Generator.cs new file mode 100644 index 00000000..14d28f77 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_Constructing_Generator.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.Generator +{ + [TestFixture] + public class When_Constructing_Generator + { + [Test] + public void Can_Create_Instance() + { + var generator = new PrimeGenerator(new PrimeEvaluationEngine()); + + Assert.IsNotNull(generator); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_No_Primes_Found_In_Range.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_No_Primes_Found_In_Range.cs new file mode 100644 index 00000000..f442a65b --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Primes/Generator/When_No_Primes_Found_In_Range.cs @@ -0,0 +1,17 @@ +using NUnit.Framework; +using Primes; + +namespace Tests.Generator +{ + [TestFixture] + public class When_No_Primes_Found_In_Range + { + [Test] + public void Can_Return_Empty_String() + { + var primeGenerator = new PrimeGenerator(new PrimeEvaluationEngine()); + + Assert.AreEqual(string.Empty, primeGenerator.GeneratePrimesUpTo(0)); + } + } +} \ No newline at end of file diff --git a/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Properties/AssemblyInfo.cs b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..17756b33 --- /dev/null +++ b/examples/Spring/Spring.CodeConfig.Migration/test/Primes.Tests/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Primes.Tests")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Primes.Tests")] +[assembly: AssemblyCopyright("Copyright © 2009")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("ce7b9b23-5d7c-4f4b-8d7c-885050ef836a")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")]