1 /* objblock.h 2 * =========================================================================== 3 * 4 * PUBLIC DOMAIN NOTICE 5 * National Center for Biotechnology Information 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 have not placed any restriction on its use or reproduction. 13 * 14 * Although all reasonable efforts have been taken to ensure the accuracy 15 * and reliability of the software and data, the NLM and the U.S. 16 * Government do not and cannot warrant the performance or results that 17 * may be obtained by using this software or data. The NLM and the U.S. 18 * Government disclaim all warranties, express or implied, including 19 * warranties of performance, merchantability or fitness for any particular 20 * purpose. 21 * 22 * Please cite the author in any work or product based on this material. 23 * 24 * =========================================================================== 25 * 26 * File Name: objblock.h 27 * 28 * Author: James Ostell 29 * 30 * Version Creation Date: 4/1/91 31 * 32 * $Revision: 6.1 $ 33 * 34 * File Description: Object manager for module GenBank-General, 35 * EMBL-General, PIR-General, SWISSPROT-General 36 * 37 * Modifications: 38 * -------------------------------------------------------------------------- 39 * Date Name Description of modification 40 * ------- ---------- ----------------------------------------------------- 41 * 05-17-93 Schuler pdbblock.class renamed pdpblock.pdbclass because 42 * class is a C++ keyword. 43 * 44 * 45 * $Log: objblock.h,v $ 46 * Revision 6.1 2000/04/29 19:51:02 kans 47 * removed strange characters at end that prevented Mac compilation 48 * 49 * Revision 6.0 1997/08/25 18:49:30 madden 50 * Revision changed to 6.0 51 * 52 * Revision 4.1 1997/06/19 18:40:57 vakatov 53 * [WIN32,MSVC++] Adopted for the "NCBIOBJ.LIB" DLL'ization 54 * 55 * Revision 4.0 1995/07/26 13:48:06 ostell 56 * force revision to 4.0 57 * 58 * Revision 3.1 1995/05/15 21:22:00 ostell 59 * added Log line 60 * 61 * 62 * 63 * ========================================================================== 64 */ 65 66 #ifndef _NCBI_SeqBlock_ 67 #define _NCBI_SeqBlock_ 68 69 #ifndef _ASNTOOL_ 70 #include <asn.h> 71 #endif 72 #ifndef _NCBI_General_ 73 #include <objgen.h> 74 #endif 75 #ifndef _NCBI_Seqloc_ 76 #include <objloc.h> 77 #endif 78 79 #undef NLM_EXTERN 80 #ifdef NLM_IMPORT 81 #define NLM_EXTERN NLM_IMPORT 82 #else 83 #define NLM_EXTERN extern 84 #endif 85 86 #ifdef __cplusplus 87 extern "C" { 88 #endif 89 90 /***************************************************************************** 91 * 92 * loader 93 * 94 *****************************************************************************/ 95 NLM_EXTERN Boolean LIBCALL SeqBlockAsnLoad PROTO((void)); 96 97 /***************************************************************************** 98 * 99 * PirBlock - PIR specific data elements 100 * 101 *****************************************************************************/ 102 typedef struct pirblock { 103 Boolean had_punct; 104 CharPtr host, 105 source, 106 summary, 107 genetic, 108 includes, 109 placement, 110 superfamily, 111 cross_reference, 112 date, 113 seq_raw; 114 ValNodePtr keywords; 115 SeqIdPtr seqref; 116 } PirBlock, PNTR PirBlockPtr; 117 118 NLM_EXTERN PirBlockPtr LIBCALL PirBlockNew PROTO((void)); 119 NLM_EXTERN Boolean LIBCALL PirBlockAsnWrite PROTO((PirBlockPtr pbp, AsnIoPtr aip, AsnTypePtr atp)); 120 NLM_EXTERN PirBlockPtr LIBCALL PirBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 121 NLM_EXTERN PirBlockPtr LIBCALL PirBlockFree PROTO((PirBlockPtr pbp)); 122 123 /***************************************************************************** 124 * 125 * GBBlock - GenBank specific data elements 126 * 127 *****************************************************************************/ 128 typedef struct gbblock { 129 ValNodePtr extra_accessions, 130 keywords; 131 CharPtr source, 132 origin, 133 date, 134 div, 135 taxonomy; 136 DatePtr entry_date; 137 } GBBlock, PNTR GBBlockPtr; 138 139 NLM_EXTERN GBBlockPtr LIBCALL GBBlockNew PROTO((void)); 140 NLM_EXTERN Boolean LIBCALL GBBlockAsnWrite PROTO((GBBlockPtr gbp, AsnIoPtr aip, AsnTypePtr atp)); 141 NLM_EXTERN GBBlockPtr LIBCALL GBBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 142 NLM_EXTERN GBBlockPtr LIBCALL GBBlockFree PROTO((GBBlockPtr gbp)); 143 144 /***************************************************************************** 145 * 146 * SPBlock - SWISSPROT specific data elements 147 * 148 *****************************************************************************/ 149 typedef struct spblock { 150 Uint1 _class; 151 ValNodePtr extra_acc; 152 Boolean imeth; 153 ValNodePtr plasnm; 154 SeqIdPtr seqref; 155 ValNodePtr dbref; 156 ValNodePtr keywords; 157 NCBI_DatePtr created, 158 sequpd, 159 annotupd; 160 } SPBlock, PNTR SPBlockPtr; 161 162 NLM_EXTERN SPBlockPtr LIBCALL SPBlockNew PROTO((void)); 163 NLM_EXTERN Boolean LIBCALL SPBlockAsnWrite PROTO((SPBlockPtr sbp, AsnIoPtr aip, AsnTypePtr atp)); 164 NLM_EXTERN SPBlockPtr LIBCALL SPBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 165 NLM_EXTERN SPBlockPtr LIBCALL SPBlockFree PROTO((SPBlockPtr sbp)); 166 167 /***************************************************************************** 168 * 169 * EMBLBlock - EMBL specific data elements 170 * 171 *****************************************************************************/ 172 typedef struct emblxref { 173 Uint1 _class; 174 CharPtr name; /* NULL if class used */ 175 ValNodePtr id; /* ValNode->data.ptrvalue is an ObjectIdPtr */ 176 struct emblxref PNTR next; 177 } EMBLXref, PNTR EMBLXrefPtr; 178 179 typedef struct emblblock { 180 Uint1 _class, 181 div; /* 255 = not set */ 182 NCBI_DatePtr creation_date , 183 update_date; 184 ValNodePtr extra_acc; 185 ValNodePtr keywords; 186 EMBLXrefPtr xref; 187 } EMBLBlock, PNTR EMBLBlockPtr; 188 189 NLM_EXTERN EMBLBlockPtr LIBCALL EMBLBlockNew PROTO((void)); 190 NLM_EXTERN Boolean LIBCALL EMBLBlockAsnWrite PROTO((EMBLBlockPtr ebp, AsnIoPtr aip, AsnTypePtr atp)); 191 NLM_EXTERN EMBLBlockPtr LIBCALL EMBLBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 192 NLM_EXTERN EMBLBlockPtr LIBCALL EMBLBlockFree PROTO((EMBLBlockPtr ebp)); 193 194 /***************************************************************************** 195 * 196 * PRF-Block - PRF specific data emements 197 * by A.Ogiwara 198 *****************************************************************************/ 199 typedef struct prfextsrc { 200 CharPtr host; 201 CharPtr part; 202 CharPtr state; 203 CharPtr strain; 204 CharPtr taxon; 205 } PrfExtSrc, PNTR PrfExtSrcPtr; 206 207 typedef struct prfblock { 208 PrfExtSrcPtr extra_src; 209 ValNodePtr keywords; 210 } PrfBlock, PNTR PrfBlockPtr; 211 212 NLM_EXTERN PrfBlockPtr LIBCALL PrfBlockNew PROTO((void)); 213 NLM_EXTERN Boolean LIBCALL PrfBlockAsnWrite PROTO((PrfBlockPtr pbp, AsnIoPtr aip, AsnTypePtr atp)); 214 NLM_EXTERN PrfBlockPtr LIBCALL PrfBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 215 NLM_EXTERN PrfBlockPtr LIBCALL PrfBlockFree PROTO((PrfBlockPtr pbp)); 216 217 218 /***************************************************************************** 219 * 220 * PDB-Block - PDB specific data emements 221 * 222 *****************************************************************************/ 223 224 typedef struct pdbreplace { 225 DatePtr date; 226 ValNodePtr ids; 227 } 228 PdbRep, PNTR PdbRepPtr; 229 230 typedef struct pdbblock { 231 DatePtr deposition ; 232 CharPtr pdbclass ; 233 ValNodePtr compound ; 234 ValNodePtr source ; 235 CharPtr exp_method ; 236 PdbRepPtr replace; 237 } 238 PdbBlock, PNTR PdbBlockPtr; 239 240 NLM_EXTERN PdbBlockPtr LIBCALL PdbBlockNew PROTO((void)); 241 NLM_EXTERN Boolean LIBCALL PdbBlockAsnWrite PROTO((PdbBlockPtr pdbp, AsnIoPtr aip, AsnTypePtr atp)); 242 NLM_EXTERN PdbBlockPtr LIBCALL PdbBlockAsnRead PROTO((AsnIoPtr aip, AsnTypePtr atp)); 243 NLM_EXTERN PdbBlockPtr LIBCALL PdbBlockFree PROTO((PdbBlockPtr pdbp)); 244 245 #ifdef __cplusplus 246 } 247 #endif 248 249 #undef NLM_EXTERN 250 #ifdef NLM_EXPORT 251 #define NLM_EXTERN NLM_EXPORT 252 #else 253 #define NLM_EXTERN 254 #endif 255 #endif 256 257 258