inc/hgGene.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 /* hgGene.h was originally generated by the autoSql program, which also 
00007  * generated hgGene.c and hgGene.sql.  This header links the database and the RAM 
00008  * representation of objects. */
00009 
00010 struct geneFinder
00011 /* A gene finding program. */
00012     {
00013     struct geneFinder *next;  /* Next in singly linked list. */
00014     unsigned id;        /* Unique ID */
00015     char *name; /* Name of gene finder */
00016     };
00017 
00018 void geneFinderStaticLoad(char **row, struct geneFinder *ret);
00019 /* Load a row from geneFinder table into ret.  The contents of ret will
00020  * be replaced at the next call to this function. */
00021 
00022 struct geneFinder *geneFinderLoad(char **row);
00023 /* Load a geneFinder from row fetched with select * from geneFinder
00024  * from database.  Dispose of this with geneFinderFree(). */
00025 
00026 struct geneFinder *geneFinderCommaIn(char **pS);
00027 /* Create a geneFinder out of a comma separated string. */
00028 
00029 void geneFinderFree(struct geneFinder **pEl);
00030 /* Free a single dynamically allocated geneFinder such as created
00031  * with geneFinderLoad(). */
00032 
00033 void geneFinderFreeList(struct geneFinder **pList);
00034 /* Free a list of dynamically allocated geneFinder's */
00035 
00036 void geneFinderOutput(struct geneFinder *el, FILE *f, char sep, char lastSep);
00037 /* Print out geneFinder.  Separate fields with sep. Follow last field with lastSep. */
00038 
00039 #define geneFinderTabOut(el,f) geneFinderOutput(el,f,'\t','\n');
00040 /* Print out geneFinder as a line in a tab-separated file. */
00041 
00042 #define geneFinderCommaOut(el,f) geneFinderOutput(el,f,',',',');
00043 /* Print out geneFinder as a comma separated list including final comma. */
00044 
00045 struct hgGene
00046 /* A gene prediction */
00047     {
00048     struct hgGene *next;  /* Next in singly linked list. */
00049     unsigned id;        /* Unique ID */
00050     char *name; /* Name of gene */
00051     unsigned geneFinder;        /* Program that made prediction */
00052     unsigned startBac;  /* Bac this starts in */
00053     unsigned startPos;  /* Position within bac where starts */
00054     unsigned endBac;    /* Bac this ends in */
00055     unsigned endPos;    /* Position withing bac where ends */
00056     signed char orientation;    /* Orientation relative to start bac */
00057     unsigned transcriptCount;   /* Number of transcripts */
00058     unsigned *transcripts;      /* Array of transcripts */
00059     };
00060 
00061 struct hgGene *hgGeneLoad(char **row);
00062 /* Load a hgGene from row fetched with select * from hgGene
00063  * from database.  Dispose of this with hgGeneFree(). */
00064 
00065 struct hgGene *hgGeneCommaIn(char **pS);
00066 /* Create a hgGene out of a comma separated string. */
00067 
00068 void hgGeneFree(struct hgGene **pEl);
00069 /* Free a single dynamically allocated hgGene such as created
00070  * with hgGeneLoad(). */
00071 
00072 void hgGeneFreeList(struct hgGene **pList);
00073 /* Free a list of dynamically allocated hgGene's */
00074 
00075 void hgGeneOutput(struct hgGene *el, FILE *f, char sep, char lastSep);
00076 /* Print out hgGene.  Separate fields with sep. Follow last field with lastSep. */
00077 
00078 #define hgGeneTabOut(el,f) hgGeneOutput(el,f,'\t','\n');
00079 /* Print out hgGene as a line in a tab-separated file. */
00080 
00081 #define hgGeneCommaOut(el,f) hgGeneOutput(el,f,',',',');
00082 /* Print out hgGene as a comma separated list including final comma. */
00083 
00084 struct hgTranscript
00085 /* A transcript prediction */
00086     {
00087     struct hgTranscript *next;  /* Next in singly linked list. */
00088     unsigned id;        /* Unique ID */
00089     char *name; /* Name of transcript */
00090     unsigned hgGene;    /* Gene this is in */
00091     unsigned startBac;  /* Bac this starts in */
00092     unsigned startPos;  /* Position within bac where starts */
00093     unsigned endBac;    /* Bac this ends in */
00094     unsigned endPos;    /* Position withing bac where ends */
00095     unsigned cdsStartBac;       /* Start of coding region. */
00096     unsigned cdsStartPos;       /* Start of coding region. */
00097     unsigned cdsEndBac; /* End of coding region. */
00098     unsigned cdsEndPos; /* End of coding region. */
00099     signed char orientation;    /* Orientation relative to start bac */
00100     unsigned exonCount; /* Number of exons */
00101     unsigned *exonStartBacs;    /* Exon start positions */
00102     unsigned *exonStartPos;     /* Exon start positions */
00103     unsigned *exonEndBacs;      /* Exon start positions */
00104     unsigned *exonEndPos;       /* Exon start positions */
00105     };
00106 
00107 struct hgTranscript *hgTranscriptLoad(char **row);
00108 /* Load a hgTranscript from row fetched with select * from hgTranscript
00109  * from database.  Dispose of this with hgTranscriptFree(). */
00110 
00111 struct hgTranscript *hgTranscriptCommaIn(char **pS);
00112 /* Create a hgTranscript out of a comma separated string. */
00113 
00114 void hgTranscriptFree(struct hgTranscript **pEl);
00115 /* Free a single dynamically allocated hgTranscript such as created
00116  * with hgTranscriptLoad(). */
00117 
00118 void hgTranscriptFreeList(struct hgTranscript **pList);
00119 /* Free a list of dynamically allocated hgTranscript's */
00120 
00121 void hgTranscriptOutput(struct hgTranscript *el, FILE *f, char sep, char lastSep);
00122 /* Print out hgTranscript.  Separate fields with sep. Follow last field with lastSep. */
00123 
00124 #define hgTranscriptTabOut(el,f) hgTranscriptOutput(el,f,'\t','\n');
00125 /* Print out hgTranscript as a line in a tab-separated file. */
00126 
00127 #define hgTranscriptCommaOut(el,f) hgTranscriptOutput(el,f,',',',');
00128 /* Print out hgTranscript as a comma separated list including final comma. */
00129 

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