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/classCSeqDBVolSet.html below:

NCBI C++ ToolKit: CSeqDBVolSet Class Reference

Search Toolkit Book for CSeqDBVolSet

CSeqDBVolSet. More...

#include "seqdbvolset.hpp"
(Private to src/objtools/blast/seqdb_reader.)

CSeqDBVolSet.

This class stores a set of CSeqDBVol objects and defines an interface to control usage of them. Several methods are provided to create the set of volumes, or to get the required volumes by different criteria. Also, certain methods perform operations over the set of volumes. The CSeqDBVolEntry class, defined internally to this one, provides some of this abstraction.

Definition at line 157 of file seqdbvolset.hpp.

◆ CSeqDBVolSet() [1/3]

Standard Constructor.

An object of this class will be constructed after the alias files have been read, and the volume names will come from that processing step. All of the specified volumes will be opened and the metadata will be verified during construction.

Parameters
atlas The memory management object to use. vol_names The names of the volumes this object will manage. prot_nucl Whether these are protein or nucleotide sequences. user_list If specified, will be used to include deflines by GI or TI. neg_list If specified, will be used to exclude deflines by GI or TI.

Definition at line 37 of file seqdbvolset.cpp.

References i, int, m_VolList, NCBI_THROW, CSeqDBAtlas::Unlock(), and x_AddVolume().

◆ CSeqDBVolSet() [2/3] CSeqDBVolSet::CSeqDBVolSet ( )

Default Constructor.

An empty volume set will be created; this is in support of the CSeqDBExpert class's default constructor.

Definition at line 89 of file seqdbvolset.cpp.

◆ ~CSeqDBVolSet() CSeqDBVolSet::~CSeqDBVolSet ( )

Destructor.

The destructor will release all resources still held, but some of the resources will probably already be cleaned up via a call to the UnLease method.

Definition at line 94 of file seqdbvolset.cpp.

References i, int, and m_VolList.

◆ CSeqDBVolSet() [3/3]

Private constructor to prevent copy operation.

◆ FindVol() [1/3]

Find a volume by OID.

Many of the CSeqDB methods identify which sequence to use by OID. That OID applies to all sequences in all volumes of the opened database(s). This method is used to find the volume (if any) that contains this OID, and to return both a pointer to that volume and the OID within that volume that corresponds to the global input OID.

Parameters
oid The global OID to search for. vol_oid The returned OID within the relevant volume.
Returns
A pointer to the volume containing the oid, or NULL.

Definition at line 293 of file seqdbvolset.hpp.

References int, m_RecentVol, m_VolList, CSeqDBVolEntry::OIDEnd(), CSeqDBVolEntry::OIDStart(), and CSeqDBVolEntry::Vol().

◆ FindVol() [2/3]

Find a volume by OID.

Many of the CSeqDB methods identify which sequence to use by OID. That OID applies to all sequences in all volumes of the opened database(s). This method is used to find the volume (if any) that contains this OID, and to return both a pointer to that volume and the OID within that volume that corresponds to the global input OID.

Parameters
oid The global OID to search for. vol_oid The returned OID within the relevant volume.
Returns
A pointer to the volume containing the oid, or NULL.

Definition at line 210 of file seqdbvolset.hpp.

Referenced by CSeqDBImpl::GetAmbigPartialSeq(), CSeqDBImpl::GetAmbigSeq(), CSeqDBImpl::GetBioseq(), CSeqDBImpl::GetColumnBlob(), CSeqDBImpl::GetMaskData(), CSeqDBImpl::GetRawSeqAndAmbig(), CSeqDBImpl::GetSeqData(), CSeqDBImpl::GetSeqIDs(), CSeqDBImpl::GetSeqLengthApprox(), CSeqDBImpl::GetSequence(), CSeqDBImpl::OidToGi(), CSeqDBImpl::OidToPig(), CSeqDBImpl::SetOffsetRanges(), CSeqDBImpl::x_FillSeqBuffer(), CSeqDBImpl::x_GetHdr(), CSeqDBImpl::x_GetSeqGI(), CSeqDBImpl::x_GetSeqLength(), and CSeqDBImpl::x_ScanTotals().

◆ FindVol() [3/3]

Find a volume by OID.

Many of the CSeqDB methods identify which sequence to use by OID. That OID applies to all sequences in all volumes of the opened database(s). This method is used to find the volume (if any) that contains this OID, and to return a pointer to that volume, the OID within that volume that corresponds to the global input OID, and the volume index.

