Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

NamespaceParserRegistry.RegisterParser(INamespaceParser, String, String) Method

Associates a parser with a namespace.

[Visual Basic]
Public Overloads Shared Sub RegisterParser( _
   ByVal parser As INamespaceParser, _
   ByVal namespaceUri As String, _
   ByVal schemaLocation As String _
public static void RegisterParser(
   INamespaceParser parser,
   string namespaceUri,
   string schemaLocation


The parser instance.
The namespace with which to associate instance of the parser.
The location of the XML schema that should be used for validation of the XML elements that belong to the specified namespace (can be any valid Spring.NET resource URI).


Note    Parsers registered with the same namespaceUri as that of a parser that has previously been registered will overwrite the existing parser.


Exception Type Condition
ArgumentNullException If parser is a null reference (Nothing in Visual Basic), or if namespaceUri is not specified and parser class does not have default value defined using NamespaceParserAttribute.

See Also

NamespaceParserRegistry Class | Spring.Objects.Factory.Xml Namespace | NamespaceParserRegistry.RegisterParser Overload List