#include <atom_classifier.h>
Public Types | |
typedef Properties_ | Properties |
typedef Properties_::Key_type | Key_type |
typedef Properties_::Query_type | Query_type |
typedef std::vector < Properties_ >::iterator | Properties_iterator |
typedef std::vector < Properties_ > ::const_iterator | Properties_const_iterator |
Public Member Functions | |
Generic_classifier () | |
Generic_classifier (std::string filename, int) | |
Generic_classifier (const std::string &filename) | |
const Properties & | get_properties (unsigned i) const |
const Properties & | get_properties (const Query_type &query) const |
unsigned | number_of_properties () const |
Properties_iterator | properties_begin () |
Properties_const_iterator | properties_begin () const |
Properties_iterator | properties_end () |
Properties_const_iterator | properties_end () const |
An object that help to associate properties to objects. This can be used for example to to associate a radius or a color to an (pseudo-)atom type.
Properties_ | must follow the concept of Property class. |
typedef Properties_::Key_type ESBTL::Generic_classifier< Properties_ >::Key_type |
typedef Properties_ ESBTL::Generic_classifier< Properties_ >::Properties |
typedef std::vector<Properties_>::const_iterator ESBTL::Generic_classifier< Properties_ >::Properties_const_iterator |
typedef std::vector<Properties_>::iterator ESBTL::Generic_classifier< Properties_ >::Properties_iterator |
typedef Properties_::Query_type ESBTL::Generic_classifier< Properties_ >::Query_type |
ESBTL::Generic_classifier< Properties_ >::Generic_classifier | ( | ) | [inline] |
Default constructor. The method Properties_::default_loader is called to fill in the dictionary and the property vector.
ESBTL::Generic_classifier< Properties_ >::Generic_classifier | ( | std::string | filename, |
int | |||
) | [inline] |
Constructor that uses a file to complete the default properties. Not yet implemented
ESBTL::Generic_classifier< Properties_ >::Generic_classifier | ( | const std::string & | filename | ) | [inline] |
Constructor using a file, default is not loaded. The file must follow the following format:
There are four different sections providing different kind of information:
Note that none of these sections are mandatory.
const Properties& ESBTL::Generic_classifier< Properties_ >::get_properties | ( | unsigned | i | ) | const [inline] |
Returns a property given its index
i | is the index of the desired property (starting from 0). |
const Properties& ESBTL::Generic_classifier< Properties_ >::get_properties | ( | const Query_type & | query | ) | const [inline] |
Returns a property associated to a Query_type object.
query | is the object a property is looking for in the dictionary. |
unsigned ESBTL::Generic_classifier< Properties_ >::number_of_properties | ( | ) | const [inline] |
returns the number of properties.
Properties_const_iterator ESBTL::Generic_classifier< Properties_ >::properties_begin | ( | ) | const [inline] |
Returns the first iterator on properties, const version.
Properties_iterator ESBTL::Generic_classifier< Properties_ >::properties_begin | ( | ) | [inline] |
Returns the first iterator on properties.
Properties_iterator ESBTL::Generic_classifier< Properties_ >::properties_end | ( | ) | [inline] |
Returns the past-end iterator on properties.
Properties_const_iterator ESBTL::Generic_classifier< Properties_ >::properties_end | ( | ) | const [inline] |
Returns the past-end iterator on properties, const version.