Parameters
oid The global OID to search for. vol_oid The returned OID within the relevant volume. vol_idx The returned index of the relevant volume.
Returns
A pointer to the volume containing the oid, or NULL.

Definition at line 245 of file seqdbvolset.hpp.

References int, m_RecentVol, m_VolList, NULL, CSeqDBVolEntry::OIDEnd(), CSeqDBVolEntry::OIDStart(), and CSeqDBVolEntry::Vol().

◆ GetMaxLength() int CSeqDBVolSet::GetMaxLength ( ) const inline ◆ GetMinLength() int CSeqDBVolSet::GetMinLength ( ) const inline ◆ GetNumOIDs() int CSeqDBVolSet::GetNumOIDs ( ) const inline ◆ GetNumVols() int CSeqDBVolSet::GetNumVols ( ) const inline

Get the number of volumes.

This returns the number of volumes available from this set. It would be needed, for example, in order to iterate over all volumes with the GetVol(int) method.

Returns
The number of volumes available from this set.

Definition at line 441 of file seqdbvolset.hpp.

References m_VolList.

Referenced by CSeqDBImpl::AccessionToOids(), CSeqDBLMDBSet::CSeqDBLMDBSet(), CSeqDBImpl::FlushOffsetRangeCache(), CSeqDBAliasFile::GetAliasFileValues(), CSeqDBImpl::GetColumnMetaData(), CSeqDBImpl::GetDate(), CSeqDBImpl::GetGiBounds(), CSeqDBImpl::GetNumOfVols(), CSeqDBImpl::GetOidAtOffset(), CSeqDBImpl::GetPigBounds(), CSeqDBImpl::GetStringBounds(), CSeqDBImpl::GiToOid(), CSeqDBImpl::GiToOidwFilterCheck(), CSeqDBImpl::HashToOids(), CSeqDBImpl::IdsToOids(), CSeqDBImpl::ListColumns(), CSeqDBImpl::PigToOid(), s_GetFilteredOidRange(), CSeqDBImpl::SeqidToOids(), CSeqDBImpl::SetVolsMemBit(), CSeqDBImpl::SetVolsOidMaskType(), CSeqDBImpl::TiToOid(), CSeqDBImpl::x_BuildMaskAlgorithmList(), CSeqDBOIDList::x_ComputeFilters(), CSeqDBImpl::x_GetColumnId(), CSeqDBGiListSet::x_ResolveNegativeList(), CSeqDBGiListSet::x_ResolvePositiveList(), and CSeqDBOIDList::x_Setup().

◆ GetVol() [1/3]

Find a volume by name (non-const version).

Each volume has a name, which is the name of the component files (.pin, .psq, etc), without the file extension. This method returns a non-const pointer to the volume matching the specified name.

Parameters
volname The name of the volume to search for.
Returns
A pointer to the volume matching the specified name, or NULL.

Definition at line 426 of file seqdbvolset.hpp.

References x_FindVolName().

◆ GetVol() [2/3]

Find a volume by name.

Each volume has a name, which is the name of the component files (.pin, .psq, etc), without the file extension. This method returns a const pointer to the volume matching the specified name.

Parameters
volname The name of the volume to search for.
Returns
A pointer to the volume matching the specified name, or NULL.

Definition at line 407 of file seqdbvolset.hpp.

References x_FindVolName().

◆ GetVol() [3/3]

Find a volume by index.

This method returns a volume by index, so that 0 is the first volume, and N-1 is the last volume of a set of N.

Parameters
i The index of the volume to return.
Returns
A pointer to the indicated volume, or NULL.

Definition at line 333 of file seqdbvolset.hpp.

References i, m_RecentVol, and m_VolList.

Referenced by CSeqDBImpl::AccessionToOids(), CSeqDBLMDBSet::CSeqDBLMDBSet(), CSeqDBAliasFile::GetAliasFileValues(), CSeqDBImpl::GetDate(), CSeqDBImpl::GetGiBounds(), CSeqDBImpl::GetOidAtOffset(), CSeqDBImpl::GetPigBounds(), CSeqDBImpl::GetSeqType(), CSeqDBImpl::GetStringBounds(), CSeqDBImpl::GiToOid(), CSeqDBImpl::GiToOidwFilterCheck(), CSeqDBImpl::HashToOids(), CSeqDBImpl::IdsToOids(), CSeqDBImpl::PigToOid(), s_GetFilteredOidRange(), CSeqDBImpl::SeqidToOids(), CSeqDBImpl::TiToOid(), and CSeqDBAliasNode::WalkNodes().

