Changeset 14169 for trunk/ippdb/src/ippdb.h
- Timestamp:
- Jul 12, 2007, 12:27:55 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/ippdb/src/ippdb.h (modified) (19 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippdb/src/ippdb.h
r14061 r14169 1395 1395 char *workdir; 1396 1396 char *workdir_state; 1397 char *reduction; 1397 1398 } newExpRow; 1398 1399 … … 1409 1410 const char *state, 1410 1411 const char *workdir, 1411 const char *workdir_state 1412 const char *workdir_state, 1413 const char *reduction 1412 1414 ); 1413 1415 … … 1445 1447 const char *state, 1446 1448 const char *workdir, 1447 const char *workdir_state 1449 const char *workdir_state, 1450 const char *reduction 1448 1451 ); 1449 1452 … … 1811 1814 char *filelevel; 1812 1815 char *workdir; 1816 char *reduction; 1813 1817 char *filter; 1814 1818 psF32 airmass; … … 1849 1853 const char *filelevel, 1850 1854 const char *workdir, 1855 const char *reduction, 1851 1856 const char *filter, 1852 1857 psF32 airmass, … … 1908 1913 const char *filelevel, 1909 1914 const char *workdir, 1915 const char *reduction, 1910 1916 const char *filter, 1911 1917 psF32 airmass, … … 2568 2574 typedef struct { 2569 2575 psS64 chip_id; 2576 psS64 exp_id; 2570 2577 char *state; 2571 2578 char *workdir; … … 2584 2591 chipRunRow *chipRunRowAlloc( 2585 2592 psS64 chip_id, 2593 psS64 exp_id, 2586 2594 const char *state, 2587 2595 const char *workdir, … … 2621 2629 psDB *dbh, ///< Database handle 2622 2630 psS64 chip_id, 2631 psS64 exp_id, 2623 2632 const char *state, 2624 2633 const char *workdir, … … 2775 2784 FILE *stream, ///< a stream 2776 2785 chipRunRow *object, ///< an chipRunRow object 2777 bool mdcf ///< format as mdconfig or simple2778 );2779 /** chipInputImfileRow data structure2780 *2781 * Structure for representing a single row of chipInputImfile table data.2782 */2783 2784 typedef struct {2785 psS64 chip_id;2786 psS64 exp_id;2787 char *class_id;2788 } chipInputImfileRow;2789 2790 /** Creates a new chipInputImfileRow object2791 *2792 * @return A new chipInputImfileRow object or NULL on failure.2793 */2794 2795 chipInputImfileRow *chipInputImfileRowAlloc(2796 psS64 chip_id,2797 psS64 exp_id,2798 const char *class_id2799 );2800 2801 /** Creates a new chipInputImfile table2802 *2803 * @return true on success2804 */2805 2806 bool chipInputImfileCreateTable(2807 psDB *dbh ///< Database handle2808 );2809 2810 /** Deletes a chipInputImfile table2811 *2812 * @return true on success2813 */2814 2815 bool chipInputImfileDropTable(2816 psDB *dbh ///< Database handle2817 );2818 2819 /** Insert a single row into a table2820 *2821 * This function constructs and inserts a single row based on it's parameters.2822 *2823 * @return true on success2824 */2825 2826 bool chipInputImfileInsert(2827 psDB *dbh, ///< Database handle2828 psS64 chip_id,2829 psS64 exp_id,2830 const char *class_id2831 );2832 2833 /** Deletes up to limit rows from the database and returns the number of rows actually deleted.2834 *2835 * @return A The number of rows removed or a negative value on error2836 */2837 2838 long long chipInputImfileDelete(2839 psDB *dbh, ///< Database handle2840 const psMetadata *where, ///< Row match criteria2841 unsigned long long limit ///< Maximum number of elements to delete2842 );2843 2844 /** Insert a single chipInputImfileRow object into a table2845 *2846 * This function constructs and inserts a single row based on it's parameters.2847 *2848 * @return true on success2849 */2850 2851 bool chipInputImfileInsertObject(2852 psDB *dbh, ///< Database handle2853 chipInputImfileRow *object ///< chipInputImfileRow object2854 );2855 2856 /** Insert an array of chipInputImfileRow object into a table2857 *2858 * This function constructs and inserts multiple rows based on it's parameters.2859 *2860 * @return true on success2861 */2862 2863 bool chipInputImfileInsertObjects(2864 psDB *dbh, ///< Database handle2865 psArray *objects ///< array of chipInputImfileRow objects2866 );2867 2868 /** Insert data from a binary FITS table chipInputImfileRow into the database2869 *2870 * This function expects a psFits object with a FITS table as the first2871 * extension. The table must have at least one row of data in it, that is of2872 * the appropriate format (number of columns and their type). All other2873 * extensions are ignored.2874 *2875 * @return true on success2876 */2877 2878 bool chipInputImfileInsertFits(2879 psDB *dbh, ///< Database handle2880 const psFits *fits ///< psFits object2881 );2882 2883 /** Selects up to limit from the database and returns them in a binary FITS table2884 *2885 * This function assumes an empty psFits object and will create a FITS table2886 * as the first extension.2887 *2888 * See psDBSelectRows() for documentation on the format of where.2889 *2890 * @return true on success2891 */2892 2893 bool chipInputImfileSelectRowsFits(2894 psDB *dbh, ///< Database handle2895 psFits *fits, ///< psFits object2896 const psMetadata *where, ///< Row match criteria2897 unsigned long long limit ///< Maximum number of elements to return2898 );2899 2900 /** Convert a chipInputImfileRow into an equivalent psMetadata2901 *2902 * @return A psMetadata pointer or NULL on error2903 */2904 2905 psMetadata *chipInputImfileMetadataFromObject(2906 const chipInputImfileRow *object ///< fooRow to convert into a psMetadata2907 );2908 2909 /** Convert a psMetadata into an equivalent fooRow2910 *2911 * @return A chipInputImfileRow pointer or NULL on error2912 */2913 2914 chipInputImfileRow *chipInputImfileObjectFromMetadata(2915 psMetadata *md ///< psMetadata to convert into a fooRow2916 );2917 /** Selects up to limit rows from the database and returns as chipInputImfileRow objects in a psArray2918 *2919 * See psDBSelectRows() for documentation on the format of where.2920 *2921 * @return A psArray pointer or NULL on error2922 */2923 2924 psArray *chipInputImfileSelectRowObjects(2925 psDB *dbh, ///< Database handle2926 const psMetadata *where, ///< Row match criteria2927 unsigned long long limit ///< Maximum number of elements to return2928 );2929 /** Deletes a row from the database coresponding to an chipInputImfile2930 *2931 * Note that a 'where' search psMetadata is constructed from each object and2932 * used to find rows to delete.2933 *2934 * @return A The number of rows removed or a negative value on error2935 */2936 2937 bool chipInputImfileDeleteObject(2938 psDB *dbh, ///< Database handle2939 const chipInputImfileRow *object ///< Object to delete2940 );2941 /** Deletes up to limit rows from the database and returns the number of rows actually deleted.2942 *2943 * Note that a 'where' search psMetadata is constructed from each object and2944 * used to find rows to delete.2945 *2946 * @return A The number of rows removed or a negative value on error2947 */2948 2949 long long chipInputImfileDeleteRowObjects(2950 psDB *dbh, ///< Database handle2951 const psArray *objects, ///< Array of objects to delete2952 unsigned long long limit ///< Maximum number of elements to delete2953 );2954 /** Formats and prints an array of chipInputImfileRow objects2955 *2956 * When mdcf is set the formated output is in psMetadataConfig2957 * format, otherwise it is in a simple tabular format.2958 *2959 * @return true on success2960 */2961 2962 bool chipInputImfilePrintObjects(2963 FILE *stream, ///< a stream2964 psArray *objects, ///< An array of chipInputImfileRow objects2965 bool mdcf ///< format as mdconfig or simple2966 );2967 /** Formats and prints an chipInputImfileRow object2968 *2969 * When mdcf is set the formated output is in psMetadataConfig2970 * format, otherwise it is in a simple tabular format.2971 *2972 * @return true on success2973 */2974 2975 bool chipInputImfilePrintObject(2976 FILE *stream, ///< a stream2977 chipInputImfileRow *object, ///< an chipInputImfileRow object2978 2786 bool mdcf ///< format as mdconfig or simple 2979 2787 ); … … 4731 4539 psF64 bg; 4732 4540 psF64 bg_stdev; 4541 psS16 fault; 4733 4542 } warpSkyfileRow; 4734 4543 … … 4745 4554 const char *path_base, 4746 4555 psF64 bg, 4747 psF64 bg_stdev 4556 psF64 bg_stdev, 4557 psS16 fault 4748 4558 ); 4749 4559 … … 4781 4591 const char *path_base, 4782 4592 psF64 bg, 4783 psF64 bg_stdev 4593 psF64 bg_stdev, 4594 psS16 fault 4784 4595 ); 4785 4596 … … 5365 5176 psF64 bg; 5366 5177 psF64 bg_stdev; 5178 psS16 fault; 5367 5179 } diffSkyfileRow; 5368 5180 … … 5377 5189 const char *path_base, 5378 5190 psF64 bg, 5379 psF64 bg_stdev 5191 psF64 bg_stdev, 5192 psS16 fault 5380 5193 ); 5381 5194 … … 5411 5224 const char *path_base, 5412 5225 psF64 bg, 5413 psF64 bg_stdev 5226 psF64 bg_stdev, 5227 psS16 fault 5414 5228 ); 5415 5229 … … 5983 5797 psF64 bg; 5984 5798 psF64 bg_stdev; 5799 psS16 fault; 5985 5800 } stackSumSkyfileRow; 5986 5801 … … 5995 5810 const char *path_base, 5996 5811 psF64 bg, 5997 psF64 bg_stdev 5812 psF64 bg_stdev, 5813 psS16 fault 5998 5814 ); 5999 5815 … … 6029 5845 const char *path_base, 6030 5846 psF64 bg, 6031 psF64 bg_stdev 5847 psF64 bg_stdev, 5848 psS16 fault 6032 5849 ); 6033 5850
Note:
See TracChangeset
for help on using the changeset viewer.
