Main Page | Class List | Directories | File List | Class Members | File Members

pdbcoord.h

Go to the documentation of this file.
00001 /*
00002  * Copyright (C) 2004-2005 by David J. Hardy.  All rights reserved.
00003  */
00004 
00025 #ifndef MDIO_PDBCOORD_H
00026 #define MDIO_PDBCOORD_H
00027 
00028 #include "adt/list.h"
00029 #include "mdio/file.h"
00030 #include "mdapi/mdtypes.h"
00031 
00032 #ifdef __cplusplus
00033 extern "C" {
00034 #endif
00035 
00040   typedef struct mdio_Pdbcoord_t {
00041     mdio_File file;
00042     adt_List dvec;
00043     adt_List atom;
00044   } mdio_Pdbcoord;
00045 
00046 
00057   typedef struct mdio_Pdbatom_t {
00058     /*
00059      *                        definition                         columns
00060      */
00061     char record[8];  
00062     char serial[8];  
00063     char name[8];    
00064     char altLoc[4];  
00065     char resName[4]; 
00066     char chainID[4]; 
00067     char resSeq[8];  
00068     char iCode[4];   
00069     float occupancy; 
00070     float tempFactor;
00071     char segID[8];   
00072     char element[4]; 
00073     char charge[4];  
00074   } mdio_Pdbatom;
00075 
00076 
00077 /* constructor and destructor */
00078 
00086   mdio_Pdbcoord *mdio_createPdbcoord(void);
00087 
00088 
00098   void mdio_destroyPdbcoord(mdio_Pdbcoord *);
00099 
00100 
00101 /* reading file and obtaining data */
00102 
00116   int mdio_readPdbcoord(mdio_Pdbcoord *, const char *name, int n_expect);
00117 
00118 
00128   MD_Dvec *mdio_getPdbcoord(mdio_Pdbcoord *, int *nelems);
00129 
00130 
00140   mdio_Pdbatom *mdio_getAtomPdbcoord(mdio_Pdbcoord *, int *nelems);
00141 
00142 
00143 /* providing data and writing files */
00144 
00156   int mdio_setPdbcoord(mdio_Pdbcoord *, MD_Dvec *dvec, int nelems);
00157 
00158 
00170   int mdio_setAtomPdbcoord(mdio_Pdbcoord *, mdio_Pdbatom *atom, int nelems);
00171 
00172 
00184   int mdio_writePdbcoord(mdio_Pdbcoord *, const char *name);
00185 
00186 
00187 /* constructor and destructor for pre-allocated mdio_Pdbcoord object */
00188 
00194   int mdio_initializePdbcoord(mdio_Pdbcoord *);
00195 
00196 
00202   void mdio_cleanupPdbcoord(mdio_Pdbcoord *);
00203 
00204 #ifdef __cplusplus
00205 }
00206 #endif
00207 
00208 #endif /* MDIO_PDBCOORD_H */

Generated on Mon Sep 26 10:55:18 2005 for MDX by  doxygen 1.4.4