Compare commits
6
Commits
d1f940c44b
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d89acf612c | ||
|
|
2970815270 | ||
|
|
6757b2eaf6 | ||
|
|
e2de55e8ef | ||
|
|
d5da835b71 | ||
|
|
939366fbb4 |
@@ -975,7 +975,7 @@ namespace xCommons.Extensions
|
|||||||
result.Add(updateWith);
|
result.Add(updateWith);
|
||||||
|
|
||||||
//
|
//
|
||||||
return source;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -1013,7 +1013,7 @@ namespace xCommons.Extensions
|
|||||||
result.Add(updateWith);
|
result.Add(updateWith);
|
||||||
|
|
||||||
//
|
//
|
||||||
return source;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -1051,7 +1051,27 @@ namespace xCommons.Extensions
|
|||||||
result.Add(updateWith);
|
result.Add(updateWith);
|
||||||
|
|
||||||
//
|
//
|
||||||
return source;
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Converts an Enumerable to HashSet ...
|
||||||
|
/// </summary>
|
||||||
|
/// <typeparam name="T"></typeparam>
|
||||||
|
/// <param name="source"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static HashSet<T> ToHashSet<T>(this IEnumerable<T> source)
|
||||||
|
{
|
||||||
|
//
|
||||||
|
var result = new HashSet<T>();
|
||||||
|
if (source.IsNull())
|
||||||
|
{
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
result = [.. source];
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ using xCommons.Filters;
|
|||||||
using xCommons.Constants;
|
using xCommons.Constants;
|
||||||
using xCommons.Providers;
|
using xCommons.Providers;
|
||||||
using xCommons.Interfaces;
|
using xCommons.Interfaces;
|
||||||
|
using xExceptions.Constants;
|
||||||
using xCommons.Configurations;
|
using xCommons.Configurations;
|
||||||
using Microsoft.AspNetCore.Mvc;
|
using Microsoft.AspNetCore.Mvc;
|
||||||
using Microsoft.OpenApi.Models;
|
using Microsoft.OpenApi.Models;
|
||||||
@@ -14,7 +15,6 @@ using Swashbuckle.AspNetCore.SwaggerUI;
|
|||||||
using Swashbuckle.AspNetCore.SwaggerGen;
|
using Swashbuckle.AspNetCore.SwaggerGen;
|
||||||
using Microsoft.Extensions.Configuration;
|
using Microsoft.Extensions.Configuration;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using xExceptions.Constants;
|
|
||||||
|
|
||||||
namespace xCommons.Extensions
|
namespace xCommons.Extensions
|
||||||
{
|
{
|
||||||
@@ -33,6 +33,19 @@ namespace xCommons.Extensions
|
|||||||
return serviceProvider.GetService<T>();
|
return serviceProvider.GetService<T>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Inject Specific Registered Services from IServiceCollection
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="source"></param>
|
||||||
|
/// <typeparam name="T"></typeparam>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static IEnumerable<T> GetRegisteredServices<T>(this IServiceCollection source)
|
||||||
|
{
|
||||||
|
//
|
||||||
|
var serviceProvider = source.BuildServiceProvider();
|
||||||
|
return serviceProvider.GetServices<T>();
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Register App Configuration as a Service
|
/// Register App Configuration as a Service
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -63,6 +63,9 @@ namespace xCommons.Extensions {
|
|||||||
//
|
//
|
||||||
var idContainer = parts[0];
|
var idContainer = parts[0];
|
||||||
var messageContainer = parts[1];
|
var messageContainer = parts[1];
|
||||||
|
|
||||||
|
//
|
||||||
|
// TODO: Fix this ...
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user