# Copyright (C) 2002, Thomas Hamelryck (thamelry@binf.ku.dk) # This code is part of the Biopython distribution and governed by its # license. Please see the LICENSE file that should have been included # as part of this package. """Output of PDB files.""" import warnings # Exceptions and Warnings from Bio import BiopythonWarning from Bio.PDB.PDBExceptions import PDBIOException # To allow saving of chains, residues, etc.. from Bio.PDB.StructureBuilder import StructureBuilder # Allowed Elements from Bio.Data.IUPACData import atom_weights _ATOM_FORMAT_STRING = ( "%s%5i %-4s%c%3s %c%4i%c %8.3f%8.3f%8.3f%s%6.2f %4s%2s%2s\n" ) _PQR_ATOM_FORMAT_STRING = ( "%s%5i %-4s%c%3s %c%4i%c %8.3f%8.3f%8.3f %7s %6s %2s\n" ) _TER_FORMAT_STRING = ( "TER %5i %3s %c%4i%c \n" ) class Select: """Select everything for PDB output (for use as a base class). Default selection (everything) during writing - can be used as base class to implement selective output. This selects which entities will be written out. """ def __repr__(self): """Represent the output as a string for debugging.""" return "