parser(_:didStartElement:namespaceURI:qualifiedName:attributes:)
Sent by a parser object to its delegate when it encounters a start tag for a given element.
Declaration
optional func parser(_ parser: XMLParser, didStartElement elementName: String, namespaceURI: String?, qualifiedName qName: String?, attributes attributeDict: [String : String] = [:])Parameters
- parser:
A parser object.
- elementName:
A string that is the name of an element (in its start tag).
- namespaceURI:
If namespace processing is turned on, contains the URI for the current namespace as a string object.
- qName:
If namespace processing is turned on, contains the qualified name for the current namespace as a string object.
- attributeDict:
A dictionary that contains any attributes associated with the element. Keys are the names of attributes, and values are attribute values.
See Also
Related Documentation
Handling XML
parserDidStartDocument(_:)parserDidEndDocument(_:)parser(_:didEndElement:namespaceURI:qualifiedName:)parser(_:didStartMappingPrefix:toURI:)parser(_:didEndMappingPrefix:)parser(_:resolveExternalEntityName:systemID:)parser(_:parseErrorOccurred:)parser(_:validationErrorOccurred:)parser(_:foundCharacters:)parser(_:foundIgnorableWhitespace:)parser(_:foundProcessingInstructionWithTarget:data:)parser(_:foundComment:)parser(_:foundCDATA:)