Index: trunk/ippdb/src/ippdb.h
===================================================================
--- trunk/ippdb/src/ippdb.h	(revision 9705)
+++ trunk/ippdb/src/ippdb.h	(revision 9783)
@@ -20,5 +20,5 @@
 /*
  *
- * This file was generated by glueforge 0.29
+ * This file was generated by glueforge 0.30
  *
  * Do NOT directly edit this file.
@@ -2010,4 +2010,5 @@
     psS32           p1_version;
     psS32           p2_version;
+    char            *label;
 } p2PendingExpRow;
 
@@ -2021,5 +2022,6 @@
     const char      *recipe,
     psS32           p1_version,
-    psS32           p2_version
+    psS32           p2_version,
+    const char      *label
 );
 
@@ -2054,5 +2056,6 @@
     const char      *recipe,
     psS32           p1_version,
-    psS32           p2_version
+    psS32           p2_version,
+    const char      *label
 );
 
@@ -2397,4 +2400,5 @@
     psS32           p1_version;
     psS32           p2_version;
+    char            *label;
 } p2ProcessedExpRow;
 
@@ -2407,5 +2411,6 @@
     const char      *exp_tag,
     psS32           p1_version,
-    psS32           p2_version
+    psS32           p2_version,
+    const char      *label
 );
 
@@ -2439,5 +2444,6 @@
     const char      *exp_tag,
     psS32           p1_version,
-    psS32           p2_version
+    psS32           p2_version,
+    const char      *label
 );
 
@@ -2574,4 +2580,186 @@
     FILE            *stream,            ///< a stream
     psArray         *objects,           ///< An array of p2ProcessedExpRow objects
+    bool            mdcf                ///< format as mdconfig or simple
+);
+/** p2MaskRow data structure
+ *
+ * Structure for representing a single row of p2Mask table data.
+ */
+
+typedef struct {
+    char            *label;
+} p2MaskRow;
+
+/** Creates a new p2MaskRow object
+ *
+ *  @return A new p2MaskRow object or NULL on failure.
+ */
+
+p2MaskRow *p2MaskRowAlloc(
+    const char      *label
+);
+
+/** Creates a new p2Mask table
+ *
+ * @return true on success
+ */
+
+bool p2MaskCreateTable(
+    psDB            *dbh                ///< Database handle
+);
+
+/** Deletes a p2Mask table
+ *
+ * @return true on success
+ */
+
+bool p2MaskDropTable(
+    psDB            *dbh                ///< Database handle
+);
+
+/** Insert a single row into a table
+ *
+ * This function constructs and inserts a single row based on it's parameters.
+ *
+ * @return true on success
+ */
+
+bool p2MaskInsert(
+    psDB            *dbh,               ///< Database handle
+    const char      *label
+);
+
+/** Deletes up to limit rows from the database and returns the number of rows actually deleted. 
+ *
+ * @return A The number of rows removed or a negative value on error
+ */
+
+long long p2MaskDelete(
+    psDB            *dbh,               ///< Database handle
+    const psMetadata *where,            ///< Row match criteria
+    unsigned long long limit            ///< Maximum number of elements to delete 
+);
+
+/** Insert a single p2MaskRow object into a table
+ *
+ * This function constructs and inserts a single row based on it's parameters.
+ *
+ * @return true on success
+ */
+
+bool p2MaskInsertObject(
+    psDB            *dbh,               ///< Database handle
+    p2MaskRow       *object             ///< p2MaskRow object
+);
+
+/** Insert an array of p2MaskRow object into a table
+ *
+ * This function constructs and inserts multiple rows based on it's parameters.
+ *
+ * @return true on success
+ */
+
+bool p2MaskInsertObjects(
+    psDB            *dbh,               ///< Database handle
+    psArray         *objects            ///< array of p2MaskRow objects
+);
+
+/** Insert data from a binary FITS table p2MaskRow into the database
+ *
+ * This function expects a psFits object with a FITS table as the first
+ * extension.  The table must have at least one row of data in it, that is of
+ * the appropriate format (number of columns and their type).  All other
+ * extensions are ignored.
+ *
+ * @return true on success
+ */
+
+bool p2MaskInsertFits(
+    psDB            *dbh,               ///< Database handle
+    const psFits    *fits               ///< psFits object
+);
+
+/** Selects up to limit from the database and returns them in a binary FITS table
+ *
+ * This function assumes an empty psFits object and will create a FITS table
+ * as the first extension.
+ *
+ *  See psDBSelectRows() for documentation on the format of where.
+ *
+ * @return true on success
+ */
+
+bool p2MaskSelectRowsFits(
+    psDB            *dbh,               ///< Database handle
+    psFits          *fits,              ///< psFits object
+    const psMetadata *where,            ///< Row match criteria
+    unsigned long long limit            ///< Maximum number of elements to return
+);
+
+/** Convert a p2MaskRow into an equivalent psMetadata
+ *
+ * @return A psMetadata pointer or NULL on error
+ */
+
+psMetadata *p2MaskMetadataFromObject(
+    const p2MaskRow *object             ///< fooRow to convert into a psMetadata
+);
+
+/** Convert a psMetadata into an equivalent fooRow
+ *
+ * @return A p2MaskRow pointer or NULL on error
+ */
+
+p2MaskRow *p2MaskObjectFromMetadata(
+    psMetadata      *md                 ///< psMetadata to convert into a fooRow
+);
+/** Selects up to limit rows from the database and returns as p2MaskRow objects in a psArray
+ *
+ *  See psDBSelectRows() for documentation on the format of where.
+ *
+ * @return A psArray pointer or NULL on error
+ */
+
+psArray *p2MaskSelectRowObjects(
+    psDB            *dbh,               ///< Database handle
+    const psMetadata *where,            ///< Row match criteria
+    unsigned long long limit            ///< Maximum number of elements to return
+);
+/** Deletes a row from the database coresponding to an p2Mask
+ *
+ *  Note that a 'where' search psMetadata is constructed from each object and
+ *  used to find rows to delete.
+ *
+ * @return A The number of rows removed or a negative value on error
+ */
+
+bool p2MaskDeleteObject(
+    psDB            *dbh,               ///< Database handle
+    const p2MaskRow *object    ///< Object to delete
+);
+/** Deletes up to limit rows from the database and returns the number of rows actually deleted. 
+ *
+ *  Note that a 'where' search psMetadata is constructed from each object and
+ *  used to find rows to delete.
+ *
+ * @return A The number of rows removed or a negative value on error
+ */
+
+long long p2MaskDeleteRowObjects(
+    psDB            *dbh,               ///< Database handle
+    const psArray   *objects,           ///< Array of objects to delete
+    unsigned long long limit            ///< Maximum number of elements to delete 
+);
+/** Formats and prints an array of p2MaskRow objects
+ *
+ * When mdcf is set the formated output is in psMetadataConfig
+ * format, otherwise it is in a simple tabular format.
+ *
+ * @return true on success
+ */
+
+bool p2MaskPrintObjects(
+    FILE            *stream,            ///< a stream
+    psArray         *objects,           ///< An array of p2MaskRow objects
     bool            mdcf                ///< format as mdconfig or simple
 );