◆ GetVolEntry() ◆ GetVolNonConst()

Find a volume by index.

This method returns a volume by index, so that 0 is the first volume, and N-1 is the last volume of a set of N.

Parameters
i The index of the volume to return.
Returns
A pointer to the indicated volume, or NULL.

Definition at line 357 of file seqdbvolset.hpp.

References i, m_RecentVol, and m_VolList.

Referenced by CSeqDBImpl::FlushOffsetRangeCache(), CSeqDBImpl::GetColumnMetaData(), CSeqDBImpl::ListColumns(), CSeqDBImpl::SetVolsMemBit(), CSeqDBImpl::SetVolsOidMaskType(), CSeqDBImpl::x_BuildMaskAlgorithmList(), and CSeqDBImpl::x_GetColumnId().

◆ GetVolOIDStart() int CSeqDBVolSet::GetVolOIDStart ( int  i ) const inline ◆ GetVolumeSetLength() Uint8 CSeqDBVolSet::GetVolumeSetLength ( ) const inline

Find total volume length for all volumes.

Each volume in the set has an internally stored length, which indicates the length (in nucleotides/residues/bases) of all of the sequences in the volume. This returns the total of these lengths.

Returns
The sum of the lengths of all volumes.

Definition at line 503 of file seqdbvolset.hpp.

References int, and m_VolList.

Referenced by s_VerifySeqidlist(), and CSeqDBImpl::x_GetVolumeLength().

◆ operator=()

Private operator to prevent assignment.

◆ OptimizeGiLists() void CSeqDBVolSet::OptimizeGiLists ( ) inline

Optimize the GI list configuration.

This tells the volumes to examine and optimize their GI list configuration. It should not be called until all GI lists have been added to the volumes (by alias file processing).

Definition at line 541 of file seqdbvolset.hpp.

References i, int, and m_VolList.

Referenced by CSeqDBImpl::CSeqDBImpl().

◆ UnLease() void CSeqDBVolSet::UnLease ( ) inline ◆ x_AddVolume()

Add a volume.

This method adds a volume to the set.

Parameters
atlas The memory management layer object. nm The name of the volume. pn The sequence type. user_list If specified, will be used to include deflines by ID. neg_list If specified, will be used to exclude deflines by ID. locked The lock holder object for this thread.

Definition at line 101 of file seqdbvolset.cpp.

References m_VolList, CSeqDBVolEntry::SetStartAndEnd(), and x_GetNumOIDs().

Referenced by CSeqDBVolSet().

◆ x_FindVolName() [1/2]

Find a volume by name.

This returns the CSeqDBVolEntry object for the volume matching the specified name (non const version).

Parameters
volname The name of the volume.
Returns
A non-const pointer to the CSeqDBVolEntry object, or NULL.

Definition at line 616 of file seqdbvolset.hpp.

References i, int, and m_VolList.

◆ x_FindVolName() [2/2] ◆ x_GetNumOIDs() int CSeqDBVolSet::x_GetNumOIDs ( ) const inlineprivate ◆ m_RecentVol volatile int CSeqDBVolSet::m_RecentVol mutableprivate

The index of the most recently used volume.

This variable is mutable and volatile, but is not protected by locking. Instead, the following precautions are always taken.

1. First, the value is copied into a local variable. 2. Secondly, the range is always checked. 3. It is always treated as a hint; there is always fallback code to search for the correct volume.

Definition at line 639 of file seqdbvolset.hpp.

Referenced by FindVol(), GetVol(), GetVolEntry(), GetVolNonConst(), and GetVolOIDStart().

◆ m_VolList

The actual set of volumes.

Definition at line 628 of file seqdbvolset.hpp.

Referenced by CSeqDBVolSet(), FindVol(), GetMaxLength(), GetMinLength(), GetNumVols(), GetVol(), GetVolEntry(), GetVolNonConst(), GetVolOIDStart(), GetVolumeSetLength(), OptimizeGiLists(), UnLease(), x_AddVolume(), x_FindVolName(), x_GetNumOIDs(), and ~CSeqDBVolSet().

The documentation for this class was generated from the following files:


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