RDKit: BitVectUtils.h Source File

| RDKit Open-source cheminformatics and machine learning.

Loading...
Searching...
No Matches
BitVectUtils.h
Go to the documentation of this file.
1//
2// Copyright (c) 2002-2006 greg Landrum, Rational Discovery LLC
3//
4// @@ All Rights Reserved @@
5// This file is part of the RDKit.
6// The contents are covered by the terms of the BSD license
7// which is included in the file license.txt, found at the root
8// of the RDKit source tree.
9//
10#include <RDGeneral/export.h>
11#ifndef __RD_BITVECTS_UTILS_H__
12#define __RD_BITVECTS_UTILS_H__
13
14#include "BitVects.h"
15#include <string>
16
17//! \brief Construct a BitVect from the ASCII representation of a
18//! Daylight fingerprint string
19template <typename T>
20 RDKIT_DATASTRUCTS_EXPORT void FromDaylightString(T &sbv, const std::string &s);
21
22//! \brief Construct a BitVect from the ASCII representation of a
23//! bit string (i.e. a bunch of zeros and ones)
24template <typename T>
25 RDKIT_DATASTRUCTS_EXPORT void FromBitString(T &sbv, const std::string &s);
26
27//! Convert a SparseBitVector to an ExplicitBitVector
28/*!
29 \return a pointer to an ExplicitBitVector
30 <b>Note:</b> the caller is responsible for <tt>delete</tt>ing this.
31
32 */
33 RDKIT_DATASTRUCTS_EXPORT ExplicitBitVect *convertToExplicit(
34 const SparseBitVect *sbv);
35#endif
convertToExplicit
RDKIT_DATASTRUCTS_EXPORT ExplicitBitVect * convertToExplicit(const SparseBitVect *sbv)
Convert a SparseBitVector to an ExplicitBitVector.
FromDaylightString
RDKIT_DATASTRUCTS_EXPORT void FromDaylightString(T &sbv, const std::string &s)
Construct a BitVect from the ASCII representation of a Daylight fingerprint string.
FromBitString
RDKIT_DATASTRUCTS_EXPORT void FromBitString(T &sbv, const std::string &s)
Construct a BitVect from the ASCII representation of a bit string (i.e. a bunch of zeros and ones)
BitVects.h
Pulls in all the BitVect classes.
ExplicitBitVect
a class for bit vectors that are densely occupied
Definition ExplicitBitVect.h:29
SparseBitVect
a class for bit vectors that are sparsely occupied.
Definition SparseBitVect.h:35
export.h
RDKIT_DATASTRUCTS_EXPORT
#define RDKIT_DATASTRUCTS_EXPORT
Definition export.h:89