From 29fbf4b0ad3d6fa2d3d305c88d08424ce9ad0186 Mon Sep 17 00:00:00 2001 From: Simon Gockner Date: Wed, 12 Jun 2019 16:27:53 +0200 Subject: [PATCH] - add comments (#10) --- .../Installers/AssemblyInstaller.cs | 10 ++++++++++ LightweightIocContainer/Installers/FromAssembly.cs | 12 ++++++++++++ .../Interfaces/Installers/IAssemblyInstaller.cs | 7 +++++++ 3 files changed, 29 insertions(+) diff --git a/LightweightIocContainer/Installers/AssemblyInstaller.cs b/LightweightIocContainer/Installers/AssemblyInstaller.cs index 046621b..1d51cef 100644 --- a/LightweightIocContainer/Installers/AssemblyInstaller.cs +++ b/LightweightIocContainer/Installers/AssemblyInstaller.cs @@ -10,6 +10,9 @@ using LightweightIocContainer.Interfaces.Installers; namespace LightweightIocContainer.Installers { + /// + /// An that installs all s for its given + /// public class AssemblyInstaller : IAssemblyInstaller { public AssemblyInstaller(Assembly assembly) @@ -26,8 +29,15 @@ namespace LightweightIocContainer.Installers } } + /// + /// The s of the Assembly that this is installing + /// public List Installers { get; } + /// + /// Install the found s in the given + /// + /// The current public void Install(IIocContainer container) { foreach (var installer in Installers) diff --git a/LightweightIocContainer/Installers/FromAssembly.cs b/LightweightIocContainer/Installers/FromAssembly.cs index f900e17..4b09819 100644 --- a/LightweightIocContainer/Installers/FromAssembly.cs +++ b/LightweightIocContainer/Installers/FromAssembly.cs @@ -7,14 +7,26 @@ using LightweightIocContainer.Interfaces.Installers; namespace LightweightIocContainer.Installers { + /// + /// Helper class that supplies methods to find the wanted + /// public static class FromAssembly { + /// + /// Get an that installs from the calling the method + /// + /// A new with the calling public static IAssemblyInstaller This() { Assembly assembly = Assembly.GetCallingAssembly(); return new AssemblyInstaller(assembly); } + /// + /// Get an that installs from the given + /// + /// The given + /// A new with the given public static IAssemblyInstaller Instance(Assembly assembly) { return new AssemblyInstaller(assembly); diff --git a/LightweightIocContainer/Interfaces/Installers/IAssemblyInstaller.cs b/LightweightIocContainer/Interfaces/Installers/IAssemblyInstaller.cs index ca7791a..db0fe06 100644 --- a/LightweightIocContainer/Interfaces/Installers/IAssemblyInstaller.cs +++ b/LightweightIocContainer/Interfaces/Installers/IAssemblyInstaller.cs @@ -3,11 +3,18 @@ // // Copyright(c) 2019 SimonG. All Rights Reserved. using System.Collections.Generic; +using System.Reflection; namespace LightweightIocContainer.Interfaces.Installers { + /// + /// An that installs all s for its given + /// public interface IAssemblyInstaller : IIocInstaller { + /// + /// The s of the Assembly that this is installing + /// List Installers { get; } } } \ No newline at end of file