Registers an instance that will be returned whenever the IocContainer resolves the specified type.
Syntax
| Visual Basic (Usage) | Copy Code |
|---|
Dim instance As IocContainer
Dim instance As TType
Dim value As IRegistration
value = instance.RegisterInstance(Of TType)(instance) |
Parameters
- instance
- The instance that will alway be returned when TType is resolved. The instance must be assignable to a variable of type TType.
Type Parameters
- TType
- The type that is being registered for resolution.
Return Value
An instance of IRegistration that can be used to configure how the get information about the registration, or change the lifetime manager.
Requirements
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family
See Also