Package Bio :: Package PDB :: Module Residue :: Class Residue
[hide private]
[frames] | no frames]

Class Residue

source code

   object --+    
            |    
Entity.Entity --+
                |
               Residue


Represents a residue. A Residue object stores atoms.

Instance Methods [hide private]
 
__init__(self, id, resname, segid)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
__repr__(self)
repr(x)
source code
 
_sort(self, a1, a2)
Sort the Atom objects.
source code
 
add(self, atom)
Add an Atom object.
source code
 
sort(self) source code
 
flag_disordered(self)
Set the disordered flag.
source code
 
is_disordered(self)
Return 1 if the residue contains disordered atoms.
source code
 
get_resname(self) source code
 
get_unpacked_list(self)
Returns the list of all atoms, unpack DisorderedAtoms."
source code
 
get_segid(self) source code

Inherited from Entity.Entity: __contains__, __delitem__, __getitem__, __iter__, __len__, copy, detach_child, detach_parent, get_full_id, get_id, get_iterator, get_level, get_list, get_parent, has_id, insert, set_parent, transform

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, id, resname, segid)
(Constructor)

source code 
x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

__repr__(self)
(Representation operator)

source code 
repr(x)

Overrides: object.__repr__
(inherited documentation)

_sort(self, a1, a2)

source code 
Sort the Atom objects.

Atoms are sorted alphabetically according to their name,
but N, CA, C, O always come first.

Arguments:
o a1, a2 - Atom objects

add(self, atom)

source code 
Add an Atom object.

Checks for adding duplicate atoms, and raises a
PDBConstructionException if so.

Overrides: Entity.Entity.add