#include <tagUtils.h> int tag2values( char *tag, char *type, int *start, int *end, int *strand, char *comment);
This function converts a tag in string format to a tag represented by a series
of separate integer/string values. It performs the opposite task to the
The tag string format is as used in the experiment file
TG lines. The
format is "TYPE<space>S<space>start..end" followed by
zero or more comment lines, each starting with a newline character. TYPE
is the tag type, which must be 4 characters, and S is the strand; one of
-" or "
The tag string is passed as the tag argument. This is then expanded into
the type, start, end, strand and comment values.
The comment must have been allocated before hand (
always be large enough). If no comment was found then comment is set to
be an empty string. type should be allocated to be 5 bytes long.
The function returns 0 for success, -1 for failure.