Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
core::fragment::FragmentIO Class Reference

#include <FragmentIO.hh>

Collaboration diagram for core::fragment::FragmentIO:
Collaboration graph
[legend]

Public Member Functions

 FragmentIO ()
 
 FragmentIO (Size top, Size ncopies=1, bool bAnnotate=true)
 
FragSetOP read_data (std::string const &filename)
 read a FragSet... note that this function caches the fragment set. i.e., if you read the same set from multiple positions in the code you get the same set. if you read a new file ... we'll check the cache for stale references and delete them... More...
 
void read_data (std::string const &filename, FrameList &)
 
void read_data (std::istream &data, FrameList &)
 
void write_data (std::string const &file, FragSet const &frags)
 
FragFactoryget_frag_factory ()
 
void set_top_frag_num (Size setting)
 Updates the number of distinct fragments to keep. More...
 
void set_ncopies (Size setting)
 Updates the number of copies of each fragment to keep (default 1) More...
 
void set_read_annotation (bool setting=true)
 Toggles between reading annotated (true) and non-annotated (false) More...
 
void clean_frag_cache ()
 remove all FragSets that are not referenced outside the cache. More...
 

Private Types

typedef std::map< std::string,
FragSetOP
FragFileCache
 

Private Member Functions

void read_next_frames (std::istream &data, std::string &next_line, FrameList &next_frames)
 
void read_frag_data (std::istream &data, std::string &next_line, FrameList &next_frames)
 

Private Attributes

Size top_
 
Size ncopies_
 
bool bAnnotate_
 

Static Private Attributes

static FragFactory frag_factory_
 
static FragFileCache frag_cache_
 

Member Typedef Documentation

typedef std::map< std::string, FragSetOP > core::fragment::FragmentIO::FragFileCache
private

Constructor & Destructor Documentation

core::fragment::FragmentIO::FragmentIO ( )
inline
core::fragment::FragmentIO::FragmentIO ( Size  top,
Size  ncopies = 1,
bool  bAnnotate = true 
)
inline

Member Function Documentation

void core::fragment::FragmentIO::clean_frag_cache ( )

remove all FragSets that are not referenced outside the cache.

References frag_cache_, and core::fragment::tr().

Referenced by protocols::abinitio::IterativeBase::increment_stage(), and read_data().

FragFactory & core::fragment::FragmentIO::get_frag_factory ( void  )

References frag_factory_.

FragSetOP core::fragment::FragmentIO::read_data ( std::string const &  filename)
void core::fragment::FragmentIO::read_data ( std::string const &  filename,
FrameList frames 
)
void core::fragment::FragmentIO::read_data ( std::istream &  data,
FrameList all_frames 
)
void core::fragment::FragmentIO::read_frag_data ( std::istream &  data,
std::string &  next_line,
FrameList next_frames 
)
private
void core::fragment::FragmentIO::read_next_frames ( std::istream &  data,
std::string &  next_line,
FrameList next_frames 
)
private
void core::fragment::FragmentIO::set_ncopies ( Size  setting)
inline

Updates the number of copies of each fragment to keep (default 1)

References ncopies_.

Referenced by protocols::topology_broker::read_frags().

void core::fragment::FragmentIO::set_read_annotation ( bool  setting = true)
inline

Toggles between reading annotated (true) and non-annotated (false)

References bAnnotate_.

Referenced by protocols::topology_broker::read_frags().

void core::fragment::FragmentIO::set_top_frag_num ( Size  setting)
inline

Updates the number of distinct fragments to keep.

References top_.

Referenced by protocols::topology_broker::read_frags().

void core::fragment::FragmentIO::write_data ( std::string const &  file,
FragSet const &  frags 
)

Member Data Documentation

bool core::fragment::FragmentIO::bAnnotate_
private
FragmentIO::FragFileCache core::fragment::FragmentIO::frag_cache_
staticprivate

Referenced by clean_frag_cache(), and read_data().

FragFactory core::fragment::FragmentIO::frag_factory_
staticprivate
Size core::fragment::FragmentIO::ncopies_
private
Size core::fragment::FragmentIO::top_
private

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