colvarproxy_namd.C File Reference

#include <errno.h>
#include "common.h"
#include "fstream_namd.h"
#include "BackEnd.h"
#include "InfoStream.h"
#include "Node.h"
#include "Molecule.h"
#include "PDB.h"
#include "PDBData.h"
#include "ReductionMgr.h"
#include "ScriptTcl.h"
#include <tcl.h>
#include "colvarmodule.h"
#include "colvaratoms.h"
#include "colvarproxy.h"
#include "colvarproxy_namd.h"
#include "colvarscript.h"

Go to the source code of this file.

Enumerations

enum  e_pdb_field {
  e_pdb_none, e_pdb_occ, e_pdb_beta, e_pdb_x,
  e_pdb_y, e_pdb_z, e_pdb_ntot
}

Functions

e_pdb_field pdb_field_str2enum (std::string const &pdb_field_str)


Enumeration Type Documentation

enum e_pdb_field

Enumerator:
e_pdb_none 
e_pdb_occ 
e_pdb_beta 
e_pdb_x 
e_pdb_y 
e_pdb_z 
e_pdb_ntot 

Definition at line 710 of file colvarproxy_namd.C.

00710                  {
00711   e_pdb_none,
00712   e_pdb_occ,
00713   e_pdb_beta,
00714   e_pdb_x,
00715   e_pdb_y,
00716   e_pdb_z,
00717   e_pdb_ntot
00718 };


Function Documentation

e_pdb_field pdb_field_str2enum ( std::string const &  pdb_field_str  ) 

Definition at line 721 of file colvarproxy_namd.C.

References e_pdb_beta, e_pdb_none, e_pdb_occ, e_pdb_x, e_pdb_y, and e_pdb_z.

Referenced by colvarproxy_namd::load_atoms(), and colvarproxy_namd::load_coords().

00722 {
00723   e_pdb_field pdb_field = e_pdb_none;
00724 
00725   if (colvarparse::to_lower_cppstr(pdb_field_str) ==
00726       colvarparse::to_lower_cppstr("O")) {
00727     pdb_field = e_pdb_occ;
00728   }
00729 
00730   if (colvarparse::to_lower_cppstr(pdb_field_str) ==
00731       colvarparse::to_lower_cppstr("B")) {
00732     pdb_field = e_pdb_beta;
00733   }
00734 
00735   if (colvarparse::to_lower_cppstr(pdb_field_str) ==
00736       colvarparse::to_lower_cppstr("X")) {
00737     pdb_field = e_pdb_x;
00738   }
00739 
00740   if (colvarparse::to_lower_cppstr(pdb_field_str) ==
00741       colvarparse::to_lower_cppstr("Y")) {
00742     pdb_field = e_pdb_y;
00743   }
00744 
00745   if (colvarparse::to_lower_cppstr(pdb_field_str) ==
00746       colvarparse::to_lower_cppstr("Z")) {
00747     pdb_field = e_pdb_z;
00748   }
00749 
00750   if (pdb_field == e_pdb_none) {
00751     cvm::error("Error: unsupported PDB field, \""+
00752                pdb_field_str+"\".\n", INPUT_ERROR);
00753   }
00754 
00755   return pdb_field;
00756 }


Generated on Tue Sep 19 01:17:15 2017 for NAMD by  doxygen 1.4.7