ARB
|
Go to the source code of this file.
Classes | |
struct | prettyopts |
Macros | |
#define | short int |
#define | NEWLINE '\n' |
#define | false 0 |
#define | true 1 |
#define | min(a, b) (a<b)?a:b |
#define | max(a, b) (a>b)?a:b |
#define | skipwhitespace(string) {while (*string <= ' ' && *string != 0) string++;} |
#define | is_upper(c) ('A'<=(c) && (c)<='Z') |
#define | is_lower(c) ('a'<=(c) && (c)<='z') |
#define | to_lower(c) ((char)(is_upper(c) ? (c)+' ' : (c))) |
#define | to_upper(c) ((char)(is_lower(c) ? (c)-' ' : (c))) |
#define | eFileNotFound -1 |
#define | eNoData -2 |
#define | eMemFull -3 |
#define | eItemNotFound -4 |
#define | eOneFormat -5 |
#define | eUnequalSize -6 |
#define | eFileCreate -7 |
#define | eUnknownFormat -8 |
#define | eOptionBad -9 |
#define | eASNerr -10 |
#define | ePipeStdin -11 |
#define | kListSequences -1 |
#define | kOtherSeq 0 |
#define | kDNA 1 |
#define | kRNA 2 |
#define | kNucleic 3 |
#define | kAmino 4 |
#define | kIG 1 |
#define | kGenBank 2 |
#define | kNBRF 3 |
#define | kEMBL 4 |
#define | kGCG 5 |
#define | kStrider 6 |
#define | kFitch 7 |
#define | kPearson 8 |
#define | kZuker 9 |
#define | kOlsen 10 |
#define | kPhylip2 11 |
#define | kPhylip4 12 |
#define | kPhylip3 kPhylip4 |
#define | kPhylip kPhylip4 |
#define | kPlain 13 /* keep this at #13 */ |
#define | kPIR 14 |
#define | kMSF 15 |
#define | kASN1 16 |
#define | kPAUP 17 |
#define | kPretty 18 |
#define | kMaxFormat 18 |
#define | kMinFormat 1 |
#define | kNoformat -1 /* format not tested */ |
#define | kUnknown 0 /* format not determinable */ |
#define | kASNseqentry 51 |
#define | kASNseqset 52 |
#define | kPhylipInterleave 61 |
#define | kPhylipSequential 62 |
#define | gPrettyInit(p) |
#define | seqchecksum CRC32checksum |
Typedefs | |
typedef char | boolean |
Functions | |
short | seqFileFormat (const char *filename, long *skiplines, short *error) |
short | seqFileFormatFp (FILE *fseq, long *skiplines, short *error) |
char * | listSeqs (const char *filename, const long skiplines, const short format, short *nseq, short *error) |
char * | readSeq (const short whichEntry, const char *filename, const long skiplines, const short format, long *seqlen, short *nseq, short *error, char *seqid) |
char * | readSeqFp (const short whichEntry_, FILE *fp_, const long skiplines_, const short format_, long *seqlen_, short *nseq_, short *error_, char *seqid_) |
short | writeSeq (FILE *outf, const char *seq, const long seqlen, const short outform, const char *seqid) |
unsigned long | CRC32checksum (const char *seq, const long seqlen, unsigned long *checktotal) |
unsigned long | GCGchecksum (const char *seq, const long seqlen, unsigned long *checktotal) |
short | getseqtype (const char *seq, const long seqlen) |
char * | compressSeq (const char gapc, const char *seq, const long seqlen, long *newlen) |
int | Strcasecmp (const char *a, const char *b) |
int | Strncasecmp (const char *a, const char *b, long maxn) |
Variables | |
prettyopts | gPretty |
#define short int |
Definition at line 8 of file ureadseq.h.
Referenced by AW_window::create_text_field(), gb_make_main_idx(), main(), and AW_window::refresh_toggle_field().
#define NEWLINE '\n' |
Definition at line 12 of file ureadseq.h.
Referenced by dumpSeqList().
#define false 0 |
Definition at line 13 of file ureadseq.h.
#define true 1 |
Definition at line 14 of file ureadseq.h.
#define min | ( | a, | |
b | |||
) | (a<b)?a:b |
Definition at line 15 of file ureadseq.h.
#define max | ( | a, | |
b | |||
) | (a>b)?a:b |
Definition at line 16 of file ureadseq.h.
Definition at line 17 of file ureadseq.h.
Referenced by main(), parseformat(), readMSF(), readPAUPinterleaved(), readPAUPsequential(), readPhylipInterleaved(), readPhylipSequential(), and writeSeq().
Definition at line 20 of file ureadseq.h.
#define is_lower | ( | c | ) | ('a'<=(c) && (c)<='z') |
Definition at line 21 of file ureadseq.h.
Definition at line 22 of file ureadseq.h.
Referenced by main(), and parseformat().
Definition at line 23 of file ureadseq.h.
Referenced by CRC32checksum(), GCGchecksum(), getseqtype(), main(), Strcasecmp(), and Strncasecmp().
#define eFileNotFound -1 |
Definition at line 27 of file ureadseq.h.
Referenced by erralert(), readSeqMain(), and seqFileFormatFp().
#define eNoData -2 |
Definition at line 28 of file ureadseq.h.
Referenced by erralert(), and readSeqMain().
#define eMemFull -3 |
Definition at line 29 of file ureadseq.h.
Referenced by addseq(), erralert(), and main().
#define eItemNotFound -4 |
Definition at line 30 of file ureadseq.h.
Referenced by erralert(), and main().
#define eOneFormat -5 |
Definition at line 31 of file ureadseq.h.
Referenced by erralert(), and main().
#define eUnequalSize -6 |
Definition at line 32 of file ureadseq.h.
Referenced by erralert(), and main().
#define eFileCreate -7 |
Definition at line 33 of file ureadseq.h.
Referenced by erralert(), main(), and readopt().
#define eUnknownFormat -8 |
Definition at line 34 of file ureadseq.h.
Referenced by erralert(), readSeq(), readSeqFp(), and readSeqMain().
#define eOptionBad -9 |
Definition at line 35 of file ureadseq.h.
Referenced by readopt().
#define eASNerr -10 |
Definition at line 36 of file ureadseq.h.
Referenced by erralert().
#define ePipeStdin -11 |
Definition at line 37 of file ureadseq.h.
Referenced by erralert(), and main().
#define kListSequences -1 |
Definition at line 40 of file ureadseq.h.
Referenced by listSeqs(), readLoop(), readMSF(), readOlsen(), readPAUPinterleaved(), readPAUPsequential(), readPhylipInterleaved(), readPlain(), readSeq(), readSeqFp(), and readUWGCG().
#define kOtherSeq 0 |
Definition at line 43 of file ureadseq.h.
Referenced by getseqtype(), main(), seqFileFormatFp(), and writeSeq().
#define kDNA 1 |
Definition at line 44 of file ureadseq.h.
Referenced by getseqtype(), main(), seqFileFormatFp(), and writeSeq().
#define kRNA 2 |
Definition at line 45 of file ureadseq.h.
Referenced by getseqtype(), main(), seqFileFormatFp(), and writeSeq().
#define kNucleic 3 |
Definition at line 46 of file ureadseq.h.
Referenced by getseqtype(), main(), seqFileFormatFp(), and writeSeq().
#define kAmino 4 |
Definition at line 47 of file ureadseq.h.
Referenced by getseqtype(), main(), seqFileFormatFp(), and writeSeq().
#define kIG 1 |
Definition at line 50 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kGenBank 2 |
Definition at line 51 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kNBRF 3 |
Definition at line 52 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kEMBL 4 |
Definition at line 53 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kGCG 5 |
Definition at line 54 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kStrider 6 |
Definition at line 55 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kFitch 7 |
Definition at line 56 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPearson 8 |
Definition at line 57 of file ureadseq.h.
Referenced by chooseFormat(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kZuker 9 |
Definition at line 58 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kOlsen 10 |
Definition at line 59 of file ureadseq.h.
Referenced by readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPhylip2 11 |
Definition at line 60 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPhylip4 12 |
Definition at line 61 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPhylip3 kPhylip4 |
Definition at line 62 of file ureadseq.h.
#define kPhylip kPhylip4 |
Definition at line 63 of file ureadseq.h.
Referenced by formatstr(), main(), and seqFileFormatFp().
#define kPlain 13 /* keep this at #13 */ |
Definition at line 64 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPIR 14 |
Definition at line 65 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kMSF 15 |
Definition at line 66 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kASN1 16 |
Definition at line 67 of file ureadseq.h.
Referenced by formatstr(), main(), seqFileFormatFp(), and writeSeq().
#define kPAUP 17 |
Definition at line 68 of file ureadseq.h.
Referenced by main(), readSeqMain(), seqFileFormatFp(), and writeSeq().
#define kPretty 18 |
Definition at line 69 of file ureadseq.h.
Referenced by main(), and writeSeq().
#define kMaxFormat 18 |
Definition at line 71 of file ureadseq.h.
Referenced by chooseFormat(), formatstr(), parseformat(), readSeq(), readSeqFp(), and usage().
#define kMinFormat 1 |
Definition at line 72 of file ureadseq.h.
Referenced by chooseFormat(), and usage().
#define kNoformat -1 /* format not tested */ |
Definition at line 73 of file ureadseq.h.
Referenced by chooseFormat(), main(), parseformat(), resetGlobals(), and seqFileFormatFp().
#define kUnknown 0 /* format not determinable */ |
Definition at line 74 of file ureadseq.h.
Referenced by seqFileFormatFp(), and writeSeq().
#define kASNseqentry 51 |
Definition at line 77 of file ureadseq.h.
Referenced by formatstr(), main(), and seqFileFormatFp().
#define kASNseqset 52 |
Definition at line 78 of file ureadseq.h.
Referenced by formatstr(), main(), and seqFileFormatFp().
#define kPhylipInterleave 61 |
Definition at line 80 of file ureadseq.h.
Referenced by formatstr().
#define kPhylipSequential 62 |
Definition at line 81 of file ureadseq.h.
Referenced by formatstr().
#define gPrettyInit | ( | p | ) |
Definition at line 95 of file ureadseq.h.
Referenced by resetGlobals().
#define seqchecksum CRC32checksum |
Definition at line 140 of file ureadseq.h.
Referenced by main(), and writeSeq().
Definition at line 11 of file ureadseq.h.
Definition at line 1151 of file ureadseq.c.
References format(), and seqFileFormatFp().
Referenced by main().
Definition at line 1165 of file ureadseq.c.
References ReadSeqVars::done, eFileNotFound, format(), getseqtype(), kAmino, kASN1, kASNseqentry, kASNseqset, kDNA, kEMBL, kFitch, kGCG, kGenBank, kIG, kMSF, kNBRF, kNoformat, kNucleic, kOlsen, kOtherSeq, kPAUP, kPearson, kPhylip, kPhylip2, kPhylip4, kPIR, kPlain, kRNA, kStrider, kUnknown, kZuker, ReadSeqVars::linestart, ReadOneLine, seq, and ReadSeqVars::sp.
Referenced by seqFileFormat().
char* listSeqs | ( | const char * | filename, |
const long | skiplines, | ||
const short | format, | ||
short * | nseq, | ||
short * | error | ||
) |
Definition at line 1134 of file ureadseq.c.
References kListSequences, readSeq(), ReadSeqVars::seqid, and ReadSeqVars::seqlen.
Referenced by main().
char* readSeq | ( | const short | whichEntry, |
const char * | filename, | ||
const long | skiplines, | ||
const short | format, | ||
long * | seqlen, | ||
short * | nseq, | ||
short * | error, | ||
char * | seqid | ||
) |
Definition at line 1082 of file ureadseq.c.
References ReadSeqVars::addit, ReadSeqVars::allDone, ReadSeqVars::choice, ReadSeqVars::err, eUnknownFormat, ReadSeqVars::f, ReadSeqVars::filestart, ReadSeqVars::fname, ReadSeqVars::isseqchar, isSeqChar(), ReadSeqVars::isseqcharfirst8, kListSequences, kMaxFormat, kStartLength, ReadSeqVars::maxseq, ReadSeqVars::nseq, readSeqMain(), ReadSeqVars::seq, ReadSeqVars::seqid, and ReadSeqVars::seqlen.
Referenced by listSeqs(), and main().
char* readSeqFp | ( | const short | whichEntry_, |
FILE * | fp_, | ||
const long | skiplines_, | ||
const short | format_, | ||
long * | seqlen_, | ||
short * | nseq_, | ||
short * | error_, | ||
char * | seqid_ | ||
) |
Definition at line 1033 of file ureadseq.c.
References ReadSeqVars::addit, ReadSeqVars::allDone, ReadSeqVars::choice, ReadSeqVars::err, eUnknownFormat, ReadSeqVars::f, ReadSeqVars::filestart, ReadSeqVars::fname, ReadSeqVars::isseqchar, isSeqChar(), ReadSeqVars::isseqcharfirst8, kListSequences, kMaxFormat, kStartLength, ReadSeqVars::maxseq, ReadSeqVars::nseq, readSeqMain(), ReadSeqVars::seq, ReadSeqVars::seqid, and ReadSeqVars::seqlen.
Referenced by main().
short writeSeq | ( | FILE * | outf, |
const char * | seq, | ||
const long | seqlen, | ||
const short | outform, | ||
const char * | seqid | ||
) |
added 31jan91
added 31jan91
Definition at line 1583 of file ureadseq.c.
References prettyopts::atseq, prettyopts::baseonlynum, prettyopts::domatch, fputc(), prettyopts::gapchar, GCGchecksum(), getseqtype(), kAmino, kASN1, kDNA, kEMBL, kFitch, kGCG, kGenBank, kIG, kMaxseqwidth, kMSF, kNBRF, kNucleic, kOlsen, kOtherSeq, kPAUP, kPearson, kPhylip2, kPhylip4, kPIR, kPlain, kPretty, kRNA, kStrider, kUnknown, kZuker, prettyopts::matchchar, min, prettyopts::nameleft, prettyopts::nameright, prettyopts::nametop, prettyopts::namewidth, prettyopts::numleft, prettyopts::numline, prettyopts::numright, s, seqchecksum, ReadSeqVars::seqlen, prettyopts::seqwidth, skipwhitespace, prettyopts::spacer, prettyopts::tab, and tab().
Referenced by main().
Definition at line 1492 of file ureadseq.c.
References ReadSeqVars::seqlen, and to_upper.
Definition at line 1420 of file ureadseq.c.
References ReadSeqVars::seqlen, and to_upper.
Referenced by main(), and writeSeq().
Definition at line 1511 of file ureadseq.c.
References kAmino, kDNA, kNucleic, kOtherSeq, kRNA, min, and to_upper.
Referenced by main(), seqFileFormatFp(), and writeSeq().
Definition at line 34 of file ureadseq.c.
Definition at line 48 of file ureadseq.c.
References diff(), and to_upper.
Referenced by checkopt().
prettyopts gPretty |
Definition at line 31 of file ureadseq.c.
Referenced by main(), readopt(), and resetGlobals().