NCBI C++ ToolKit
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CLineError Class Reference

Search Toolkit Book for CLineError

#include <objtools/readers/line_error.hpp>

+ Inheritance diagram for CLineError:
+ Collaboration diagram for CLineError:

Public Member Functions

virtual ILineErrorClone (void) const
 Use this because copy ctor is protected. More...
 
virtual ~CLineError (void) noexcept
 
void Throw (void) const
 copy constructor is protected so please use this function to throw the object. More...
 
void PatchLineNumber (unsigned int uLine)
 
void PatchErrorMessage (const string &errorMessage)
 
void AddOtherLine (unsigned int uOtherLine)
 
EProblem Problem (void) const
 
virtual EDiagSev Severity (void) const
 
const std::stringSeqId (void) const
 
unsigned int Line (void) const
 
const TVecOfLinesOtherLines (void) const
 
const std::stringFeatureName (void) const
 
const std::stringQualifierName (void) const
 
const std::stringQualifierValue (void) const
 
virtual std::string ProblemStr (void) const
 
const std::stringErrorMessage (void) const
 
- Public Member Functions inherited from ILineError
virtual ~ILineError (void) noexcept
 
virtual std::string Message (void) const
 
std::string SeverityStr (void) const
 
virtual void Write (CNcbiOstream &out) const
 
virtual void WriteAsXML (CNcbiOstream &out) const
 
virtual string GetText (void) const
 
virtual EDiagSev GetSeverity (void) const
 
virtual int GetCode (void) const
 
virtual int GetSubCode (void) const
 
virtual void Dump (CNcbiOstream &out) const
 
virtual std::string Compose (void) const
 
virtual void DumpAsXML (CNcbiOstream &out) const
 
- Public Member Functions inherited from IObjtoolsMessage
virtual ~IObjtoolsMessage (void)=default
 

Static Public Member Functions

static CLineErrorCreate (EProblem eProblem, EDiagSev eSeverity, const std::string &strSeqId, unsigned int uLine, const std::string &strFeatureName=string(""), const std::string &strQualifierName=string(""), const std::string &strQualifierValue=string(""), const std::string &strErrorMessage=string(""), const TVecOfLines &vecOfOtherLines=TVecOfLines())
 Use this because the constructor is protected. More...
 
- Static Public Member Functions inherited from ILineError
static std::string ProblemStr (EProblem eProblem)
 

Protected Member Functions

 CLineError (EProblem eProblem, EDiagSev eSeverity, const std::string &strSeqId, unsigned int uLine, const std::string &strFeatureName, const std::string &strQualifierName, const std::string &strQualifierValue, const std::string &strErrorMessage, const TVecOfLines &m_vecOfOtherLine)
 protected instead of public. Please use the Create function instead. More...
 
 CLineError (const CLineError &rhs)
 protected instead of public. More...
 

Protected Attributes

EProblem m_eProblem
 
EDiagSev m_eSeverity
 
std::string m_strSeqId
 
unsigned int m_uLine
 
std::string m_strFeatureName
 
std::string m_strQualifierName
 
std::string m_strQualifierValue
 
std::string m_strErrorMessage
 
TVecOfLines m_vecOfOtherLines
 

Additional Inherited Members

- Public Types inherited from ILineError
enum  EProblem {
  eProblem_Unset = 1 , eProblem_UnrecognizedFeatureName , eProblem_UnrecognizedQualifierName , eProblem_NumericQualifierValueHasExtraTrailingCharacters ,
  eProblem_NumericQualifierValueIsNotANumber , eProblem_FeatureNameNotAllowed , eProblem_NoFeatureProvidedOnIntervals , eProblem_QualifierWithoutFeature ,
  eProblem_IncompleteFeature , eProblem_FeatureBadStartAndOrStop , eProblem_BadFeatureInterval , eProblem_QualifierBadValue ,
  eProblem_BadScoreValue , eProblem_MissingContext , eProblem_BadTrackLine , eProblem_InternalPartialsInFeatLocation ,
  eProblem_FeatMustBeInXrefdGene , eProblem_CreatedGeneFromMultipleFeats , eProblem_UnrecognizedSquareBracketCommand , eProblem_TooLong ,
  eProblem_UnexpectedNucResidues , eProblem_UnexpectedAminoAcids , eProblem_TooManyAmbiguousResidues , eProblem_InvalidResidue ,
  eProblem_ModifierFoundButNoneExpected , eProblem_ExtraModifierFound , eProblem_ExpectedModifierMissing , eProblem_Missing ,
  eProblem_NonPositiveLength , eProblem_ParsingModifiers , eProblem_ContradictoryModifiers , eProblem_InvalidLengthAutoCorrected ,
  eProblem_IgnoredResidue , eProblem_DiscouragedFeatureName , eProblem_DiscouragedQualifierName , eProblem_InvalidQualifier ,
  eProblem_InconsistentQualifiers , eProblem_DuplicateIDs , eProblem_BadInfoLine , eProblem_BadFormatLine ,
  eProblem_BadFilterLine , eProblem_ProgressInfo , eProblem_GeneralParsingError
}
 
typedef vector< unsigned intTVecOfLines
 

Detailed Description

Definition at line 376 of file line_error.hpp.

Constructor & Destructor Documentation

◆ ~CLineError()

virtual CLineError::~CLineError ( void  )
inlinevirtualnoexcept

Definition at line 400 of file line_error.hpp.

◆ CLineError() [1/2]

