Bumping manifests a=b2g-bump
[gecko.git] / parser / xml / nsISAXMutableAttributes.idl
blobc3c205005ddc63adfa978a9fa542d5b5c9da206d
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #include "nsISupports.idl"
7 #include "nsISAXAttributes.idl"
9 /**
10 * This interface extends the nsISAXAttributes interface with
11 * manipulators so that the list can be modified or reused.
13 [scriptable, uuid(8b1de83d-cebb-49fa-8245-c0fe319eb7b6)]
14 interface nsISAXMutableAttributes : nsISAXAttributes {
16 /**
17 * Add an attribute to the end of the list.
19 * For the sake of speed, this method does no checking
20 * to see if the attribute is already in the list: that is
21 * the responsibility of the application.
23 * @param uri The Namespace URI, or the empty string if
24 * none is available or Namespace processing is not
25 * being performed.
26 * @param localName The local name, or the empty string if
27 * Namespace processing is not being performed.
28 * @param qName The qualified (prefixed) name, or the empty string
29 * if qualified names are not available.
30 * @param type The attribute type as a string.
31 * @param value The attribute value.
33 void addAttribute(in AString uri,
34 in AString localName,
35 in AString qName,
36 in AString type,
37 in AString value);
39 /**
40 * Clear the attribute list for reuse.
42 void clear();
44 /**
45 * Remove an attribute from the list.
47 * @param index The index of the attribute (zero-based).
49 void removeAttribute(in unsigned long index);
51 /**
52 * Set the attributes list. This method will clear any attributes in
53 * the list before adding the attributes from the argument.
55 * @param attributes The attributes object to replace populate the
56 * list with.
58 void setAttributes(in nsISAXAttributes attributes);
60 /**
61 * Set an attribute in the list.
63 * For the sake of speed, this method does no checking for name
64 * conflicts or well-formedness: such checks are the responsibility
65 * of the application.
67 * @param index The index of the attribute (zero-based).
68 * @param uri The Namespace URI, or the empty string if
69 * none is available or Namespace processing is not
70 * being performed.
71 * @param localName The local name, or the empty string if
72 * Namespace processing is not being performed.
73 * @param qName The qualified name, or the empty string
74 * if qualified names are not available.
75 * @param type The attribute type as a string.
76 * @param value The attribute value.
78 void setAttribute(in unsigned long index,
79 in AString uri,
80 in AString localName,
81 in AString qName,
82 in AString type,
83 in AString value);
85 /**
86 * Set the local name of a specific attribute.
88 * @param index The index of the attribute (zero-based).
89 * @param localName The attribute's local name, or the empty
90 * string for none.
92 void setLocalName(in unsigned long index, in AString localName);
94 /**
95 * Set the qualified name of a specific attribute.
97 * @param index The index of the attribute (zero-based).
98 * @param qName The attribute's qualified name, or the empty
99 * string for none.
101 void setQName(in unsigned long index, in AString qName);
104 * Set the type of a specific attribute.
106 * @param index The index of the attribute (zero-based).
107 * @param type The attribute's type.
109 void setType(in unsigned long index, in AString type);
112 * Set the Namespace URI of a specific attribute.
114 * @param index The index of the attribute (zero-based).
115 * @param uri The attribute's Namespace URI, or the empty
116 * string for none.
118 void setURI(in unsigned long index, in AString uri);
121 * Set the value of a specific attribute.
123 * @param index The index of the attribute (zero-based).
124 * @param value The attribute's value.
126 void setValue(in unsigned long index, in AString value);