/* itemConf.h was originally generated by the autoSql program, which also * generated itemConf.c and itemConf.sql. This header links the database and * the RAM representation of objects. */ #ifndef ITEMCONF_H #define ITEMCONF_H #define ITEMCONF_NUM_COLS 3 struct itemConf /* Probability and false discovery rate (FDR) for an element in a track. */ { struct itemConf *next; /* Next in singly linked list. */ char *id; /* Identifier of element */ float probability; /* Probability associated with element */ float fdr; /* False Discovery Rate (FDR) associated with element */ }; void itemConfStaticLoad(char **row, struct itemConf *ret); /* Load a row from itemConf table into ret. The contents of ret will * be replaced at the next call to this function. */ struct itemConf *itemConfLoad(char **row); /* Load a itemConf from row fetched with select * from itemConf * from database. Dispose of this with itemConfFree(). */ struct itemConf *itemConfLoadAll(char *fileName); /* Load all itemConf from whitespace-separated file. * Dispose of this with itemConfFreeList(). */ struct itemConf *itemConfLoadAllByChar(char *fileName, char chopper); /* Load all itemConf from chopper separated file. * Dispose of this with itemConfFreeList(). */ #define itemConfLoadAllByTab(a) itemConfLoadAllByChar(a, '\t'); /* Load all itemConf from tab separated file. * Dispose of this with itemConfFreeList(). */ struct itemConf *itemConfCommaIn(char **pS, struct itemConf *ret); /* Create a itemConf out of a comma separated string. * This will fill in ret if non-null, otherwise will * return a new itemConf */ void itemConfFree(struct itemConf **pEl); /* Free a single dynamically allocated itemConf such as created * with itemConfLoad(). */ void itemConfFreeList(struct itemConf **pList); /* Free a list of dynamically allocated itemConf's */ void itemConfOutput(struct itemConf *el, FILE *f, char sep, char lastSep); /* Print out itemConf. Separate fields with sep. Follow last field with lastSep. */ #define itemConfTabOut(el,f) itemConfOutput(el,f,'\t','\n'); /* Print out itemConf as a line in a tab-separated file. */ #define itemConfCommaOut(el,f) itemConfOutput(el,f,',',','); /* Print out itemConf as a comma separated list including final comma. */ /* -------------------------------- End autoSql Generated Code -------------------------------- */ #endif /* ITEMCONF_H */