fix(*): Make Factory static to enable not having to instantiate it everywhere

This commit is contained in:
Josh Creek
2021-08-30 11:06:11 +01:00
parent 5138cca9b0
commit 1813599e82
+2 -2
View File
@@ -8,7 +8,7 @@ namespace FileRepository
/// <summary> /// <summary>
/// A factory to enable consumers of this package to easily get a specific type of repository. /// A factory to enable consumers of this package to easily get a specific type of repository.
/// </summary> /// </summary>
public class Factory public static class Factory
{ {
/// <summary> /// <summary>
/// An enum to restrict users to only select valid repository types. /// An enum to restrict users to only select valid repository types.
@@ -46,7 +46,7 @@ namespace FileRepository
/// </summary> /// </summary>
/// <param name="repositoryType">The type of repository to initialise, based on the enum member.</param> /// <param name="repositoryType">The type of repository to initialise, based on the enum member.</param>
/// <returns>Returns an initialised repository.</returns> /// <returns>Returns an initialised repository.</returns>
public IFileRepository GetFileRepository(RepositoryType repositoryType) public static IFileRepository GetFileRepository(RepositoryType repositoryType)
{ {
switch (repositoryType) switch (repositoryType)
{ {