Skip to content
Snippets Groups Projects
Commit 5252923c authored by Marco Biasini's avatar Marco Biasini
Browse files

added option to disable connecting adjacent residues

parent 19bc7445
Branches
Tags
No related merge requests found
......@@ -70,7 +70,8 @@ void HeuristicProcessor::DoProcess(DiagnosticsPtr diags,
this->FillResidueProps(residue, compound);
if (this->GetConnect()) {
this->ConnectAtomsOfResidue(residue, compound, false);
this->ConnectResidues(prev, residue);
if (this->GetConnectAminoAcids())
this->ConnectResidues(prev, residue);
}
prev = residue;
if (!this->GetConnect()) { continue; }
......
......@@ -66,7 +66,7 @@ protected:
mol::AtomHandle LocateAtom(const mol::AtomHandleList&, int ordinal) const;
public:
Processor(): check_bond_feasibility_(false),
assign_torsions_(false), connect_(true),
assign_torsions_(false), connect_(true), connect_aa_(true),
zero_occ_treatment_(CONOP_SILENT) {}
void SetConnect(bool connect) {
connect_ = connect;
......@@ -82,6 +82,12 @@ public:
return assign_torsions_;
}
bool GetConnectAminoAcids() const {
return connect_aa_;
}
void SetConnectAminoAcids(bool c) {
connect_aa_ = c;
}
bool GetCheckBondFeasibility() const {
return check_bond_feasibility_;
}
......@@ -103,6 +109,7 @@ private:
bool check_bond_feasibility_;
bool assign_torsions_;
bool connect_;
bool connect_aa_;
ConopAction zero_occ_treatment_;
};
......
......@@ -73,7 +73,8 @@ void RuleBasedProcessor::DoProcess(DiagnosticsPtr diags,
if (this->GetConnect()) {
this->ConnectAtomsOfResidue(residue, compound,
this->GetStrictHydrogens());
this->ConnectResidues(prev, residue);
if (this->GetConnectAminoAcids())
this->ConnectResidues(prev, residue);
for (mol::AtomHandleList::iterator k = atoms_to_connect.begin(),
e3=atoms_to_connect.end(); k!= e3; ++k) {
this->DistanceBasedConnect(*k);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment