NCBI C++ ToolKit
|
#include <ncbi_pch.hpp>
#include "ftacpp.hpp"
#include <objects/general/Person_id.hpp>
#include <objects/biblio/Auth_list.hpp>
#include <objects/biblio/Cit_gen.hpp>
#include "index.h"
#include <objtools/flatfile/flatdefn.h>
#include "ftaerr.hpp"
#include "asci_blk.h"
#include "utilref.h"
#include "add.h"
#include "utilfun.h"
Go to the source code of this file.
Go to the SVN repository for this file.
Macros | |
#define | THIS_FILE "utilref.cpp" |
#define | MAX_PAGE 50 |
#define | OTHER_MEDIUM 255 |
Functions | |
USING_SCOPE (objects) | |
ValNodePtr | get_tokens (char *pt, const Char *delimeter) |
static void | RemoveSpacesAndCommas (string &str) |
void | get_auth_from_toks (ValNodePtr token, ERefFormat format, CRef< CAuth_list > &auths) |
CRef< CAuthor > | get_std_auth (const Char *token, ERefFormat format) |
void | get_auth (char *pt, ERefFormat format, char *jour, CRef< CAuth_list > &auths) |
void | get_auth_consortium (char *cons, CRef< CAuth_list > &auths) |
static Int4 | check_mix_pages_range (char *pages) |
Int4 | valid_pages_range (char *pages, const Char *title, Int4 er, bool inpress) |
CRef< CDate > | get_date (const Char *year) |
CRef< CCit_gen > | get_error (char *bptr, CRef< CAuth_list > &auth_list, CRef< CTitle::C_E > &title) |
#define MAX_PAGE 50 |
Definition at line 59 of file utilref.cpp.
#define OTHER_MEDIUM 255 |
Definition at line 60 of file utilref.cpp.
#define THIS_FILE "utilref.cpp" |
Definition at line 57 of file utilref.cpp.
Definition at line 326 of file utilref.cpp.
References ch1, ch2, i, StringChr, and StringEqu().
Referenced by valid_pages_range().
void get_auth | ( | char * | pt, |
ERefFormat | format, | ||
char * | jour, | ||
CRef< CAuth_list > & | auths | ||
) |
Definition at line 253 of file utilref.cpp.
References delimiter, EMBL_REF, ERR_REFERENCE_EtAlInAuthors, ErrPostEx, format, GB_REF, get_auth_from_toks(), get_tokens(), isalnum(), len, PDB_REF, PIR_REF, SEV_WARNING, SP_REF, StringEquN(), StringLen(), and ValNodeFree().
Referenced by embl_refs(), gb_refs_common(), get_book(), GetCitBook(), SprotRefString(), and XMLRefs().
void get_auth_consortium | ( | char * | cons, |
CRef< CAuth_list > & | auths | ||
) |
Definition at line 292 of file utilref.cpp.
References CRef< C, Locker >::Empty(), NStr::EqualNocase(), CRef< C, Locker >::Reset(), CAuthor_Base::SetName(), CAuth_list_Base::SetNames(), and StringChr.
Referenced by embl_refs(), gb_refs_common(), SprotRefString(), and XMLRefs().
void get_auth_from_toks | ( | ValNodePtr | token, |
ERefFormat | format, | ||
CRef< CAuth_list > & | auths | ||
) |
Definition at line 127 of file utilref.cpp.
References ValNode::data, CRef< C, Locker >::Empty(), ERR_REFERENCE_IllegalAuthorName, ErrPostStr, format, get_std_auth(), CAuthor_Base::GetName(), CPerson_id_Base::GetName(), i, CName_std_Base::IsSetFirst(), CName_std_Base::IsSetInitials(), CName_std_Base::IsSetLast(), CName_std_Base::IsSetSuffix(), last(), ValNode::next, RemoveSpacesAndCommas(), CRef< C, Locker >::Reset(), CAuthor_Base::SetName(), CAuth_list_Base::SetNames(), SEV_WARNING, StringEquN(), and NStr::TruncateSpacesInPlace().
Referenced by get_auth(), and GetCitBookOld().
Definition at line 503 of file utilref.cpp.
References ERR_REFERENCE_IllegalDate, ERR_REFERENCE_ImpendingYear, ERR_REFERENCE_YearPrecedes1900, ERR_REFERENCE_YearPrecedes1950, ErrPostEx, ErrPostStr, NStr::fAllowTrailingSymbols, i, CRef< C, Locker >::Reset(), CDate_Base::SetStd(), CDate_std_Base::SetYear(), SEV_ERROR, SEV_WARNING, and NStr::StringToInt().
Referenced by get_art(), get_book(), get_thesis(), get_whole_book(), and GetCitBookOld().
CRef<CCit_gen> get_error | ( | char * | bptr, |
CRef< CAuth_list > & | auth_list, | ||
CRef< CTitle::C_E > & | title | ||
) |
Definition at line 541 of file utilref.cpp.
References isdigit(), len, CRef< C, Locker >::NotEmpty(), NStr::Sanitize(), StringEquN(), and StringLen().
Referenced by journal().
CRef<CAuthor> get_std_auth | ( | const Char * | token, |
ERefFormat | format | ||
) |
Definition at line 177 of file utilref.cpp.
References _TROUBLE, EMBL_REF, format, GB_REF, CName_std_Base::IsSetLast(), ML_REF, PDB_REF, PIR_REF, CRef< C, Locker >::Reset(), CName_std_Base::SetInitials(), CName_std_Base::SetLast(), CAuthor_Base::SetName(), CPerson_id_Base::SetName(), SP_REF, and StringLen().
Referenced by get_auth_from_toks().
ValNodePtr get_tokens | ( | char * | pt, |
const Char * | delimeter | ||
) |
Definition at line 66 of file utilref.cpp.
References ValNode::data, ValNode::next, StringChr, StringEquN(), StringLen(), and ValNodeNew().
Referenced by get_auth(), GetCitBookOld(), and NotName().
Definition at line 116 of file utilref.cpp.
Referenced by get_auth_from_toks().
USING_SCOPE | ( | objects | ) |
Definition at line 419 of file utilref.cpp.
References check_mix_pages_range(), ERR_REFERENCE_IllegPageRange, ERR_REFERENCE_InvertPageRange, ERR_REFERENCE_LargePageRange, ERR_REFERENCE_UnusualPageNumber, ErrPostEx, i, MAX_PAGE, SEV_WARNING, and StringChr.
Referenced by get_art(), get_book(), and ParseJourLine().