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/hui.h src/hg/inc/hui.h
index 2d821a4..58cdc37 100644
--- src/hg/inc/hui.h
+++ src/hg/inc/hui.h
@@ -1,24 +1,25 @@
 /* hui - human genome browser user interface controls that are shared
  * between more than one CGI. */
 #ifndef HUI_H
 #define HUI_H
 
 #include "cart.h"
 #include "trackDb.h"
 #include "customTrack.h"
 #include "wiggle.h"
+#include "asParse.h"
 
 struct lineFile;
 
 void setUdcCacheDir();
 /* set the path to the udc cache dir */
 
 char *hDownloadsServer();
 /* get the downloads server from hg.conf or the default */
 
 char *hUserCookie();
 /* Return our cookie name. */
 
 char *wrapWhiteFont(char *s);
 /* Write white font around s */
 
@@ -1220,39 +1221,52 @@
 // Methods for putting up type specific cfgs used by composites/subtracks in hui.c and exported for common use
 
 boolean cfgBeginBoxAndTitle(struct trackDb *tdb, boolean boxed, char *title);
 /* Handle start of box and title for individual track type settings */
 
 void cfgEndBox(boolean boxed);
 /* Handle end of box and title for individual track type settings */
 
 void printUpdateTime(char *database, struct trackDb *tdb,
     struct customTrack *ct);
 /* display table update time, or in case of bbi file, file stat time */
 
 void printBbiUpdateTime(time_t *timep);
 /* for bbi files, print out the timep value */
 
+//#define EXTRA_FIELDS_SUPPORT
+#ifdef EXTRA_FIELDS_SUPPORT
 enum fieldType {
     ftString  =0,
     ftInteger =1,
     ftFloat   =2,
 };
 
 struct extraField {
 // extraFileds are defined in trackDb and provide labls and can be used in filtering
     struct extraField *next;
     char *name;                 // name of field
     char *label;                // Label (which could include HTML)
     enum fieldType type;        // string, int, float
     };
 
-struct extraField *extraFieldsGet(struct trackDb *tdb);
+struct extraField *extraFieldsGet(char *db, struct trackDb *tdb);
 // returns any extraFields defined in trackDb
 
 struct extraField *extraFieldsFind(struct extraField *extras, char *name);
 // returns the extraField matching the name (case insensitive).  Note: slNameFind does NOT work.
 
 void extraFieldsFree(struct extraField **pExtras);
 // frees all mem for extraFields list
+#endif///def EXTRA_FIELDS_SUPPORT
+
+
+struct asObject *asForTdb(struct sqlConnection *conn, struct trackDb *tdb);
+// Get autoSQL description if any associated with table.
+
+struct asColumn *asColumnFind(struct asObject *asObj, char *name);
+// Return named column.
+
+struct slName *asColNames(struct asObject *as);
+// Get list of column names.
 
 #endif /* HUI_H */