Download the thesis

Transcript
48
CHAPTER 3. DEVELOPER POINT OF VIEW
column and similarly for row vectors.
Thus when there is possibility to concatenate given list of lists to a matrix (same data
type, same count of elements in leaf lists), common matrix is created. This process works
up to the depth of two.
For example:
A:
- [7 ,8 ,9]
- [0 ,3 ,2]
B:
- [4]
- [5]
C:
- [1 ,2 ,3]
will create structure with one key A storing 2-to-3 matrix, key B storing two-element
column vector and C storing three-element row vector.
If the data types are incompatible (Date and number in the same list) or lengths of
inner lists are different, reader issues a cell matrix.
YAML writer was written to work the opposite way – data written from MATLAB to
YAML and read back should be the same as written.
There was also a requirement for the reader to support imports and mixins.
Both features mentioned are the same in principle. Mixin is a merge of two dictionaries, which are concatenated to one new dictionary, with child dictionary keys overwriting
the parent ones when they have a same name.
So in general, when there is a key named parent in the YAML dictionary, the dictionary, which contains it is considered to be a parent, the rest of the data is looked up for
another key of the name specified by the value of parent field and its value is used as a
child.
When there is an import key, the behaviour is almost the same with the difference
that the content of the file, with name contained in the import value is considered to be
a child.
See YAMLMatlab page [23] for further details.
3.7
Web browser part of the application
Web pages evolved a lot during past years. They are no longer only HTML documents,
rendered from static files. The trend is to make web pages to make user feels like he or
she works with the real desktop application. This involves client-side scripting to be used
intensively.
Today, the most widespread language to be run in a web browser is Java Script. It is
simple language, similar to Java in syntax, but has its own manners. Java Script is more
and more powerful, which allows the developer to write really sophisticated applications
like word processors and spreadsheet processors and run them in the browser.
Java Script itself is quite lightweight and not feature rich, hence many extensions were