pmConfig.h

Go to the documentation of this file.
00001 /** @file  pmConfig.h
00002  *
00003  *  @author PAP, IfA
00004  *
00005  *  @version $Revision: 1.2 $ $Name: rel9_1 $
00006  *  @date $Date: 2005/10/20 23:06:24 $
00007  *
00008  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
00009  *
00010  */
00011 #ifndef PM_CONFIG_H
00012 #define PM_CONFIG_H
00013 
00014 #include "pslib.h"
00015 
00016 
00017 
00018 /** pmConfigRead
00019  * 
00020  * pmConfigRead shall load the site configuration (according to the above rule
00021  * for determining the source). The camera configuration shall also be loaded if
00022  * it is specified on the command line (argc, argv); otherwise it shall be set to
00023  * NULL. The recipe shall also be loaded from the command line (if specified) or,
00024  * if the camera configuration has been loaded, from the camera configuration and
00025  * recipe specification therein (see below). In dealing with the command line
00026  * parameters, the functions shall use the appropriate functions in psLib to
00027  * retrieve and remove the relevant options from the argument list; this
00028  * simplifies assignment of the mandatory arguments, since all the optional
00029  * command line arguments are removed leaving only the mandatory arguments. The
00030  * following psLib setups shall also be performed if they are specified in the
00031  * site configuration:
00032  *
00033  */
00034 bool pmConfigRead(
00035     psMetadata **site,
00036     psMetadata **camera,
00037     psMetadata **recipe,
00038     int *argc,
00039     char **argv,
00040     const char *recipeName
00041 );
00042 
00043 
00044 
00045 /** pmConfigValidateCamera
00046  * 
00047  * This function, used by pmConfigCameraFromHeader, shall return true if the
00048  * FITS header matches the rule contained in the camera configuration (see
00049  * x2.2.2.3); otherwise it shall return false.
00050  * 
00051  */
00052 bool pmConfigValidateCamera(
00053     const psMetadata *camera,
00054     const psMetadata *header
00055 );
00056 
00057 
00058 
00059 /** pmConfigCameraFromHeader
00060  * 
00061  * pmConfigCameraFromHeader shall load the camera configuration based on the
00062  * contents of the FITS header, using the list of known cameras contained in the
00063  * site configuration. If more than one camera matches the FITS header, a warning
00064  * shall be generated and the first matching camera returned.
00065  * 
00066  */
00067 psMetadata *pmConfigCameraFromHeader(
00068     const psMetadata *site,
00069     const psMetadata *header
00070 );
00071 
00072 
00073 
00074 /** pmConfigRecipeFromCamera
00075  * 
00076  * pmConfigRecipeFromCamera shall load the recipe configuration based on the
00077  * recipeName and the list of known recipes contained in the camera 
00078  * configuration.
00079  * 
00080  */
00081 psMetadata *pmConfigRecipeFromCamera(
00082     const psMetadata *camera,
00083     const char *recipeName
00084 );
00085 
00086 /** pmConfigDB
00087  * 
00088  * pmConfigDB shall use the site configuration data to open a database handle.
00089  * This is fairly straightforward at the moment, but will change when we beef up
00090  * security. (TBD)
00091  * 
00092  */
00093 psDB *pmConfigDB(
00094     psMetadata *site
00095 );
00096 
00097 
00098 #endif

Generated on Tue Dec 13 13:38:22 2005 for Pan-STARRS Module Library by  doxygen 1.4.5