Archetektur angefangen
This commit is contained in:
23
ConsoleClient/ConsoleClient.csproj
Normal file
23
ConsoleClient/ConsoleClient.csproj
Normal file
@@ -0,0 +1,23 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Ninject" Version="3.3.4" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\KundenManagement.Contract\KundenManagement.Contract.csproj" />
|
||||
<ProjectReference Include="..\Mappings\Mappings.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="kunden.csv">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
29
ConsoleClient/Program.cs
Normal file
29
ConsoleClient/Program.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
|
||||
using KanSan.CrossCutting.DataClasses;
|
||||
using KanSan.DependencyInjection.Mappings;
|
||||
using KundenManagement.Contract;
|
||||
using Ninject;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace ConsoleClient
|
||||
{
|
||||
class Program
|
||||
{
|
||||
static void Main(string[] args)
|
||||
{
|
||||
StandardKernel kernel = new StandardKernel();
|
||||
new KernelInitializer().Initialize(kernel);
|
||||
|
||||
IKundeManager manager = kernel.Get<IKundeManager>();
|
||||
|
||||
List<Kunde> kunden = manager.GetAllKunden();
|
||||
|
||||
kunden.ForEach(a => Console.WriteLine(a.Vorname + " " + a.ID));
|
||||
|
||||
Console.WriteLine("Hello World!");
|
||||
|
||||
Console.ReadKey();
|
||||
}
|
||||
}
|
||||
}
|
||||
2
ConsoleClient/kunden.csv
Normal file
2
ConsoleClient/kunden.csv
Normal file
@@ -0,0 +1,2 @@
|
||||
1,Damian,Bodde
|
||||
2,Cynthia,Schreuder
|
||||
|
Reference in New Issue
Block a user