void adsout_write( fields *f, FILE *fp, param *p, unsigned long refnum ) { int type; fields_clearused( f ); type = get_type( f ); output_people( fp, f, "AUTHOR", "AUTHOR:ASIS", "AUTHOR:CORP", "%A", LEVEL_MAIN ); output_people( fp, f, "EDITOR", "EDITOR:ASIS", "EDITOR:CORP", "%E", LEVEL_ANY ); output_easy( fp, f, "TITLE", "%T", LEVEL_ANY ); if ( type==TYPE_ARTICLE || type==TYPE_MAGARTICLE ) output_title( fp, f, "TITLE", "SUBTITLE", "%J", LEVEL_HOST ); output_date( fp, f, "%D", LEVEL_ANY ); output_easy( fp, f, "VOLUME", "%V", LEVEL_ANY ); output_easy( fp, f, "ISSUE", "%N", LEVEL_ANY ); output_easy( fp, f, "NUMBER", "%N", LEVEL_ANY ); output_easy( fp, f, "LANGUAGE", "%M", LEVEL_ANY ); output_easyall( fp, f, "NOTES", "%X", LEVEL_ANY ); output_easy( fp, f, "ABSTRACT", "%B", LEVEL_ANY ); output_keys( fp, f, "KEYWORD", "%K", LEVEL_ANY ); output_easyall( fp, f, "URL", "%U", LEVEL_ANY ); output_easyall( fp, f, "FILEATTACH", "%U", LEVEL_ANY ); output_easyall( fp, f, "FIGATTACH", "%U", LEVEL_ANY ); output_pages( fp, f ); output_easyall( fp, f, "DOI", "%Y", LEVEL_ANY ); fprintf( fp, "%%W PHY\n%%G AUTHOR\n" ); output_Rtag( fp, f, "%R", type ); fprintf( fp, "\n" ); fflush( fp ); }
static void output_allpeople( FILE *fp, fields *f, int type ) { output_people( fp, f, "AUTHOR", "AU", LEVEL_MAIN ); output_easyall( fp, f, "AUTHOR:CORP", "AU", LEVEL_MAIN ); output_easyall( fp, f, "AUTHOR:ASIS", "AU", LEVEL_MAIN ); output_people( fp, f, "AUTHOR", "A2", LEVEL_HOST ); output_easyall( fp, f, "AUTHOR:CORP", "A2", LEVEL_HOST ); output_easyall( fp, f, "AUTHOR:ASIS", "A2", LEVEL_HOST ); output_people( fp, f, "AUTHOR", "A3", LEVEL_SERIES ); output_easyall( fp, f, "AUTHOR:CORP", "A3", LEVEL_SERIES ); output_easyall( fp, f, "AUTHOR:ASIS", "A3", LEVEL_SERIES ); output_people( fp, f, "EDITOR", "ED", LEVEL_MAIN ); output_easyall( fp, f, "EDITOR:CORP", "ED", LEVEL_MAIN ); output_easyall( fp, f, "EDITOR:ASIS", "ED", LEVEL_MAIN ); if ( type_is_element( type ) ) { output_people( fp, f, "EDITOR", "ED", LEVEL_HOST ); output_easyall( fp, f, "EDITOR:CORP", "ED", LEVEL_HOST ); output_easyall( fp, f, "EDITOR:ASIS", "ED", LEVEL_HOST ); } else { output_people( fp, f, "EDITOR", "A3", LEVEL_HOST ); output_easyall( fp, f, "EDITOR:CORP", "A3", LEVEL_HOST ); output_easyall( fp, f, "EDITOR:ASIS", "A3", LEVEL_HOST ); } output_people( fp, f, "EDITOR", "A3", LEVEL_SERIES ); output_easyall( fp, f, "EDITOR:CORP", "A3", LEVEL_SERIES ); output_easyall( fp, f, "EDITOR:ASIS", "A3", LEVEL_SERIES ); }
void bibtexout_write( fields *info, FILE *fp, param *p, unsigned long refnum ) { int type; fields_clearused( info ); type = bibtexout_type( info, "", refnum, p ); output_type( fp, type, p->format_opts ); if ( !( p->format_opts & BIBOUT_DROPKEY ) ) output_citekey( fp, info, refnum, p->format_opts ); output_people( fp, info, refnum, "AUTHOR", "AUTHOR:CORP", "AUTHOR:ASIS", "author", 0, p->format_opts ); output_people( fp, info, refnum, "EDITOR", "EDITOR:CORP", "EDITOR:ASIS", "editor", -1, p->format_opts ); output_people( fp, info, refnum, "TRANSLATOR", "TRANSLATOR:CORP", "TRANSLATOR:ASIS", "translator", -1, p->format_opts ); /* item=main level title */ if ( type==TYPE_INBOOK ) output_title( fp, info, refnum, "chapter", 0, p->format_opts ); else output_title( fp, info, refnum, "title", 0, p->format_opts ); /* item=host level title */ if ( type==TYPE_ARTICLE ) output_title( fp, info, refnum, "journal", 1, p->format_opts ); else if ( type==TYPE_INBOOK ) { output_title( fp, info, refnum, "title", 1, p->format_opts ); output_title( fp, info, refnum, "series", 2, p->format_opts ); } else if ( type==TYPE_INPROCEEDINGS || type==TYPE_INCOLLECTION ) { output_title( fp, info, refnum, "booktitle", 1, p->format_opts ); output_title( fp, info, refnum, "series", 2, p->format_opts ); } else if ( type==TYPE_PHDTHESIS || type==TYPE_MASTERSTHESIS ) { output_title( fp, info, refnum, "series", 1, p->format_opts ); } else if ( type==TYPE_BOOK || type==TYPE_COLLECTION || type==TYPE_PROCEEDINGS ) output_title( fp, info, refnum, "series", 1, p->format_opts ); output_date( fp, info, refnum, p->format_opts ); output_simple( fp, info, "EDITION", "edition", p->format_opts ); output_simple( fp, info, "PUBLISHER", "publisher", p->format_opts ); output_simple( fp, info, "ADDRESS", "address", p->format_opts ); output_simple( fp, info, "VOLUME", "volume", p->format_opts ); output_issue_number( fp, info, p->format_opts ); /* output_simple( fp, info, "ISSUE", "issue", p->format_opts ); output_simple( fp, info, "NUMBER", "number", p->format_opts );s*/ output_pages( fp, info, refnum, p->format_opts ); output_simpleall( fp, info, "KEYWORD", "keywords", p->format_opts ); output_simple( fp, info, "CONTENTS", "contents", p->format_opts ); output_simple( fp, info, "ABSTRACT", "abstract", p->format_opts ); output_simple( fp, info, "LOCATION", "location", p->format_opts ); output_simple( fp, info, "DEGREEGRANTOR", "school", p->format_opts ); output_simple( fp, info, "DEGREEGRANTOR:ASIS", "school", p->format_opts ); output_simple( fp, info, "DEGREEGRANTOR:CORP", "school", p->format_opts ); output_simpleall( fp, info, "NOTES", "note", p->format_opts ); output_simpleall( fp, info, "ANNOTE", "annote", p->format_opts ); output_simple( fp, info, "ISBN", "isbn", p->format_opts ); output_simple( fp, info, "ISSN", "issn", p->format_opts ); output_simple( fp, info, "DOI", "doi", p->format_opts ); output_simpleall( fp, info, "URL", "url", p->format_opts ); output_fileattach( fp, info, p->format_opts ); output_arxiv( fp, info, p->format_opts ); output_pmid( fp, info, p->format_opts ); output_jstor( fp, info, p->format_opts ); output_simple( fp, info, "LANGUAGE", "language", p->format_opts ); if ( p->format_opts & BIBOUT_FINALCOMMA ) fprintf( fp, "," ); fprintf( fp, "\n}\n\n" ); fflush( fp ); }
void isiout_write( fields *f, FILE *fp, param *p, unsigned long refnum ) { int type = get_type( f ); if ( p->format_opts & BIBL_FORMAT_VERBOSE ) output_verbose( f, refnum ); output_type( fp, type ); output_people( fp, f, "AUTHOR", "AU", 0 ); output_easyall( fp, f, "AUTHOR:CORP", "AU", 0 ); output_easyall( fp, f, "AUTHOR:ASIS", "AU", 0 ); /* output_people( fp, f, "AUTHOR", "A2", 1 ); output_people( fp, f, "AUTHOR:CORP", "A2", 1 ); output_people( fp, f, "AUTHOR:ASIS", "A2", 1 ); output_people( fp, f, "AUTHOR", "A3", 2 ); output_people( fp, f, "AUTHOR:CORP", "A3", 2 ); output_people( fp, f, "AUTHOR:ASIS", "A3", 2 ); output_people( fp, f, "EDITOR", "ED", -1 ); output_people( fp, f, "EDITOR:CORP", "ED", -1 ); output_people( fp, f, "EDITOR:ASIS", "ED", -1 );*/ /* output_date( fp, f, refnum );*/ output_title( fp, f, "TI", 0 ); if ( type==TYPE_ARTICLE ) { output_title( fp, f, "SO", 1 ); output_abbrtitle( fp, f, "JI", 1 ); output_title( fp, f, "SE", 2 ); } else if ( type==TYPE_INBOOK ) { output_title( fp, f, "BT", 1 ); output_title( fp, f, "SE", 2 ); } else { /* type==BOOK */ output_title( fp, f, "SE", 1 ); } output_date( fp, f ); /* output_easy( fp, f, "PARTMONTH", "PD", -1 ); output_easy( fp, f, "PARTYEAR", "PY", -1 );*/ output_easy( fp, f, "PAGESTART", "BP", -1 ); output_easy( fp, f, "PAGEEND", "EP", -1 ); output_easy( fp, f, "ARTICLENUMBER", "AR", -1 ); /* output article number as pages */ output_easy( fp, f, "TOTALPAGES","PG", -1 ); output_easy( fp, f, "VOLUME", "VL", -1 ); output_easy( fp, f, "ISSUE", "IS", -1 ); output_easy( fp, f, "NUMBER", "IS", -1 ); output_easy( fp, f, "DOI", "DI", -1 ); output_easy( fp, f, "ISIREFNUM", "UT", -1 ); output_easy( fp, f, "LANGUAGE", "LA", -1 ); output_easy( fp, f, "ISIDELIVERNUM", "GA", -1 ); output_keywords( fp, f ); output_easy( fp, f, "ABSTRACT", "AB", -1 ); output_easy( fp, f, "TIMESCITED", "TC", -1 ); output_easy( fp, f, "NUMBERREFS", "NR", -1 ); output_easy( fp, f, "CITEDREFS", "CR", -1 ); output_easy( fp, f, "ADDRESS", "PI", -1 ); /* output_easy( fp, f, "PUBLISHER", "PB", -1 ); output_easy( fp, f, "DEGREEGRANTOR", "PB", -1 ); output_easy( fp, f, "ADDRESS", "CY", -1 ); output_easy( fp, f, "ABSTRACT", "AB", -1 ); output_easy( fp, f, "ISSN", "SN", -1 ); output_easy( fp, f, "ISBN", "SN", -1 ); output_easyall( fp, f, "URL", "UR", -1 ); output_easyall( fp, f, "FILEATTACH", "UR", -1 ); output_pubmed( fp, f, refnum ); output_easyall( fp, f, "NOTES", "N1", -1 ); output_easyall( fp, f, "REFNUM", "ID", -1 );*/ fprintf( fp, "ER\n\n" ); fflush( fp ); }
static void endout_write( fields *info, FILE *fp, param *p, unsigned long refnum ) { int type, status; fields_clearused( info ); type = get_type( info, p, refnum ); output_type( fp, type, p ); status = output_title( fp, info, "TITLE", "SUBTITLE", "%T", LEVEL_MAIN ); if ( status==0 ) output_title( fp, info, "SHORTTITLE", "SHORTSUBTITLE", "%T", LEVEL_MAIN ); else output_title( fp, info, "SHORTTITLE", "SHORTSUBTITLE", "%!", LEVEL_MAIN ); output_people( fp, info, "AUTHOR", "%A", LEVEL_MAIN ); output_people( fp, info, "EDITOR", "%E", LEVEL_MAIN ); if ( type==TYPE_ARTICLE || type==TYPE_MAGARTICLE || type==TYPE_ELECTRONICARTICLE || type==TYPE_NEWSARTICLE ) output_people( fp, info, "EDITOR", "%E", LEVEL_HOST ); else if ( type==TYPE_INBOOK || type==TYPE_INPROCEEDINGS ) { output_people( fp, info, "EDITOR", "%E", LEVEL_HOST ); } else { output_people( fp, info, "EDITOR", "%Y", LEVEL_HOST ); } output_people( fp, info, "TRANSLATOR", "%H", LEVEL_ANY ); output_people( fp, info, "AUTHOR", "%Y", LEVEL_SERIES ); output_people( fp, info, "EDITOR", "%Y", LEVEL_SERIES ); if ( type==TYPE_CASE ) output_easy( fp, info, "AUTHOR:CORP", "%I", LEVEL_MAIN ); else if ( type==TYPE_HEARING ) output_easyall( fp, info, "AUTHOR:CORP", "%S", LEVEL_MAIN ); else if ( type==TYPE_NEWSARTICLE ) output_people( fp, info, "REPORTER", "%A", LEVEL_MAIN ); else if ( type==TYPE_COMMUNICATION ) output_people( fp, info, "RECIPIENT", "%E", LEVEL_ANY ); else { output_easyall( fp, info, "AUTHOR:CORP", "%A", LEVEL_MAIN ); output_easyall( fp, info, "AUTHOR:ASIS", "%A", LEVEL_MAIN ); output_easyall( fp, info, "EDITOR:CORP", "%E", LEVEL_ANY ); output_easyall( fp, info, "EDITOR:ASIS", "%E", LEVEL_ANY ); output_easyall( fp, info, "TRANSLATOR:CORP", "%H", LEVEL_ANY ); output_easyall( fp, info, "TRANSLATOR:ASIS", "%H", LEVEL_ANY ); } if ( type==TYPE_ARTICLE || type==TYPE_MAGARTICLE || type==TYPE_ELECTRONICARTICLE || type==TYPE_NEWSARTICLE ) { status = output_title( fp, info, "TITLE", "SUBTITLE", "%J", LEVEL_HOST ); if ( status==0 ) status = output_title( fp, info, "SHORTTITLE", "SHORTSUBTITLE", "%J", LEVEL_HOST ); } else if ( type==TYPE_INBOOK || type==TYPE_INPROCEEDINGS ) { status = output_title( fp, info, "TITLE", "SUBTITLE", "%B", LEVEL_HOST ); if ( status==0 ) output_title( fp, info, "SHORTTITLE", "SHORTSUBTITLE", "%B", LEVEL_HOST ); } else { status = output_title( fp, info, "TITLE", "SUBTITLE", "%S", LEVEL_HOST ); if ( status==0 ) output_title( fp, info, "SHORTTITLE", "SHORTSUBTITLE", "%S", LEVEL_HOST ); } if ( type!=TYPE_CASE && type!=TYPE_HEARING ) { output_title( fp, info, "TITLE", "SUBTITLE", "%S", LEVEL_SERIES ); } output_year( fp, info, LEVEL_ANY ); output_monthday( fp, info, LEVEL_ANY ); output_easy( fp, info, "VOLUME", "%V", LEVEL_ANY ); output_easy( fp, info, "ISSUE", "%N", LEVEL_ANY ); output_easy( fp, info, "NUMBER", "%N", LEVEL_ANY ); output_easy( fp, info, "EDITION", "%7", LEVEL_ANY ); output_easy( fp, info, "PUBLISHER", "%I", LEVEL_ANY ); output_easy( fp, info, "ADDRESS", "%C", LEVEL_ANY ); output_easy( fp, info, "DEGREEGRANTOR", "%C", LEVEL_ANY ); output_easy( fp, info, "DEGREEGRANTOR:CORP", "%C", LEVEL_ANY ); output_easy( fp, info, "DEGREEGRANTOR:ASIS", "%C", LEVEL_ANY ); output_easy( fp, info, "SERIALNUMBER", "%@", LEVEL_ANY ); output_easy( fp, info, "ISSN", "%@", LEVEL_ANY ); output_easy( fp, info, "ISBN", "%@", LEVEL_ANY ); output_easy( fp, info, "LANGUAGE", "%G", LEVEL_ANY ); output_easy( fp, info, "REFNUM", "%F", LEVEL_ANY ); output_easyall( fp, info, "NOTES", "%O", LEVEL_ANY ); output_easy( fp, info, "ABSTRACT", "%X", LEVEL_ANY ); output_easy( fp, info, "CLASSIFICATION", "%L", LEVEL_ANY ); output_easyall( fp, info, "KEYWORD", "%K", LEVEL_ANY ); output_easyall( fp, info, "NGENRE", "%9", LEVEL_ANY ); output_thesishint( fp, type ); output_easyall( fp, info, "DOI", "%R", LEVEL_ANY ); output_easyall( fp, info, "URL", "%U", LEVEL_ANY ); output_easyall( fp, info, "FILEATTACH", "%U", LEVEL_ANY ); output_doi( fp, info ); output_pmid( fp, info ); output_pmc( fp, info ); output_arxiv( fp, info ); output_jstor( fp, info ); output_pages( fp, info ); fprintf( fp, "\n" ); fflush( fp ); }