Skip to content

Commit 640cddb

Browse files
committed
polishing
renamed BreakingChanges-1.2.txt to BreakingChanges-1.3.txt
1 parent 6610f5e commit 640cddb

File tree

2 files changed

+4
-11
lines changed

2 files changed

+4
-11
lines changed
File renamed without changes.

src/Spring/Spring.Core/Objects/Factory/Support/AbstractObjectFactory.cs

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1714,14 +1714,11 @@ public bool IsPrototype(string name)
17141714
}
17151715

17161716
/// <summary>
1717-
/// Does this object factory contain an object with the given name?
1717+
/// Does this object factory or one of its parent factories contain an object with the given name?
17181718
/// </summary>
17191719
/// <remarks>
1720-
/// This method does not (and it should not) check if the specified
1721-
/// object exists in one of the parent object factories. If it did,
1722-
/// message sources and event registries within application context
1723-
/// hierarchy would have circular references, which would cause stack
1724-
/// overflows during message lookup, for example. (A. Seovic)
1720+
/// This method scans the object factory hierarchy starting with the current factory instance upwards.
1721+
/// Use <see cref="ContainsLocalObject"/> if you want to explicitely check just this object factory instance.
17251722
/// </remarks>
17261723
/// <see cref="Spring.Objects.Factory.IObjectFactory.ContainsObject"/>.
17271724
public bool ContainsObject(string name)
@@ -1745,11 +1742,7 @@ public string[] GetAliases(string name)
17451742
{
17461743
string objectName = TransformedObjectName(name);
17471744
// check if object actually exists in this object factory...
1748-
bool isInSingletonCache = false;
1749-
lock (singletonCache)
1750-
{
1751-
isInSingletonCache = singletonCache.Contains(objectName);
1752-
}
1745+
bool isInSingletonCache = ContainsSingleton(objectName);
17531746
if (isInSingletonCache || ContainsObjectDefinition(objectName))
17541747
{
17551748
// if found, gather aliases...

0 commit comments

Comments
 (0)