ScopeGetItem Method

Simple Injector
Retrieves an item from the scope stored by the given key or null when no item is stored by that key.

Namespace:  SimpleInjector
Assembly:  SimpleInjector (in SimpleInjector.dll) Version: 5.3.0
Syntax

public Object GetItem(
	Object key
)

Parameters

key
Type: SystemObject
The key of the item to retrieve.

Return Value

Type: Object
The stored item or null.
Exceptions

ExceptionCondition
ArgumentNullExceptionThrown when one of the supplied arguments is a null reference.
Remarks

Thread safety: Calls to this method are thread safe, but users should take proper percussions when they call both GetItem and SetItem(Object, Object).
See Also

Reference