,
"AC",
"NI",
"DT",
"DE",
"KW",
"OS",
"OC",
"OG",
"RN",
"RP",
"RX",
"RC",
"RG",
"RA",
"RT",
"RL",
"DR",
"FH",
"FT",
"SQ",
"CC",
"SV",
"CO",
"XX",
"AH",
"AS",
"PR",
"//" 91 size_tp = line.rfind(
'.');
92 if(p == string_view::npos) {
97 stringacc(line.substr(0, p));
99 stringver(line.substr(p));
100 for(
size_tq = p; q < line.size(); ++q) {
101 if(line[q] <
'0'|| line[q] >
'9') {
103entry->
drop=
true;
107 if(entry->
acnum!= acc) {
109entry->
drop=
true;
115entry->
drop=
true;
122 if(locus.empty() ||
str.empty())
124 autop =
str.find(
';');
125 if(p == string_view::npos)
128 while(p <
str.size() &&
str[p] ==
' ')
130 if(p + 2 >=
str.size() ||
str[p] !=
'S'||
str[p + 1] !=
'V')
133 while(p <
str.size() &&
str[p] ==
' ')
135 autoq =
str.find(
';', p);
136 if(q == string_view::npos)
141res +=
str.substr(p, q - p);
180 autotibnp = ibl.before_begin();
182 while(! end_of_file) {
187tibnp = ibl.emplace_after(tibnp, entry);
203optional<string> line_sv;
214 while(! end_of_file &&
216 conststring_view line = finfo.
str;
217 if(line.starts_with(keywordKw)) {
222}
else if(line.starts_with(keywordId)) {
225entry->
drop=
true;
231}
else if(line.starts_with(keywordAh)) {
236 if(after_SQ &&
isalpha(line.front())) {
238entry->
drop=
true;
241 if(line.starts_with(keywordNi)) {
244entry->
drop=
true;
248}
else if(line.starts_with(keywordSq)) {
251}
else if(line.starts_with(keywordOs)) {
258line.starts_with(keywordSv)) {
261entry->
drop=
true;
265entry->
drop=
true;
270 while(*p ==
' '|| *p ==
'\t')
273 for(; *q !=
'\0'&& *q !=
' '&& *q !=
'\t'&&
279 if(line.starts_with(
"OC"sv))
283 if(line.starts_with(keywordRn))
287 if(line.starts_with(keywordCo))
292 if(line.starts_with(keywordAc)) {
293 if(after_AC ==
false) {
297}
else if(! entry->
drop&&
300}
else if(line.starts_with(keywordDt)) {
302 if(tokens.num > 2) {
311 if(finfo.
str[0] !=
' '&& finfo.
str[0] !=
'\t') {
313entry->
drop=
true;
324 if(! entry->
drop) {
325 if(after_AC ==
false) {
327entry->
drop=
true;
330 if(after_ID ==
false)
333 if(after_SV ==
false&& pp->
accver&&
337 if(after_OS ==
false)
340 if(after_OC ==
false)
343 if(after_RN ==
false)
346 if(after_DT ==
false)
349 if(after_SQ ==
false&& entry->
is_contig==
false)
361(*fun)(entry,
data->mBuf.ptr,
static_cast<Int4>(
data->mBuf.len));
382 for(
auto& it : ibl) {
386 return(end_of_file);
bool QSIndex(ParserPtr pp, const TIndBlkList &ibl, unsigned ibl_size)
const list< string > KeywordList() const
void AddDataLine(const string &line)
static optional< string > EmblGetNewIDVersion(string_view locus, string_view str)
vector< string > emblKeywords
bool EmblIndex(ParserPtr pp, void(*fun)(IndexblkPtr entry, char *offset, Int4 len))
static void ParseEmblVersion(IndexblkPtr entry, string_view line)
static bool em_err_field(const char *str)
vector< string > checkedEmblKeywords
#define ParFlat_COL_DATA_EMBL
DataBlk * LoadEntry(ParserPtr pp, size_t offset, size_t len)
#define ERR_FORMAT_MissingEnd
int fta_atoi(string_view sv)
bool fta_StartsWith(const char *s1, string_view s2)
void FtaDeletePrefix(int prefix)
#define FtaErrPost(sev, level,...)
static DLIST_TYPE *DLIST_NAME() next(DLIST_LIST_TYPE *list, DLIST_TYPE *item)
static const char * str(char *buf, int n)
int32_t Int4
4-byte (32-bit) signed integer
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
IndexblkPtr InitialEntry(ParserPtr pp, FinfoBlk &finfo)
bool FindNextEntryBuf(bool end_of_file, FileBuf &fbuf, FinfoBlk &finfo, string_view keyword)
CRef< CDate_std > GetUpdateDate(string_view str, Parser::ESource source)
bool XReadFileBuf(FileBuf &fbuf, FinfoBlk &finfo)
void MsgSkipTitleFail(const char *flatfile, FinfoBlk &finfo)
bool SkipTitleBuf(FileBuf &fbuf, FinfoBlk &finfo, string_view keyword)
forward_list< unique_ptr< Indexblk > > TIndBlkList
#define ERR_VERSION_NonDigitVerNum
#define ERR_ORGANISM_Multiple
#define ERR_VERSION_MissingVerNum
#define ERR_ACCESSION_NoAccessNum
#define ERR_FORMAT_Multiple_SV
#define ERR_VERSION_InvalidVersion
#define ERR_FORMAT_MissingField
#define ERR_FORMAT_Multiple_NI
#define ERR_ENTRY_InvalidLineType
#define ERR_VERSION_AccessionsDontMatch
const CConstRef< CSeq_id > GetAccession(const CSeq_id_Handle &id_handle)
CRef< objects::CDate_std > date
vector< IndexblkPtr > entrylist
CKeywordParser & KeywordParser()
bool CheckLineType(string_view str, Int4 type, const vector< string > &keywordList, bool after_origin)
TokenStatBlk TokenString(string_view str, Char delimiter)
void xCheckEstStsGssTpaKeywords(const list< string > keywordList, bool tpa_check, IndexblkPtr entry)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4