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 string Message () const
 
string SeverityStr () 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 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 167 of file line_error.hpp.

Constructor & Destructor Documentation

◆ ~CLineError()

virtual CLineError::~CLineError ( void  )
inlinevirtualnoexcept

Definition at line 190 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 96 of file line_error.cpp.

Member Function Documentation

◆ AddOtherLine()

void CLineError::AddOtherLine ( unsigned int  uOtherLine)
inline

Definition at line 207 of file line_error.hpp.

References m_vecOfOtherLines.

◆ Clone()

ILineError * CLineError::Clone ( void  ) const
virtual

Use this because copy ctor is protected.

Implements ILineError.

Definition at line 324 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 245 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 228 of file line_error.hpp.

References m_strFeatureName.

◆ Line()

unsigned int CLineError::Line ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 222 of file line_error.hpp.

References m_uLine.

◆ OtherLines()

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

Implements ILineError.

Definition at line 225 of file line_error.hpp.

References m_vecOfOtherLines.

◆ PatchErrorMessage()

void CLineError::PatchErrorMessage ( const string errorMessage)
inline

Definition at line 199 of file line_error.hpp.

References m_strErrorMessage.

◆ PatchLineNumber()

void CLineError::PatchLineNumber ( unsigned int  uLine)
inline

Definition at line 196 of file line_error.hpp.

References m_uLine.

◆ Problem()

EProblem CLineError::Problem ( void  ) const
inlinevirtual

Implements ILineError.

Definition at line 213 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 237 of file line_error.hpp.

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

◆ QualifierName()

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

Implements ILineError.

Definition at line 231 of file line_error.hpp.

References m_strQualifierName.

◆ QualifierValue()

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

Implements ILineError.

Definition at line 234 of file line_error.hpp.

References m_strQualifierValue.

◆ SeqId()

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

Implements ILineError.

Definition at line 219 of file line_error.hpp.

References m_strSeqId.

◆ Severity()

virtual EDiagSev CLineError::Severity ( void  ) const
inlinevirtual

Reimplemented from ILineError.

Definition at line 216 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 67 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 248 of file line_error.hpp.

Referenced by Problem().

◆ m_eSeverity

EDiagSev CLineError::m_eSeverity
protected

Definition at line 249 of file line_error.hpp.

Referenced by Severity().

◆ m_strErrorMessage

std::string CLineError::m_strErrorMessage
protected

Definition at line 255 of file line_error.hpp.

Referenced by ErrorMessage(), and PatchErrorMessage().

◆ m_strFeatureName

std::string CLineError::m_strFeatureName
protected

Definition at line 252 of file line_error.hpp.

Referenced by FeatureName().

◆ m_strQualifierName

std::string CLineError::m_strQualifierName
protected

Definition at line 253 of file line_error.hpp.

Referenced by QualifierName().

◆ m_strQualifierValue

std::string CLineError::m_strQualifierValue
protected

Definition at line 254 of file line_error.hpp.

Referenced by QualifierValue().

◆ m_strSeqId

std::string CLineError::m_strSeqId
protected

Definition at line 250 of file line_error.hpp.

Referenced by SeqId().

◆ m_uLine

unsigned int CLineError::m_uLine
protected

Definition at line 251 of file line_error.hpp.

Referenced by Line(), and PatchLineNumber().

◆ m_vecOfOtherLines

TVecOfLines CLineError::m_vecOfOtherLines
protected

Definition at line 256 of file line_error.hpp.

Referenced by AddOtherLine(), and OtherLines().


The documentation for this class was generated from the following files:
Modified on Fri Sep 20 14:58:27 2024 by modify_doxy.py rev. 669887