A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/seqid__validate_8cpp_source.html below:

NCBI C++ ToolKit: src/objtools/readers/seqid_validate.cpp Source File

52  if

(!pErrorReporter) {

60  bool

foundError =

false

;

62  if

(idString.empty()) {

63

description =

"Empty local ID."

;

67  if

(idString.size() > 50) {

68

description =

"Local ID \""

+

70  " \" exceeds 50 character limit."

;

75

description =

"Local ID \""

+

77  "\" contains invalid characters."

;

82

pErrorReporter->

Error

(

97  for

(

const auto

& pSeqId : ids) {

124  for

(

const auto

& pId : ids) {

125  if

(pId->IsLocal() &&

127  const auto

& idString = pId->GetSeqIdString();

128  string msg

=

"'"

+ idString +

"' is not a valid local ID"

;

155  const string

& idType,

156  size_t

maxAllowedLength,

163

+

". Please find and correct all "

+ idType +

"s that are too long."

;

171  if

(

id

.IsLocal()) {

172  if

(

id

.GetLocal().IsStr() &&

184  if

(

id

.IsGeneral()) {

185  if

(

id

.GetGeneral().IsSetTag() &&

186  id

.GetGeneral().GetTag().IsStr()) {

187  const auto

length =

id

.GetGeneral().GetTag().GetStr().length();

191  "general id string"

,

200  auto

pTextId =

id

.GetTextseq_Id();

201  if

(pTextId && pTextId->IsSetAccession()) {

202  const auto

length = pTextId->GetAccession().length();

217  if

(

id

.IsLocal()) {

218  if

(

id

.GetLocal().IsId()) {

221  if

(

id

.GetLocal().IsStr()) {

246  const auto

& idString =

id

.GetSeqIdString();

250  const string

err_message =

251  "Fasta Reader: sequence id ends with "

+

253  " valid nucleotide characters. "

+

254  " Was the sequence accidentally placed in the definition line?"

;

287  const string

& idString)

289  const auto

first_it = rbegin(idString);

290  const auto

it = find_if_not(first_it, rend(idString),

s_IsPossibleNuc

);

292  return static_cast<size_t>

(distance(first_it, it));

301  const auto

& idString =

id

.GetSeqIdString();

307  const string

err_message =

308  "Fasta Reader: sequence id ends with "

+

310  " valid amino-acid characters. "

+

311  " Was the sequence accidentally placed in the definition line?"

;

319  const string

& idString)

321  const auto

first_it = rbegin(idString);

322  const auto

it = find_if_not(first_it, rend(idString),

323

[](

char

c) {

return

(c >=

'A'

&& c <=

'Z'

) ||

324

(c >=

'a'

&& c <=

'z'

); });

326  return static_cast<size_t>

(distance(first_it, it));

void Error(const SShowStopper &showStopper)

void SetMaxLocalIDLength(size_t length)

virtual void operator()(const TIds &ids, int lineNum, FReportError fReportError)

function< void(EDiagSev severity, int lineNum, const string &idString, EErrCode errCode, const string &msg)> FReportError

CFastaIdValidate(TFastaFlags flags)

void CheckForExcessiveNucData(const CSeq_id &id, int lineNum, FReportError fReportError) const

size_t kWarnNumAminoAcidCharsAtEnd

static size_t CountPossibleNucResidues(const string &idString)

size_t kErrNumNucCharsAtEnd

void SetMaxAccessionLength(size_t length)

list< CRef< CSeq_id > > TIds

virtual bool IsValidLocalString(const CTempString &idString) const

size_t kWarnNumNucCharsAtEnd

size_t kMaxAccessionLength

size_t kMaxGeneralTagLength

void CheckForExcessiveProtData(const CSeq_id &id, int lineNum, FReportError fReportError) const

static size_t CountPossibleAminoAcids(const string &idString)

bool IsValidLocalID(const CSeq_id &id) const

void SetMaxGeneralTagLength(size_t length)

void CheckIDLength(const CSeq_id &id, int lineNum, FReportError fReportError) const

virtual void operator()(const CSeq_id &seqId, int lineNum, CAlnErrorReporter *pErrorReporter)

CTempString implements a light-weight string on top of a storage buffer whose lifetime management is ...

string GetSeqIdString(const CSeq_id &id)

The NCBI C++ standard methods for dealing with std::string.

Operators to edit gaps in sequences.

@ eDiag_Error

Error message.

@ eDiag_Warning

Warning message.

@ fQuickIDCheck

Just check local IDs' first characters.

@ fAssumeNuc

Assume nucs unless accns indicate otherwise.

@ fAssumeProt

Assume prots unless accns indicate otherwise.

static TErrorFlags CheckLocalID(const CTempString &s)

Perform rudimentary validation on potential local IDs, whose contents should not exceed fifty charact...

#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.

CTempString substr(size_type pos) const

Obtain a substring from this string, beginning at a given offset.

static enable_if< is_arithmetic< TNumeric >::value||is_convertible< TNumeric, Int8 >::value, string >::type NumericToString(TNumeric value, TNumToStringFlags flags=0, int base=10)

Convert numeric value to string.

bool IsStr(void) const

Check if variant Str is selected.

const TStr & GetStr(void) const

Get the variant data.

const TLocal & GetLocal(void) const

Get the variant data.

bool IsLocal(void) const

Check if variant Local is selected.

@ eAlnSubcode_IllegalSequenceId

static bool s_IsPossibleNuc(unsigned char c)

static string s_GetIDLengthErrorString(size_t length, const string &idType, size_t maxAllowedLength, int lineNum)

static SLJIT_INLINE sljit_ins msg(sljit_gpr r, sljit_s32 d, sljit_gpr x, sljit_gpr b)


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