 | GenericSingletonProviderGetInstanceT(Boolean) Method |
Returns the only instance of the desired class.
This instance is created beforehand the first time it is called.
Namespace: NetEti.GlobalsAssembly: NetEti.Global (in NetEti.Global.dll) Version: 1.0.0+ad672dc5430e1683eae7461ce3945c8e9dce1c49
Syntaxpublic static T GetInstance<T>(
out bool newInstance
)
where T : class
Public Shared Function GetInstance(Of T As Class) (
<OutAttribute> ByRef newInstance As Boolean
) As T
public:
generic<type name T>
where T : ref class
static T GetInstance(
[OutAttribute] bool% newInstance
)
static member GetInstance :
newInstance : bool byref -> 'T when 'T : not struct
Parameters
- newInstance Boolean
- True if the returned instance has just been created.
Type parameters
- T
- Type of class requested
Return value
TAn instance of the requested class as a singleton
See also