Add Design Patterns
This commit is contained in:
9
DecoratorLib/Component.cs
Normal file
9
DecoratorLib/Component.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace DecoratorLib;
|
||||
|
||||
public class Component : IComponent
|
||||
{
|
||||
public void Log()
|
||||
{
|
||||
Console.WriteLine("Component Log");
|
||||
}
|
||||
}
|
||||
9
DecoratorLib/DecoratorLib.csproj
Normal file
9
DecoratorLib/DecoratorLib.csproj
Normal file
@@ -0,0 +1,9 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
</Project>
|
||||
6
DecoratorLib/IComponent.cs
Normal file
6
DecoratorLib/IComponent.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace DecoratorLib;
|
||||
|
||||
public interface IComponent
|
||||
{
|
||||
void Log();
|
||||
}
|
||||
Reference in New Issue
Block a user