NCBI C++ ToolKit
masked_range_set.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: masked_range_set.hpp 42213 2009-06-15 18:32:16Z camacho $
2 * ===========================================================================
3 *
4 * PUBLIC DOMAIN NOTICE
5 * National Center for Biotechnology Information
6 *
7 * This software/database is a "United States Government Work" under the
8 * terms of the United States Copyright Act. It was written as part of
9 * the author's official duties as a United States Government employee and
10 * thus cannot be copyrighted. This software/database is freely available
11 * to the public for use. The National Library of Medicine and the U.S.
12 * Government have not placed any restriction on its use or reproduction.
13 *
14 * Although all reasonable efforts have been taken to ensure the accuracy
15 * and reliability of the software and data, the NLM and the U.S.
16 * Government do not and cannot warrant the performance or results that
17 * may be obtained by using this software or data. The NLM and the U.S.
18 * Government disclaim all warranties, express or implied, including
19 * warranties of performance, merchantability or fitness for any particular
20 * purpose.
21 *
22 * Please cite the author in any work or product based on this material.
23 *
24 * ===========================================================================
25 *
26 * Author: Kevin Bealer
27 *
28 */
29 
30 #ifndef _MASKED_RANGE_SET_HPP_
31 #define _MASKED_RANGE_SET_HPP_
32 
34 
37 
38 /** @file masked_range_set.hpp
39  FIXME
40 */
41 
42 // First version will be simple -- it will use universal Seq-loc
43 // logic. If performance is a problem then it might be best to have
44 // two containers, one with a Seq-loc key and one with an integer key.
45 
47 public:
48  void Insert(int algo_id,
49  const CSeq_id & id,
50  const CSeq_loc & v)
51  {
53  }
54 
55  virtual CMaskedRangesVector &
56  GetRanges(const list< CRef<CSeq_id> > & idlist);
57 
58 private:
59  void x_FindAndCombine(CConstRef<CSeq_loc> & L1, int algo_id,
60  CSeq_id_Handle& id);
61 
62  static void x_CombineLocs(CConstRef<CSeq_loc> & L1, const CSeq_loc & L2);
63 
64  CConstRef<CSeq_loc> & x_Set(int algo_id, CSeq_id_Handle id);
65 
67 
69  vector< TAlgoMap > m_Values;
70 };
71 
72 #endif /* _MASKED_RANGE_SET_HPP_ */
Code to build a database given various sources of sequence data.
vector< TAlgoMap > m_Values
CMaskedRangesVector m_Ranges
void Insert(int algo_id, const CSeq_id &id, const CSeq_loc &v)
static void x_CombineLocs(CConstRef< CSeq_loc > &L1, const CSeq_loc &L2)
void x_FindAndCombine(CConstRef< CSeq_loc > &L1, int algo_id, CSeq_id_Handle &id)
CConstRef< CSeq_loc > & x_Set(int algo_id, CSeq_id_Handle id)
virtual CMaskedRangesVector & GetRanges(const list< CRef< CSeq_id > > &idlist)
Get ranges of masking data for the given Seq-ids.
map< CSeq_id_Handle, CConstRef< CSeq_loc > > TAlgoMap
This represents a set of masks for a given sequence.
Definition: writedb.hpp:65
An interface providing lookups of mask-data by Seq-id.
Definition: build_db.hpp:120
Definition: map.hpp:338
static CSeq_id_Handle GetHandle(const CSeq_id &id)
Normal way of getting a handle, works for any seq-id.
USING_SCOPE(objects)
USING_NCBI_SCOPE
Modified on Wed Apr 24 14:14:46 2024 by modify_doxy.py rev. 669887