Rosetta Utilities  2014.35
Public Member Functions | Private Attributes | Friends | List of all members
basic::resource_manager::ResourceOptions Class Referenceabstract

The ResourceOptions class is responsible for describing all the data requried for instanting a particular resource, except for the data stream (i.e. the file) that contains the data for the resource. For example, when reading in a PDB file, there are 30 different options for how that PDB file should be turned into a Pose. That data is now held in an ImportPoseOptions object. The purpose of the ResourceOptions class is to allow different jobs to load resources in different ways, or for one job to load two different resources of the same type in different ways. For example, a protocol may need both a centroid pose and a fullatom pose to be loaded in from disk; however, if the logic for loading a pose in from disk is controlled by the options system alone, this becomes impossible. More...

#include <ResourceOptions.hh>

Public Member Functions

 ResourceOptions ()
 
 ResourceOptions (std::string const &name)
 Assign a name to an instance of the resource options object. Usefull for identifying flaws in input files defining ResourceOptions. More...
 
virtual ~ResourceOptions ()
 
virtual void show (std::ostream &out) const
 Describe this instance to a given output stream. More...
 
virtual void parse_my_tag (utility::tag::TagCOP tag)=0
 Initialize from the recursive "tag" structure. More...
 
virtual std::string type () const =0
 The class name (its type) for a particular ResourceOptions instance. This function allows for better error message delivery. More...
 
std::string name () const
 A name given to a particular ResourceOptions instance. This function allows for better error message delivery. More...
 
void name (std::string const &setting)
 Set the name for this ResoureOptions instance. More...
 
- Public Member Functions inherited from utility::pointer::ReferenceCount
void ctor ()
 
virtual ~ReferenceCount ()
 Destructor. More...
 
Size ref_count () const
 Reference count. More...
 

Private Attributes

std::string name_
 

Friends

std::ostream & operator<< (std::ostream &out, const ResourceOptions &resource_manager)
 Friend output-operator function that invokes the show() function. More...
 

Additional Inherited Members

- Public Types inherited from utility::pointer::ReferenceCount
typedef platform::Size Size
 
typedef platform::Size size_type
 
- Protected Member Functions inherited from utility::pointer::ReferenceCount
 ReferenceCount ()
 Default constructor. More...
 
 ReferenceCount (ReferenceCount const &)
 Copy constructor. More...
 
ReferenceCountoperator= (ReferenceCount const &)
 Copy assignment. More...
 

Detailed Description

The ResourceOptions class is responsible for describing all the data requried for instanting a particular resource, except for the data stream (i.e. the file) that contains the data for the resource. For example, when reading in a PDB file, there are 30 different options for how that PDB file should be turned into a Pose. That data is now held in an ImportPoseOptions object. The purpose of the ResourceOptions class is to allow different jobs to load resources in different ways, or for one job to load two different resources of the same type in different ways. For example, a protocol may need both a centroid pose and a fullatom pose to be loaded in from disk; however, if the logic for loading a pose in from disk is controlled by the options system alone, this becomes impossible.

Constructor & Destructor Documentation

basic::resource_manager::ResourceOptions::ResourceOptions ( )
basic::resource_manager::ResourceOptions::ResourceOptions ( std::string const &  name)

Assign a name to an instance of the resource options object. Usefull for identifying flaws in input files defining ResourceOptions.

basic::resource_manager::ResourceOptions::~ResourceOptions ( )
virtual

Member Function Documentation

std::string basic::resource_manager::ResourceOptions::name ( ) const

A name given to a particular ResourceOptions instance. This function allows for better error message delivery.

References name_.

Referenced by basic::database::DatabaseSessionLoader::create_resource().

void basic::resource_manager::ResourceOptions::name ( std::string const &  setting)

Set the name for this ResoureOptions instance.

References name_.

virtual void basic::resource_manager::ResourceOptions::parse_my_tag ( utility::tag::TagCOP  tag)
pure virtual

Initialize from the recursive "tag" structure.

Implemented in basic::database::DatabaseSessionOptions.

void basic::resource_manager::ResourceOptions::show ( std::ostream &  out) const
virtual

Describe this instance to a given output stream.

References name_.

Referenced by basic::resource_manager::operator<<().

virtual std::string basic::resource_manager::ResourceOptions::type ( ) const
pure virtual

The class name (its type) for a particular ResourceOptions instance. This function allows for better error message delivery.

Implemented in basic::database::DatabaseSessionOptions.

Referenced by basic::database::DatabaseSessionLoader::create_resource().

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const ResourceOptions resource_manager 
)
friend

Friend output-operator function that invokes the show() function.

Member Data Documentation

std::string basic::resource_manager::ResourceOptions::name_
private

Referenced by name(), and show().


The documentation for this class was generated from the following files: