Skip to content

Commit

Permalink
refs #50
Browse files Browse the repository at this point in the history
  • Loading branch information
lsoft committed Dec 28, 2021
1 parent f1267c7 commit fad3594
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 58 deletions.
5 changes: 4 additions & 1 deletion DpdtInject.Injector/Src/CustomScope/CustomScopeObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace DpdtInject.Injector.Src.CustomScope
{
public sealed class CustomScopeObject : ICustomScopeObject, IDisposable
public sealed class CustomScopeObject : IDisposable
{
private readonly FlexibleSizeObjectContainer _dependencyContainer;

Expand All @@ -14,6 +14,9 @@ public CustomScopeObject(int estimatedTypeCount)
);
}

/// <summary>
/// Internal use only. Please DO NOT use this method.
/// </summary>
public object GetOrAdd(
Guid uniqueId,
Func<object> objectProvider
Expand Down
12 changes: 0 additions & 12 deletions DpdtInject.Injector/Src/CustomScope/ICustomScopeObject.cs

This file was deleted.

45 changes: 0 additions & 45 deletions DpdtInject.Injector/Src/Reinvented/FlexibleSizeObjectContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,51 +67,6 @@ Func<object> o
}


//public bool TryGetObject(
// Type requestedType,
// [NotNullWhen(true)] out object? result
// )
//{
// var index = CalculateIndex(requestedType);
// var list = _table[index];

// for (var i = 0; i < list.Count; i++)
// {
// var item = list[i];

// if (item.Type == requestedType)
// {
// result = item.Object;
// return true;
// }
// }

// result = null;
// return false;
//}

//public object? GetGetObject(Type requestedType)
//{
// var index = CalculateIndex(requestedType);
// var list = _table[index];

// for (var i = 0; i < list.Count; i++)
// {
// var item = list[i];

// if (item.Type == requestedType)
// {
// return item.Object;
// }
// }

// throw new DpdtException(
// DpdtExceptionTypeEnum.NoBindingAvailable,
// $"No bindings available for {requestedType.FullName}",
// requestedType.FullName!
// );
//}

public void Dispose()
{
var excps = new List<Exception>();
Expand Down

0 comments on commit fad3594

Please sign in to comment.