< DOMAttribute > Protocol Reference
Inheritance diagram for < DOMAttribute >:
List of all members.
Detailed Description
Represents an attribute of an element.
There is no need to create attribute objects yourself. To add attributes to an element, use DOMElement::setAttributeNamed:value: on an element node. You can then get a reference to the attribute object by using the DOMElement::attributeNamed: method, or get it's value directly with DOMElement::valueOfAttributeNamed:. Never create them yourself.
A word on namespaces: an attribute cannot have a prefix without being in a namespace (having a namespace URI). The methods setName: and setNamespaceURI:prefix: will raise exceptions if you try to set a name containing a colon or set a prefix without first having put the attribute in the namespace.
Member Function Documentation
|
|
Returns the local name of the attribute |
|
|
Returns the qualified name of the attribute.
The qualified name is the namespace prefix (if any) a colon and the local, name (iconara:book for example). |
|
|
Returns the element containing this attribute. |
| - (void) setIsId: |
|
(BOOL) |
state |
|
|
|
|
|
Sets the isId flag of this attribute. See isId. |
| - (void) setName: |
|
(NSString *) |
name |
|
|
|
|
|
Sets the name of this attribute.
- Exceptions:
-
| DOMNamespaceException | Raised if the name matches "xmlns" in any variation of case, "xmlns" is a reserved name. |
|
| - (void) setValue: |
|
(NSString *) |
value |
|
|
|
|
|
Sets the value of this attribute. |
|
|
Returns the value of the attribute. |