Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

IObjectDefinitionRegistry.RegisterAlias Method

Given a object name, create an alias. We typically use this method to support names that are illegal within XML ids (used for object names).

[Visual Basic]
Public Sub RegisterAlias( _
   ByVal name As String, _
   ByVal theAlias As String _
)
[C#]
void RegisterAlias(
   string name,
   string theAlias
);

Parameters

name
The name of the object.
theAlias
The alias that will behave the same as the object name.

Exceptions

Exception Type Condition
NoSuchObjectDefinitionException If there is no object with the given name.
ObjectDefinitionStoreException If the alias is already in use.

See Also

IObjectDefinitionRegistry Interface | Spring.Objects.Factory.Support Namespace