NCBI C Toolkit Cross Reference

C/desktop/apparam.h


  1 /*   apparam.h
  2 * ===========================================================================
  3 *
  4 *                            PUBLIC DOMAIN NOTICE
  5 *            National Center for Biotechnology Information (NCBI)
  6 *
  7 *  This software/database is a "United States Government Work" under the
  8 *  terms of the United States Copyright Act.  It was written as part of
  9 *  the author's official duties as a United States Government employee and
 10 *  thus cannot be copyrighted.  This software/database is freely available
 11 *  to the public for use. The National Library of Medicine and the U.S.
 12 *  Government do not place any restriction on its use or reproduction.
 13 *  We would, however, appreciate having the NCBI and the author cited in
 14 *  any work or product based on this material
 15 *
 16 *  Although all reasonable efforts have been taken to ensure the accuracy
 17 *  and reliability of the software and data, the NLM and the U.S.
 18 *  Government do not and cannot warrant the performance or results that
 19 *  may be obtained by using this software or data. The NLM and the U.S.
 20 *  Government disclaim all warranties, express or implied, including
 21 *  warranties of performance, merchantability or fitness for any particular
 22 *  purpose.
 23 *
 24 * ===========================================================================
 25 *
 26 * File Name:  apparam.h
 27 *
 28 * Author:  Sergei Egorov
 29 *
 30 * Version Creation Date:   9/23/94
 31 *
 32 * $Revision: 6.0 $
 33 *
 34 * File Description: 
 35 *
 36 * Modifications:  
 37 * --------------------------------------------------------------------------
 38 * Date     Name        Description of modification
 39 * -------  ----------  -----------------------------------------------------
 40 *
 41 *
 42 * ==========================================================================
 43 */
 44 
 45 #ifndef _APPARAM_
 46 #define _APPARAM_
 47 
 48 #include <vibrant.h>
 49 
 50 /* fuzzy logic here 8^) */
 51 typedef UIEnum UIFuzzy, PNTR UIFuzzyPtr;
 52 #define FUZZY_DEFAULT       -3 /* JK */
 53 #define FUZZY_VERY_SMALL    -2
 54 #define FUZZY_SMALL         -1
 55 #define FUZZY_MEDIUM        0
 56 #define FUZZY_LARGE         1
 57 #define FUZZY_VERY_LARGE    2
 58 
 59 #define MAX_APS_BASE  30
 60 #define MAX_APS_SECT  60
 61 #define MAX_APS_VALUE 120
 62 
 63 typedef struct apsect {
 64   Char base [MAX_APS_BASE+1];
 65   Char sect [MAX_APS_SECT+1]; 
 66 } APSect, PNTR APSectPtr;
 67 
 68 
 69 /* basic operations */
 70 extern Boolean APOpenSection (CharPtr file, CharPtr sect, APSectPtr sp);
 71 extern void APForEachKey (APSectPtr sp, void (*proc) (CharPtr key));
 72 extern Boolean APDeleteSection (APSectPtr sp); /* delete subsections first! */
 73 extern Boolean APFindKey (APSectPtr sp, CharPtr key);
 74 extern Boolean APDeleteKey (APSectPtr sp, CharPtr key);
 75 extern Boolean APGetKeyValue (APSectPtr sp, CharPtr key, CharPtr PNTR pval);
 76 extern Boolean APSetKeyValue (APSectPtr sp, CharPtr key, CharPtr val);
 77 
 78 /* subsections */
 79 extern Boolean APCreateSubsection (APSectPtr sp, CharPtr ss, APSectPtr ssp);
 80 extern Boolean APLookupSubsection (APSectPtr sp, CharPtr ss, APSectPtr ssp);
 81 extern Boolean APDeleteSubsection (APSectPtr sp, CharPtr ss);
 82 extern void APForEachSubsection (APSectPtr sp, void (*proc) (CharPtr ss));
 83 
 84 /* font dir hacks ??? */
 85 extern Boolean APFindEntry (APSectPtr sp, CharPtr ss, Int2Ptr pindex);
 86 extern Boolean APEntrySubsection (APSectPtr sp, Int2 index, APSectPtr ssp);
 87 
 88 /* save/restore */
 89 extern Boolean APArchiveBoolean (Boolean writep, APSectPtr sp, CharPtr key, BoolPtr pb);
 90 extern Boolean APArchiveEnum (Boolean writep, APSectPtr sp, CharPtr key, UIEnumPtr pe);
 91 extern Boolean APArchiveInt2 (Boolean writep, APSectPtr sp, CharPtr key, Int2Ptr pi2);
 92 extern Boolean APArchiveUint2 (Boolean writep, APSectPtr sp, CharPtr key, Uint2Ptr pu2);
 93 extern Boolean APArchiveInt4 (Boolean writep, APSectPtr sp, CharPtr key, Int4Ptr pi4);
 94 extern Boolean APArchiveUint4 (Boolean writep, APSectPtr sp, CharPtr key, Uint4Ptr pu4);
 95 extern Boolean APArchiveString (Boolean writep, APSectPtr sp, CharPtr key, CharPtr psb, Int2 bsz);
 96 
 97 #define ARC_WRITE   TRUE
 98 #define ARC_READ    FALSE
 99 
100 /* utils */
101 extern CharPtr APArrayIndexKey(CharPtr key, Int4 i);
102 
103 #endif /* ndef _APPARAM_ */
104 

source navigation ]   [ diff markup ]   [ identifier search ]   [ freetext search ]   [ file search ]  

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.