CLineError::CLineError ( EProblem  eProblem,
EDiagSev  eSeverity,
const std::string strSeqId,
unsigned int  uLine,
const std::string strFeatureName,
const std::string strQualifierName,
const std::string strQualifierValue,
const std::string strErrorMessage,
const TVecOfLines m_vecOfOtherLine 
)
protected

protected instead of public. Please use the Create function instead.

Definition at line 74 of file line_error.cpp.

Referenced by Clone().

◆ CLineError() [2/2]

CLineError::CLineError ( const CLineError rhs)
protected

protected instead of public.

Please use the Throw function to throw this exception and try to avoid using the copy constructor at all.

Definition at line 90 of file line_error.cpp.

Member Function Documentation

◆ AddOtherLine()

void CLineError::AddOtherLine ( unsigned int  uOtherLine)
inline

Definition at line 416 of file line_error.hpp.

References m_vecOfOtherLines.

◆ Clone()

ILineError * CLineError::Clone ( void  ) const
virtual

Use this because copy ctor is protected.

Reimplemented from ILineError.

Definition at line 97 of file line_error.cpp.

References CLineError().

◆ Create()

CLineError * CLineError::Create ( EProblem  eProblem,
EDiagSev  eSeverity,
const std::string strSeqId,
unsigned int  uLine,
const std::string strFeatureName = string(""),
const std::string strQualifierName = string(""),
const std::string strQualifierValue = string(""),
const std::string strErrorMessage = string(""),
const TVecOfLines vecOfOtherLines = TVecOfLines() 
)
static

◆ ErrorMessage()

const std::string& CLineError::ErrorMessage ( void  ) const
inlinevirtual

Reimplemented from ILineError.

Definition at line 453 of file line_error.hpp.

References m_strErrorMessage.

Referenced by ProblemStr().

◆ FeatureName()

const std::string& CLineError::FeatureName ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 436 of file line_error.hpp.

References m_strFeatureName.

◆ Line()

unsigned int CLineError::Line ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 430 of file line_error.hpp.

References m_uLine.

◆ OtherLines()

const TVecOfLines& CLineError::OtherLines ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 433 of file line_error.hpp.

References m_vecOfOtherLines.

◆ PatchErrorMessage()

void CLineError::PatchErrorMessage ( const string errorMessage)
inline

Definition at line 409 of file line_error.hpp.

References m_strErrorMessage.

◆ PatchLineNumber()

void CLineError::PatchLineNumber ( unsigned int  uLine)
inline

Definition at line 406 of file line_error.hpp.

References m_uLine.

◆ Problem()

EProblem CLineError::Problem ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 421 of file line_error.hpp.

References m_eProblem.

Referenced by ProblemStr().

◆ ProblemStr()

virtual std::string CLineError::ProblemStr ( void  ) const
inlinevirtual

Reimplemented from ILineError.

Definition at line 445 of file line_error.hpp.

References ErrorMessage(), Problem(), and ILineError::ProblemStr().

◆ QualifierName()

const std::string& CLineError::QualifierName ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 439 of file line_error.hpp.

References m_strQualifierName.

◆ QualifierValue()

const std::string& CLineError::QualifierValue ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 442 of file line_error.hpp.

References m_strQualifierValue.

◆ SeqId()

const std::string& CLineError::SeqId ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 427 of file line_error.hpp.

References m_strSeqId.

◆ Severity()

virtual EDiagSev CLineError::Severity ( void  ) const
inlinevirtual

Reimplemented from ILineError.

Definition at line 424 of file line_error.hpp.

References m_eSeverity.

◆ Throw()

void CLineError::Throw ( void  ) const

copy constructor is protected so please use this function to throw the object.

Definition at line 68 of file line_error.cpp.

Referenced by CReaderBase::ProcessError(), and CReaderBase::ProcessWarning().

Member Data Documentation

◆ m_eProblem

EProblem CLineError::m_eProblem
protected

Definition at line 457 of file line_error.hpp.

Referenced by Problem().

◆ m_eSeverity

EDiagSev CLineError::m_eSeverity
protected

Definition at line 458 of file line_error.hpp.

Referenced by Severity().

◆ m_strErrorMessage

std::string CLineError::m_strErrorMessage
protected

Definition at line 464 of file line_error.hpp.

Referenced by ErrorMessage(), and PatchErrorMessage().

◆ m_strFeatureName

std::string CLineError::m_strFeatureName
protected

Definition at line 461 of file line_error.hpp.

Referenced by FeatureName().

◆ m_strQualifierName

std::string CLineError::m_strQualifierName
protected

Definition at line 462 of file line_error.hpp.

Referenced by QualifierName().

◆ m_strQualifierValue

std::string CLineError::m_strQualifierValue
protected

Definition at line 463 of file line_error.hpp.

Referenced by QualifierValue().

◆ m_strSeqId

std::string CLineError::m_strSeqId
protected

Definition at line 459 of file line_error.hpp.

Referenced by SeqId().

◆ m_uLine

unsigned int CLineError::m_uLine
protected

Definition at line 460 of file line_error.hpp.

Referenced by Line(), and PatchLineNumber().

◆ m_vecOfOtherLines

TVecOfLines CLineError::m_vecOfOtherLines
protected

Definition at line 465 of file line_error.hpp.

Referenced by AddOtherLine(), and OtherLines().


The documentation for this class was generated from the following files:
Modified on Tue Feb 27 05:56:09 2024 by modify_doxy.py rev. 669887