Org.Xml.Sax.IContentHandler.StartPrefixMapping Method
Begin the scope of a prefix-URI Namespace mapping.

Syntax

[Android.Runtime.Register("startPrefixMapping", "(Ljava/lang/String;Ljava/lang/String;)V", "GetStartPrefixMapping_Ljava_lang_String_Ljava_lang_String_Handler:Org.Xml.Sax.IContentHandlerInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public void StartPrefixMapping (string prefix, string uri)

See Also

IContentHandler.EndPrefixMapping(string)
IContentHandler.StartElement(string, System.String, System.String, System.String)

Parameters

prefix
the Namespace prefix being declared. An empty string is used for the default element namespace, which has no prefix.
uri
the Namespace URI the prefix is mapped to

Exceptions

TypeReason
Org.Xml.Sax.SAXExceptionthe client may throw an exception during processing

Remarks

Begin the scope of a prefix-URI Namespace mapping.

The information from this event is not necessary for normal Namespace processing: the SAX XML reader will automatically replace prefixes for element and attribute names when the http://xml.org/sax/features/namespaces feature is true (the default).

There are cases, however, when applications need to use prefixes in character data or in attribute values, where they cannot safely be expanded automatically; the start/endPrefixMapping event supplies the information to the application to expand prefixes in those contexts itself, if necessary.

Note that start/endPrefixMapping events are not guaranteed to be properly nested relative to each other: all startPrefixMapping events will occur immediately before the corresponding IContentHandler.StartElement(string, System.String, System.String, System.String) event, and all IContentHandler.EndPrefixMapping(string) events will occur immediately after the corresponding IContentHandler.EndElement(string, System.String, System.String) event, but their order is not otherwise guaranteed.

There should never be start/endPrefixMapping events for the "xml" prefix, since it is predeclared and immutable.

[Android Documentation]

Requirements

Namespace: Org.Xml.Sax
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1