Summary:
See also: Built-in Classes, XML Utils
The SaxAttributes class provides methods to manipulate XML element attributes.
om.SaxAttributes
Class Methods | |
Name | Description |
copy( src SaxAttributes ) RETURNING om.SaxAttributes |
Clones an existing SaxAttributes object. |
create( ) RETURNING om.SaxAttributes |
Creates a new, empty SaxAttributes object. |
Object Methods | |
Name | Description |
addAttribute( n STRING, v STRING
) |
Adds an attribute to the end of the list. |
clear( ) |
Clears the attribute list. |
getLength( ) RETURNING INTEGER |
Returns the number of attributes in the list. |
getName( pos INTEGER ) RETURNING STRING |
Returns the name of the attribute at position pos. |
getValue( att STRING ) RETURNING STRING |
Returns the value of the attribute identified by the name att. |
getValuebyIndex( pos INTEGER ) RETURNING STRING |
Returns the value of the attribute at position pos. |
removeAttribute( pos INTEGER ) RETURNING INTEGER |
Removes the attribute at position pos. |
setAttributes( atts om.SaxAttributes ) |
Clears the current attribute list and adds all attributes of atts. |
01
FUNCTION displayAttributes( a )02
DEFINE a om.SaxAttributes03
DEFINE i INTEGER04
FOR i=1 to a.getLength()05
DISPLAY a.getName(i) || "=[" || a.getValueByIndex(i) || "]"06
END FOR07
END FUNCTION