Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

ByTypeSharedStateFactory.GetKey Method

Returns the Type for the given instance.

[Visual Basic]
Protected Overrides Sub GetKey( _
   ByVal instance As Object, _
   ByVal name As String _
)
[C#]
protected override object GetKey(
   object instance,
   string name
);

Parameters

instance
the instance to obtain the key for.
name
the name of the instance (ignored by this provider)

Return Value

instance.GetType() if it matches the TypeFilter list. Null otherwise.

Remarks

This method will only be called if CanProvideState returned true previously.

See Also

ByTypeSharedStateFactory Class | Spring.Objects.Support Namespace