inc/xa.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002  * Copyright (C) 2000 Jim Kent.  This source code may be freely used         *
00003  * for personal, academic, and non-profit purposes.  Commercial use          *
00004  * permitted only by explicit agreement with Jim Kent (jim_kent@pacbell.net) *
00005  *****************************************************************************/
00006 /* xa.h - manage cross species alignments stored in database. */
00007 #ifndef XA_H
00008 #define XA_H
00009 
00010 struct xaAli
00011 /* This contains information about one xeno alignment. */
00012     {
00013     struct xaAli *next;
00014     char *name;
00015     char *query;
00016     int qStart, qEnd;
00017     char qStrand;
00018     char *target;
00019     int tStart, tEnd;
00020     char tStrand;
00021     int milliScore;
00022     int symCount;
00023     char *qSym, *tSym, *hSym;
00024     };
00025 
00026 void xaAliFree(struct xaAli *xa);
00027 /* Free up a single xaAli. */
00028 
00029 void xaAliFreeList(struct xaAli **pXa);
00030 /* Free up a list of xaAlis. */
00031 
00032 int xaAliCmpTarget(const void *va, const void *vb);
00033 /* Compare two xaAli's to sort by ascending target positions. */
00034 
00035 FILE *xaOpenVerify(char *fileName);
00036 /* Open file, verify it's the right type, and
00037  * position file pointer for first xaReadNext(). */
00038 
00039 FILE *xaIxOpenVerify(char *fileName);
00040 /* Open file, verify that it's a good xa index. */
00041 
00042 struct xaAli *xaReadNext(FILE *f, boolean condensed);
00043 /* Read next xaAli from file. If condensed
00044  * don't fill int query, target, qSym, tSym, or hSym. */
00045 
00046 struct xaAli *xaReadRange(char *rangeIndexFileName, char *dataFileName, 
00047     int start, int end, boolean condensed);
00048 /* Return list of all xaAlis that range from start to end.  If condensed
00049  * don't fill int query, qSym, tSym, or hSym. */
00050 
00051 struct xaAli *xaRdRange(FILE *ix, FILE *data, 
00052     int start, int end, boolean condensed);
00053 /* Like xaReadRange but pass in open files rather than file names. */
00054 
00055 char *xaAlignSuffix();
00056 /* Return suffix of file with actual alignments. */
00057 
00058 char *xaChromIxSuffix();
00059 /* Return suffix of files that index xa's by chromosome position. */
00060 
00061 
00062 #endif /* XA_H */
00063 

Generated on Tue Dec 25 18:39:29 2007 for blat by  doxygen 1.5.2