Some cosmetic changes; all methods in the StringBuilderHelper are now extension methods; added GarbagePolicy enumeration for StringBuilder helper methods; custom Semaphore is not internal in Windows builds to avoid ambiguous symbols
git-svn-id: file:///srv/devel/repo-conversion/nusu@263 d2e56fa2-650e-0410-a79f-9358c0239efd
This commit is contained in:
parent
1a05bf9d63
commit
07a9de6283
13 changed files with 495 additions and 103 deletions
|
|
@ -24,13 +24,13 @@ using System.Diagnostics;
|
|||
namespace Nuclex.Support {
|
||||
|
||||
/// <summary>Manages a globally shared instance of the given Type</summary>
|
||||
/// <typeparam name="SharedType">
|
||||
/// <typeparam name="TShared">
|
||||
/// Type of which a globally shared instance will be provided
|
||||
/// </typeparam>
|
||||
public static class Shared<SharedType> where SharedType : new() {
|
||||
public static class Shared<TShared> where TShared : new() {
|
||||
|
||||
/// <summary>Returns the global instance of the class</summary>
|
||||
public static SharedType Instance {
|
||||
public static TShared Instance {
|
||||
[DebuggerStepThrough]
|
||||
get {
|
||||
return instance;
|
||||
|
|
@ -38,7 +38,7 @@ namespace Nuclex.Support {
|
|||
}
|
||||
|
||||
/// <summary>Stored the globally shared instance</summary>
|
||||
private static readonly SharedType instance = new SharedType();
|
||||
private static readonly TShared instance = new TShared();
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue