File Exchange

image thumbnail

XML Parse-n-Find

version 1.0 (3.69 KB) by

XML parser and tag finder

3 Downloads

Updated

View License

Class Definition:

xmlelem - Handle class with dynamic property to hold an XML element data

Functions:

xmlparse - Parse xml file to xmlelem class object tree
xmlfind - Wraps handle.findobj to traverse xmlelem tree

Example:
% Parse XML file to XMLELEM tree
T = xmlparse(fullfile(matlabroot,'toolbox','matlab','general','info.xml'))

% Flatten the tree
F = xmlfind(T)

% Find XML element text with 'matlab'
elem = xmlfind(T,'Name','#text','Value','matlab')

Comments and Ratings (0)

MATLAB Release
MATLAB 8.0 (R2012b)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video