public class FragmentStringParser
extends Object
This class is used to parse a String representation of a file structure into
an Object-Tree representation of that file.
As an example for a valid expression, consider the following line:
FILEPATH>varname1&varname2[50:500]&varname3#varname4[0:2000] The prefix, up
until ">", designates the resource location, which is currently limited to
files. Right of ">" variable names can be given, each of which should be
separated by an "&" sign. Each variable can be read in a range only, by
putting the range behind the name like "varname2[50:500]" which will try to
read varname2 from its 51 st entry (zero based indexing), up until
(inclusive), entry 500. You can additionally define an increment like
"varname2[50:500:2]" which would only read every second entry in varname2.
Finally, variables may be used to index other variables, a typical example
are peak lists, which do not contain mass-intensity data for every possible
mass, but only for those which have been measured, represented in row
compressed storage format. Example: "varname3#varname4[0:2000]", read the
items in varname3, starting at the item which is contained in varname4 at
position 0 up until the item stored in position 2000. This will give you a
list of arrays with 2001 elements, each individual with possibly different
length.
- Author:
- Nils Hoffmann