fStrictGuess = 1<<15,
107fBadModThrow
NCBI_STD_DEPRECATED(
"This flag is redundant as CFastaReader no longer utilizes CSourceModParser.") = 1<<20,
108fUnknModThrow
NCBI_STD_DEPRECATED(
"This flag is redundant as CFastaReader no longer utilizes CSourceModParser.") = 1<<21,
109fLeaveAsText = 1<<22,
110fQuickIDCheck = 1<<23,
112fHyphensIgnoreAndWarn = 1<<25,
113fDisableNoResidues = 1<<26,
114fDisableParseRange = 1<<27,
118 static voidAddStringFlags(
119 constlist<string>& stringFlags,
141 bool AtEOF(
void)
const{
returnm_LineReader->AtEOF(); }
181 voidSetExcludedMods(
constvector<string>& excluded_mods);
182 voidSetIgnoredMods(
constlist<string>& ignored_mods);
183 voidSetPostponedMods(
constlist<string>& postponed_mods);
193 voidSetMaxIDLength(
Uint4max_len);
203 static stringCanonicalizeString(
const CTempString& sValue);
207 voidSetGapLinkageEvidence(
212 voidSetGapLinkageEvidences(
224 static voidParseDefLine(
const TStr& defLine,
236fAligning = 0x40000000,
237fInSegSet = 0x20000000
243 virtual voidPostProcessIDs(
const CBioseq::TId& defline_ids,
244 const string& defline,
245 boolhas_range=
false,
250 virtual voidParseTitle (
constSLineTextAndLoc & lineInfo,
ILineErrorListener* pMessageListener);
251 virtual boolIsValidLocalID(
constTStr& s)
const;
252 static boolIsValidLocalID(
constTStr& idString, TFlags fFastaFlags);
253 virtual voidGenerateID (
void);
257 virtual voidx_OpenMask (
void);
258 virtual voidx_CloseMask (
void);
262 virtual boolCreateWarningsForSeqDataInTitle(
263 constTStr& sLineText,
276 typedefvector<CRef<CSeq_id> >
TIds;
279 voidx_AddPairwiseAlignments(
CSeq_annot& annot,
const TIds& ids,
281 voidx_AddMultiwayAlignment(
CSeq_annot& annot,
const TIds& ids);
285 if(m_CurrentGapLength > 0) {
286x_CloseGap(m_CurrentGapLength, atStartOfLine, pMessageListener);
287m_CurrentGapLength = 0;
290 voidOpenMask(
void);
296{
returnm_LineReader->GetLineNumber(); }
300{
return(GetFlags() & flag) != 0; }
302{
return(GetFlags() & flag) != 0; }
320 voidx_ApplyMods(
const string& title,
325 voidx_AddMods(
TSeqPosline_number,
327 string& processed_title,
330 voidx_CheckForPostponedMods(
const string& idString,
336 boolm_bModifiedMaxIdLength=
false;
438 int* counter =
nullptr,
User-defined methods of the data storage class.
User-defined methods of the data storage class.
function< void(const TIds &id, const TInfo &info, ILineErrorListener *listener)> FIdCheck
Base class for reading FASTA sequences.
list< CModData > TModList
Defines and provides stubs for a general interface to a variety of file readers.
virtual CRef< CSerialObject > ReadObject(CNcbiIstream &istr, ILineErrorListener *pErrors=nullptr)
Read an object from a given input stream, render it as the most appropriate Genbank object.
virtual CRef< CSeq_entry > ReadSeqEntry(CNcbiIstream &istr, ILineErrorListener *pErrors=nullptr)
Read an object from a given input stream, render it as a single Seq-entry, if possible.
CTempString implements a light-weight string on top of a storage buffer whose lifetime management is ...
Callback interface to scan fasta file for entries.
Abstract base class for lightweight line-by-line reading.
unsigned int TSeqPos
Type for sequence locations and lengths.
int TSignedSeqPos
Type for signed sequence position.
const TSeqPos kInvalidSeqPos
Define special value for invalid sequence position.
EDiagSev
Severity level for the posted diagnostics.
TFastaSeqIds all_seq_ids
List of all seq.ids.
TSeqTitles m_CurrentSeqTitles
function< bool(const CTempString &mod_name)> FModFilter
bool TestFlag(EFlags flag) const
TSeqPos m_CurrentGapLength
CConstRef< TGapTypeObj > TNullableGapType
const CSeqIdGenerator & GetIDGenerator(void) const
Uint4 GetMaxIDLength(void) const
Get the maximum ID allowed, which will be kMax_UI4 unless someone has manually lowered it.
SGap::TNullableGapType m_gap_type
TFlags GetFlags(void) const
CSeqIdGenerator & SetIDGenerator(void)
void SaveMasks(TMasks *masks)
const TNullableGapType m_pGapType
long TFlags
binary OR of EFlags
const Uint8 m_uLineNumber
SGap::TLinkEvidSet m_DefaultLinkageEvidence
CBioseq & SetCurrentSeq(void)
const EKnownSize m_eKnownSize
void ResetIDTracker(void)
Re-allow previously seen IDs even if fUniqueIds is on.
CRef< CFastaIdHandler > m_IDHandler
TSeqPos m_gap_Unknown_length
CRef< ILineReader > m_LineReader
map< TSeqPos, TSubMap > TStartsMap
const CSeq_id & GetBestID(void) const
CBioseq::TId & SetIDs(void)
TSeqPos GetCurrentPos(EPosType pos_type)
EFlags
Note on fAllSeqIds: some databases (notably nr) have merged identical sequences, joining their deflin...
TPostponedModMap m_PostponedModMap
CRef< CBioseq > m_CurrentSeq
virtual void EntryFound(CRef< CSeq_entry > se, CNcbiStreampos stream_position)=0
Callback function, called after reading the fasta entry.
vector< CRef< CSeq_id > > TIds
virtual void x_OpenMask(void)
CObjectFor< CSeq_gap::EType > TGapTypeObj
CSourceModParser::TMods m_BadMods
list< string > TFastaSeqIds
List of qll sequence ids.
map< TRowNum, TSignedSeqPos > TSubMap
std::vector< ILineError::EProblem > m_ignorable
CNcbiStreampos stream_offset
Molecule offset in file.
vector< ILineError::EProblem > TIgnoredProblems
set< CSeq_id_Handle > TIDTracker
bool AtEOF(void) const
Indicates (negatively) whether there is any more input.
set< CLinkage_evidence::EType > TLinkEvidSet
void ScanFastaFile(IFastaEntryScan *scanner, CNcbiIfstream &input, CFastaReader::TFlags fread_flags)
Scan FASTA files, call IFastaEntryScan::EntryFound (payload function)
Uint8 LineNumber(void) const
Int8 StreamPosition(void) const
string seq_id
Primary sequence Id.
CFastaReader::TFlags TReadFastaFlags
CFastaDeflineReader::FIdCheck FIdCheck
void ReadFastaFileMap(SFastaFileMap *fasta_map, CNcbiIfstream &input)
Function reads input stream (assumed that it is FASTA format) one molecule entry after another fillin...
string description
Molecule description.
void CloseGap(bool atStartOfLine=false, ILineErrorListener *pMessageListener=nullptr)
unordered_set< string > m_PostponedMods
CSourceModParser::TMods m_UnusedMods
bool TestFlag(EInternalFlags flag) const
const TLinkEvidSet m_setOfLinkageEvidence
ILineReader & GetLineReader(void)
const CBioseq::TId & GetIDs(void) const
vector< SLineTextAndLoc > TSeqTitles
TCountToLinkEvidMap m_GapsizeToLinkageEvidence
vector< SFastaEntry > TMapVector
CRef< CSeq_entry > ReadFasta(CNcbiIstream &in, CFastaReader::TFlags flags=0, int *counter=nullptr, CFastaReader::TMasks *lcv=nullptr, ILineErrorListener *pMessageListener=nullptr)
A const-correct replacement for the deprecated ReadFasta function.
bool NotEmpty(void) const THROWS_NONE
Check if CRef is not empty â pointing to an object and has a non-null value.
#define NCBI_STD_DEPRECATED(message)
uint32_t Uint4
4-byte (32-bit) unsigned integer
int64_t Int8
8-byte (64-bit) signed integer
uint64_t Uint8
8-byte (64-bit) unsigned integer
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define BEGIN_SCOPE(ns)
Define a new scope.
Int8 NcbiStreamposToInt8(NCBI_NS_STD::char_traits< char >::pos_type stream_pos)
Convert stream position to 64-bit int.
IO_PREFIX::istream CNcbiIstream
Portable alias for istream.
IO_PREFIX::ifstream CNcbiIfstream
Portable alias for ifstream.
IO_PREFIX::streampos CNcbiStreampos
Portable alias for streampos.
#define NCBI_XOBJREAD_EXPORT
list< CRef< CSeq_id > > TId
EMol
molecule class in living organism
Lightweight interface for getting lines of data with minimal memory copying.
std::istream & in(std::istream &in_, double &x_)
static SLJIT_INLINE sljit_ins lr(sljit_gpr dst, sljit_gpr src)
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