Report the start of DTD declarations, if any.

This method is intended to report the beginning of the DOCTYPE declaration; if the document has no DOCTYPE declaration, this method will not be invoked.

All declarations reported through DTDHandler or DeclHandler events must appear between the start_dtd and end_dtd events. Declarations are assumed to belong to the internal DTD subset unless they appear between start_entity and end_entity events. Comments and processing instructions from the DTD should also be reported between the start_dtd and end_dtd events, in their original order of (logical) occurrence; they are not required to appear in their correct locations relative to DTDHandler or DeclHandler events, however.

Note that the start_dtd/end_dtd events will appear within the start_document and end_document events from ContentHandler and before the first start_element event.

Parameters:

  • name: document type name.
  • public_id: declared public identifier for the external DTD subset, or null if none was declared.
  • system_id: declared system identifier for the external DTD subset, or null if none was declared. (Note that this is not resolved against the document base URI.)

SEE: end_dtd

SEE: start_entity

Property definitions

sax $ LexicalHandler :: start_dtd
	# Report the start of DTD declarations, if any.
	#
	# This method is intended to report the beginning of the
	# `DOCTYPE` declaration; if the document has no `DOCTYPE` declaration,
	# this method will not be invoked.
	#
	# All declarations reported through `DTDHandler` or `DeclHandler` events
	# must appear between the `start_dtd` and `end_dtd` events.
	# Declarations are assumed to belong to the internal DTD subset
	# unless they appear between `start_entity` and `end_entity` events.
	# Comments and processing instructions from the DTD should also be reported
	# between the `start_dtd` and `end_dtd` events, in their original
	# order of (logical) occurrence; they are not required to
	# appear in their correct locations relative to `DTDHandler`
	# or `DeclHandler` events, however.
	#
	# Note that the `start_dtd`/`end_dtd` events will appear within
	# the `start_document` and `end_document` events from `ContentHandler` and
	# before the first `start_element` event.
	#
	# Parameters:
	#
	# * `name`: document type name.
	# * `public_id`: declared public identifier for the
	# external DTD subset, or `null` if none was declared.
	# * `system_id`: declared system identifier for the
	# external DTD subset, or `null` if none was declared.
	# (Note that this is not resolved against the document
	# base URI.)
	#
	# SEE: `end_dtd`
	#
	# SEE: `start_entity`
	fun start_dtd(name: String, public_id: nullable String,
			system_id: nullable String) do end
lib/sax/ext/lexical_handler.nit:37,2--71,37

saxophonit $ SAXEventLogger :: start_dtd
	redef fun start_dtd(name, public_id, system_id) do
		log.push(["start_dtd", name,
				public_id or else "^NULL",
				system_id or else "^NULL"])
		if lexical_handler != null then
			lexical_handler.start_dtd(name, public_id, system_id)
		end
	end
lib/saxophonit/testing.nit:479,2--486,4