1 #ifndef OBJTOOLS_IDMAPPER___IDMAPPER_IMPL__HPP
2 #define OBJTOOLS_IDMAPPER___IDMAPPER_IMPL__HPP
84 virtual void AddMapping(
const CSeq_loc& loc_from,
134 kPriority_Default = 0
143 TPriority priority = kPriority_Default,
162 : m_Mapper(mapper, ownership),
165 m_Order = sm_Counter.
Add(1);
244 bool bInvert =
false,
248 bool bInvert =
false,
253 list<SMappingContext>& contexts);
290 bool bInvert =
false,
328 bool bInvert =
false,
330 :
CIdMapper(strContext, bInvert, pErrors),
331 m_strServer(strServer),
332 m_strDatabase(strDatabase)
394 EAliasMapping mapping,
400 EAliasMapping mapping,
409 void x_AddUnversionedMapping(
const CSeq_id& src_id,
411 void x_AddAccessionMapping(
const CSeq_id&
id);
413 EAliasMapping mapping,
414 const string& alias_scope);
416 EAliasMapping mapping,
417 const string& alias_scope);
419 EAliasMapping mapping,
420 const string& alias_scope);
433 virtual const char* GetErrCodeString(
void)
const override;
User-defined methods of the data storage class.
User-defined methods of the data storage class.
IdMapper implementation using hardcoded values.
void AddMapEntry(const std::string &, int)
IdMapper implementation combining multiple id mappers with the selected priorities.
EPriority
Sub-mapper priority.
CAtomicCounter::TValue TOrder
IdMapper implementation using an external configuration file.
IdMapper implementation using an external database.
const std::string m_strDatabase
const std::string m_strServer
CIdMapperDatabase(const std::string &strServer, const std::string &strDatabase, const std::string &strContext, bool bInvert=false, ILineErrorListener *pErrors=0)
Constructor specifying a database containing the actual mapping, the mapping context,...
NCBI_EXCEPTION_DEFAULT(CIdMapperException, CException)
IdMapper implementation using a GC-Assembly.
EAliasMapping
Mapping destination type.
@ eGenBankAcc
GenBank accession.
@ eRefSeqAcc
RefSeq accession.
IdMapper implementaion using CScope.
IdMapper base class implementation.
ILineErrorListener * m_pErrors
std::map< CSeq_id_Handle, SMapper > TMapperCache
const std::string m_strContext
Base class for all serializable objects.
General IdMapper interface.
virtual void MapObject(CSerialObject &)=0
Map all embedded IDs in a given object at once.
virtual CSeq_id_Handle Map(const CSeq_id_Handle &id)=0
Map a single given CSeq_id_Handle to another.
Include a standard set of the NCBI C++ Toolkit most basic headers.
CRange< Position > Map(const CRange< Position > &target, const CRange< Position > &range)
@ eTakeOwnership
An object can take ownership of another.
TNCBIAtomicValue TValue
Alias TValue for TNCBIAtomicValue.
TValue Add(int delta) THROWS_NONE
Atomically add value (=delta), and return new counter value.
EErrCode
Error types that an application can generate.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
IO_PREFIX::istream CNcbiIstream
Portable alias for istream.
enum ENcbiOwnership EOwnership
Ownership relations between objects.
#define NCBI_XOBJREAD_EXPORT
bool operator<(const SNode &node) const
SNode(IIdMapper *mapper, TPriority priority, EOwnership ownership)
CIdMapperComposite::TPriority TPriority
static CAtomicCounter sm_Counter
CIdMapperComposite::TOrder TOrder
AutoPtr< IIdMapper > m_Mapper
CRef< CSeq_loc_Mapper > dest_mapper