060ada2535fca719656219c1214a3e1c16490693
tdreszer
  Wed Nov 9 16:06:41 2011 -0800
Moved as code in hgTables down to lib and access it from hgc and hgTrackUi.  This is to remove 'extraFields' support as per Jim's request in redmine 5883 and 5582
diff --git src/hg/inc/makeItemsItem.h src/hg/inc/makeItemsItem.h
index 44390b5..70165bc 100644
--- src/hg/inc/makeItemsItem.h
+++ src/hg/inc/makeItemsItem.h
@@ -1,100 +1,102 @@
 /* makeItemsItem.h was originally generated by the autoSql program, which also 
  * generated makeItemsItem.c and makeItemsItem.sql.  This header links the database and
  * the RAM representation of objects. */
 
 #ifndef MAKEITEMSITEM_H
 #define MAKEITEMSITEM_H
 
 #include "jksql.h"
+#include "asParse.h"
 #define MAKEITEMSITEM_NUM_COLS 12
 
 struct makeItemsItem
 /* An item in a makeItems type track. */
     {
     struct makeItemsItem *next;  /* Next in singly linked list. */
     unsigned bin;	/* Bin for range index */
     char *chrom;	/* Reference sequence chromosome or scaffold */
     unsigned chromStart;	/* Start position in chromosome */
     unsigned chromEnd;	/* End position in chromosome */
     char *name;	/* Name of item - up to 16 chars */
     unsigned score;	/* 0-1000.  Higher numbers are darker. */
     char strand[2];	/* + or - for strand */
     unsigned thickStart;	/* Start of thick part */
     unsigned thickEnd;	/* End position of thick part */
     unsigned itemRgb;	/* RGB 8 bits each as in bed */
     char *description;	/* Longer item description */
     unsigned id;	/* Unique ID for item */
     };
 
 void makeItemsItemStaticLoad(char **row, struct makeItemsItem *ret);
 /* Load a row from makeItemsItem table into ret.  The contents of ret will
  * be replaced at the next call to this function. */
 
 struct makeItemsItem *makeItemsItemLoadByQuery(struct sqlConnection *conn, char *query);
 /* Load all makeItemsItem from table that satisfy the query given.  
  * Where query is of the form 'select * from example where something=something'
  * or 'select example.* from example, anotherTable where example.something = 
  * anotherTable.something'.
  * Dispose of this with makeItemsItemFreeList(). */
 
 void makeItemsItemSaveToDb(struct sqlConnection *conn, struct makeItemsItem *el, char *tableName, int updateSize);
 /* Save makeItemsItem as a row to the table specified by tableName. 
  * As blob fields may be arbitrary size updateSize specifies the approx size
  * of a string that would contain the entire query. Arrays of native types are
  * converted to comma separated strings and loaded as such, User defined types are
  * inserted as NULL. Note that strings must be escaped to allow insertion into the database.
  * For example "autosql's features include" --> "autosql\'s features include" 
  * If worried about this use makeItemsItemSaveToDbEscaped() */
 
 void makeItemsItemSaveToDbEscaped(struct sqlConnection *conn, struct makeItemsItem *el, char *tableName, int updateSize);
 /* Save makeItemsItem as a row to the table specified by tableName. 
  * As blob fields may be arbitrary size updateSize specifies the approx size.
  * of a string that would contain the entire query. Automatically 
  * escapes all simple strings (not arrays of string) but may be slower than makeItemsItemSaveToDb().
  * For example automatically copies and converts: 
  * "autosql's features include" --> "autosql\'s features include" 
  * before inserting into database. */ 
 
 struct makeItemsItem *makeItemsItemLoad(char **row);
 /* Load a makeItemsItem from row fetched with select * from makeItemsItem
  * from database.  Dispose of this with makeItemsItemFree(). */
 
 struct makeItemsItem *makeItemsItemLoadAll(char *fileName);
 /* Load all makeItemsItem from whitespace-separated file.
  * Dispose of this with makeItemsItemFreeList(). */
 
 struct makeItemsItem *makeItemsItemLoadAllByChar(char *fileName, char chopper);
 /* Load all makeItemsItem from chopper separated file.
  * Dispose of this with makeItemsItemFreeList(). */
 
 #define makeItemsItemLoadAllByTab(a) makeItemsItemLoadAllByChar(a, '\t');
 /* Load all makeItemsItem from tab separated file.
  * Dispose of this with makeItemsItemFreeList(). */
 
 struct makeItemsItem *makeItemsItemCommaIn(char **pS, struct makeItemsItem *ret);
 /* Create a makeItemsItem out of a comma separated string. 
  * This will fill in ret if non-null, otherwise will
  * return a new makeItemsItem */
 
 void makeItemsItemFree(struct makeItemsItem **pEl);
 /* Free a single dynamically allocated makeItemsItem such as created
  * with makeItemsItemLoad(). */
 
 void makeItemsItemFreeList(struct makeItemsItem **pList);
 /* Free a list of dynamically allocated makeItemsItem's */
 
 void makeItemsItemOutput(struct makeItemsItem *el, FILE *f, char sep, char lastSep);
 /* Print out makeItemsItem.  Separate fields with sep. Follow last field with lastSep. */
 
 #define makeItemsItemTabOut(el,f) makeItemsItemOutput(el,f,'\t','\n');
 /* Print out makeItemsItem as a line in a tab-separated file. */
 
 #define makeItemsItemCommaOut(el,f) makeItemsItemOutput(el,f,',',',');
 /* Print out makeItemsItem as a comma separated list including final comma. */
 
 /* -------------------------------- End autoSql Generated Code -------------------------------- */
 
-extern char *makeItemsItemAutoSqlString; /* AutoSql object/table definition. */
+struct asObject *makeItemsItemAsObj();
+// Return asObject describing fields of makeItemsItem
 
 #endif /* MAKEITEMSITEM_H */