19 #ifndef OST_IO_IO_PROFILE_HH
20 #define OST_IO_IO_PROFILE_HH
28 namespace ost {
namespace io {
31 struct DLLEXPORT IOProfile {
35 dialect(d), quack_mode(qm), fault_tolerant(ft), join_spread_atom_records(js),
36 no_hetatms(nh), calpha_only(co), read_conect(rc), processor(proc)
40 IOProfile(): dialect(
"PDB"), quack_mode(false), fault_tolerant(false),
41 join_spread_atom_records(false), no_hetatms(false),
42 calpha_only(false), read_conect(false), processor()
48 bool join_spread_atom_records;
55 return IOProfile(dialect, quack_mode, fault_tolerant, join_spread_atom_records,
56 no_hetatms, calpha_only, read_conect,
62 inline std::ostream&
operator<<(std::ostream& stream,
const IOProfile& p)
64 stream <<
"IOProfile(dialect='" << p.dialect
65 <<
"', quack_mode=" << (p.quack_mode ?
"True" :
"False") <<
", "
66 <<
"join_spread_atom_records=" << (p.join_spread_atom_records ?
"True" :
"False") <<
", "
67 <<
"calpha_only=" << (p.calpha_only ?
"True" :
"False") <<
", "
68 <<
"fault_tolerant=" << (p.fault_tolerant ?
"True" :
"False") <<
", "
69 <<
"no_hetatms=" << (p.no_hetatms ?
"True" :
"False") <<
", "
70 <<
"read_conect=" << (p.read_conect ?
"True" :
"False") <<
", "
71 <<
"processor=" << (p.processor ? p.processor->ToString() :
"None") <<
")";
77 static IOProfileRegistry& Instance();
81 return profiles_[key];
86 profiles_[key]=profile;
91 if (IOProfileRegistry::alive) {
100 std::map<String, IOProfile> profiles_;
IOProfile(String d, bool qm, bool ft, bool js, bool nh, bool co, bool rc, conop::ProcessorPtr proc=conop::ProcessorPtr())
boost::shared_ptr< Processor > ProcessorPtr
static void RemoveProfiles()
void Set(const String &key, const IOProfile &profile)
IOProfile & Get(const String &key)
std::ostream & operator<<(std::ostream &stream, const FormattedLine &line)
static IOProfileRegistry & Instance()