Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
michael@0 | 2 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 4 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 5 | |
michael@0 | 6 | #include "nsISupports.idl" |
michael@0 | 7 | |
michael@0 | 8 | /** |
michael@0 | 9 | * Receive notification of basic DTD-related events. |
michael@0 | 10 | * |
michael@0 | 11 | * If a SAX application needs information about notations and |
michael@0 | 12 | * unparsed entities, then the application implements this interface |
michael@0 | 13 | * and registers an instance with the SAX parser using the parser's |
michael@0 | 14 | * setDTDHandler method. The parser uses the instance to report |
michael@0 | 15 | * notation and unparsed entity declarations to the application. |
michael@0 | 16 | * |
michael@0 | 17 | * Note that this interface includes only those DTD events that the |
michael@0 | 18 | * XML recommendation requires processors to report: notation and |
michael@0 | 19 | * unparsed entity declarations. |
michael@0 | 20 | * |
michael@0 | 21 | * The SAX parser may report these events in any order, regardless |
michael@0 | 22 | * of the order in which the notations and unparsed entities were |
michael@0 | 23 | * declared; however, all DTD events must be reported after the |
michael@0 | 24 | * document handler's startDocument event, and before the first |
michael@0 | 25 | * startElement event. (If the LexicalHandler is used, these events |
michael@0 | 26 | * must also be reported before the endDTD event.) |
michael@0 | 27 | */ |
michael@0 | 28 | [scriptable, uuid(4d01f225-6cc5-11da-be43-001422106990)] |
michael@0 | 29 | interface nsISAXDTDHandler : nsISupports { |
michael@0 | 30 | |
michael@0 | 31 | /** |
michael@0 | 32 | * Receive notification of a notation declaration event. |
michael@0 | 33 | * |
michael@0 | 34 | * It is up to the application to record the notation for later |
michael@0 | 35 | * reference, if necessary; notations may appear as attribute values |
michael@0 | 36 | * and in unparsed entity declarations, and are sometime used with |
michael@0 | 37 | * processing instruction target names. |
michael@0 | 38 | * |
michael@0 | 39 | * At least one of publicId and systemId must be non-null. If a |
michael@0 | 40 | * system identifier is present, and it is a URL, the SAX parser |
michael@0 | 41 | * must resolve it fully before passing it to the application |
michael@0 | 42 | * through this event. |
michael@0 | 43 | * |
michael@0 | 44 | * There is no guarantee that the notation declaration will be |
michael@0 | 45 | * reported before any unparsed entities that use it. |
michael@0 | 46 | * |
michael@0 | 47 | * @param name The notation name. |
michael@0 | 48 | * @param publicId The notation's public identifier, or null if none was |
michael@0 | 49 | * given. |
michael@0 | 50 | * @param systemId The notation's system identifier, or null if none was |
michael@0 | 51 | * given. |
michael@0 | 52 | */ |
michael@0 | 53 | void notationDecl(in AString name, |
michael@0 | 54 | in AString publicId, |
michael@0 | 55 | in AString systemId); |
michael@0 | 56 | |
michael@0 | 57 | /** |
michael@0 | 58 | * Receive notification of an unparsed entity declaration event. |
michael@0 | 59 | * |
michael@0 | 60 | * Note that the notation name corresponds to a notation reported |
michael@0 | 61 | * by the notationDecl event. It is up to the application to record |
michael@0 | 62 | * the entity for later reference, if necessary; unparsed entities |
michael@0 | 63 | * may appear as attribute values. |
michael@0 | 64 | * |
michael@0 | 65 | * If the system identifier is a URL, the parser must resolve it |
michael@0 | 66 | * fully before passing it to the application. |
michael@0 | 67 | * |
michael@0 | 68 | * @param name The unparsed entity's name. |
michael@0 | 69 | * @param publicId The entity's public identifier, or null if none was |
michael@0 | 70 | * given. |
michael@0 | 71 | * @param systemId The entity's system identifier, or null if none was |
michael@0 | 72 | * given. |
michael@0 | 73 | * @param notationName The name of the associated notation. |
michael@0 | 74 | */ |
michael@0 | 75 | void unparsedEntityDecl(in AString name, in AString publicId, |
michael@0 | 76 | in AString systemId, in AString notationName); |
michael@0 | 77 | }; |