Structural Bioinformatics Library
Template C++ / Python API for developping structural bioinformatics applications.
Radius_of_atom< NT, Atom > Class Template Reference

#include <atom_classifier.h>

Public Types

typedef Atom Query_type
 
typedef std::string Key_type
 
typedef NT Value_type
 

Public Member Functions

 Radius_of_atom (const NT &radius, const unsigned &index)
 
 Radius_of_atom (std::stringstream &ss, unsigned index)
 

Static Public Member Functions

template<class Dictionary , class Vector_properties >
static unsigned default_loader (Dictionary &dict, Vector_properties &vect)
 
static std::string make_key (const Atom &atom)
 
template<class Dictionary >
static unsigned add_classification (std::stringstream &ss, Dictionary &dict)
 
static void handle_extra (std::stringstream &ss)
 
static int & index_of_default ()
 

Detailed Description

template<class NT, class Atom>
class ESBTL::Radius_of_atom< NT, Atom >

A property class associating a radius to an atom.

Template Parameters
NTis the number type used for the radius.
Atomis the atom type.

Member Typedef Documentation

◆ Key_type

typedef std::string Key_type

The type of the hash key

◆ Query_type

typedef Atom Query_type

The type on which the queries are made,

◆ Value_type

typedef NT Value_type

The number type of the property stored, here the radius.

Constructor & Destructor Documentation

◆ Radius_of_atom() [1/2]

Radius_of_atom ( const NT &  radius,
const unsigned &  index 
)
inline

Constructor

Parameters
radiusis the radius associated to this property class.
indexis the index of the property.

◆ Radius_of_atom() [2/2]

Radius_of_atom ( std::stringstream &  ss,
unsigned  index 
)
inline

Constructor

Parameters
ssis a string stream containing information about the property. ss must contains the radius associated to index (ex: 1.4).
indexis the index of the property.

Member Function Documentation

◆ add_classification()

static unsigned add_classification ( std::stringstream &  ss,
Dictionary &  dict 
)
inlinestatic

Function adding the classification of an atom type.

Template Parameters
Dictionaryan associative container, mapping a Query_type to the index of a property.
Parameters
ssis a string stream containing the classification of an atom type. ss must contains in this order the residue name, the atom name and the index of the property (ex: ALA N 5)
dictis the container mapping atoms to the index of a property.

◆ default_loader()

static unsigned default_loader ( Dictionary &  dict,
Vector_properties &  vect 
)
inlinestatic

Function filling default radius of atoms. Current implementation uses radii from Tsai J, Taylor R, Chothia C, Gerstein M. J Mol Biol. 1999 Jul 2;290(1):253-66.

Template Parameters
Dictionaryan associative container, mapping a Query_type to the index of a property.
Vector_propertiesis a vector storing the properties.
Parameters
dictis the container mapping atoms to the index of a property.
vectis a vector storing properties.

◆ handle_extra()

static void handle_extra ( std::stringstream &  ss)
inlinestatic

Unused function in that class (but definition needed by the classifier).

Parameters
ssa string stream.

◆ index_of_default()

static int& index_of_default ( )
inlinestatic

Function indicating the index of the property assigned to an unknown atom type. By default this value is -1, which indicate to the classifier that unknown atoms are not expected.

◆ make_key()

static std::string make_key ( const Atom &  atom)
inlinestatic

Function defining a unique identifier of an atom type.

Parameters
atomis an atom.