Structural Bioinformatics Library
Template C++ / Python API for developping structural bioinformatics applications.
T_Spheres_3_file_loader< Sphere3, Point3 > Class Template Reference


Loader for one or more txt files listing 3D spheres More...

#include "Spheres_3_file_loader.hpp"

Public Types

typedef T_Spheres_3_file_loader< Sphere3, Point3 > Self
 
typedef SBL::IO::Loader_base Base
 

Static Public Member Functions

static boost::program_options::options_description *& get_options (void)
 Access to the options' description of the module. More...
 
static bool has_options (void)
 
static void delete_options (void)
 
static void initialize_options (const std::string &caption)
 

Accessors

static void add_input_file_name (const std::string &file_name)
 Add manually the name of an input text file. More...
 
unsigned get_number_of_loaded_geometric_models (void) const
 Number of loaded files. More...
 
const Molecular_geometric_model & get_geometric_model (unsigned i) const
 ith container of the loaded 3D spheres from the ith file (const). More...
 
Molecular_geometric_model & get_geometric_model (unsigned i)
 ith container of the loaded 3D spheres from the ith file. More...
 
const Molecular_geometric_model & get_geometric_model (void) const
 Container of the loaded 3D spheres (const). More...
 
Molecular_geometric_model & get_geometric_model (void)
 Container of the loaded 3D spheres. More...
 

Mandatory Requirements

boost::program_options::options_description add_options (void) const
 Virtual method for adding options to the module. More...
 
bool load (unsigned verbose, std::ostream &out)
 Loads the data. More...
 
bool check_options (std::string &message) const
 Checks that the input options' values are coherent. More...
 
std::string get_output_prefix (void) const
 Returns a prefix that concatains the input line options used when running the module. More...
 
std::string get_name (void) const
 Return the name of the class itself. More...
 

Management

void set_loader_instance_name (const std::string &loader_instance_name)
 
const std::string & get_loader_instance_name (void) const
 

Detailed Description

template<class Sphere3, class Point3 = typename Sphere3::Point>
class SBL::Models::T_Spheres_3_file_loader< Sphere3, Point3 >


Loader for one or more txt files listing 3D spheres

It simply loads one or more files listing 3D spheres (1 sphere per line with the center coordinates and the radius) onto containers. Note that for compatibility with the CGAL library, even if the spheres are describes with their radius in the input file, the squared radius is stored in the objects of type Sphere3

Template Parameters
Sphere3Representation of a 3D sphere, that should be constructible from its center and its radius.
Point3Representation of the center of a 3D sphere, that should be constructible from its coordinates.

Member Typedef Documentation

◆ Base

◆ Self

typedef T_Spheres_3_file_loader<Sphere3, Point3> Self

Member Function Documentation

◆ add_input_file_name()

void add_input_file_name ( const std::string &  file_name)
inlinestatic

Add manually the name of an input text file.

◆ add_options()

boost::program_options::options_description add_options ( void  ) const
inlinevirtual

Virtual method for adding options to the module.

Reimplemented from T_Module_option_description< Dummy >.

◆ check_options()

bool check_options ( std::string &  message) const
inlinevirtual

Checks that the input options' values are coherent.

Reimplemented from T_Module_option_description< Dummy >.

◆ delete_options()

static void delete_options ( void  )
inlinestaticinherited

◆ get_geometric_model() [1/4]

T_Spheres_3_file_loader< Sphere3, Point3 >::Molecular_geometric_model & get_geometric_model ( unsigned  i)
inline

ith container of the loaded 3D spheres from the ith file.

Precondition
there are at least (i+1) loaded files.

◆ get_geometric_model() [2/4]

const T_Spheres_3_file_loader< Sphere3, Point3 >::Molecular_geometric_model & get_geometric_model ( unsigned  i) const
inline

ith container of the loaded 3D spheres from the ith file (const).

Precondition
there are at least (i+1) loaded files.

◆ get_geometric_model() [3/4]

T_Spheres_3_file_loader< Sphere3, Point3 >::Molecular_geometric_model & get_geometric_model ( void  )
inline

Container of the loaded 3D spheres.

Precondition
Only one text file name was given.

◆ get_geometric_model() [4/4]

const T_Spheres_3_file_loader< Sphere3, Point3 >::Molecular_geometric_model & get_geometric_model ( void  ) const
inline

Container of the loaded 3D spheres (const).

Precondition
Only one text file name was given.

◆ get_loader_instance_name()

const std::string& get_loader_instance_name ( void  ) const
inlineinherited

◆ get_name()

std::string get_name ( void  ) const
inlinevirtual

Return the name of the class itself.

Reimplemented from Loader_base.

◆ get_number_of_loaded_geometric_models()

unsigned get_number_of_loaded_geometric_models ( void  ) const
inline

Number of loaded files.

◆ get_options()

static boost::program_options::options_description*& get_options ( void  )
inlinestaticinherited

Access to the options' description of the module.

◆ get_output_prefix()

std::string get_output_prefix ( void  ) const
inlinevirtual

Returns a prefix that concatains the input line options used when running the module.

Reimplemented from T_Module_option_description< Dummy >.

◆ has_options()

static bool has_options ( void  )
inlinestaticinherited

◆ initialize_options()

static void initialize_options ( const std::string &  caption)
inlinestaticinherited

◆ load()

bool load ( unsigned  verbose,
std::ostream &  out 
)
inlinevirtual

Loads the data.

Reimplemented from Loader_base.

◆ set_loader_instance_name()

void set_loader_instance_name ( const std::string &  loader_instance_name)
inlineinherited