Chemical Data Processing Library Python API - Version 1.2.0
Classes | Public Member Functions | Properties | List of all members
CDPL.Biomol.PDBData Class Reference

A data structure for the storage of imported PDB data records (see [CTFILE]). More...

+ Inheritance diagram for CDPL.Biomol.PDBData:

Classes

class  RecordType
 

Public Member Functions

None __init__ ()
 Initializes the PDBData instance.
 
None __init__ (PDBData data)
 Initializes a copy of the PDBData instance data. More...
 
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
int getNumRecords ()
 
bool isEmpty ()
 
None clear ()
 
PDBData assign (PDBData data)
 Replaces the current state of self with a copy of the state of the PDBData instance data. More...
 
bool containsRecord (RecordType type)
 
str getData (RecordType type)
 
bool removeRecord (RecordType type)
 
None setRecord (RecordType type, str data)
 
object getRecordTypes ()
 
object getRecordData ()
 
object getRecords ()
 
int __len__ ()
 
str __getitem__ (RecordType type)
 
None __setitem__ (RecordType type, str data)
 
bool __delitem__ (RecordType type)
 
bool __contains__ (RecordType type)
 Returns the result of the membership test operation type in self. More...
 

Properties

 objectID = property(getObjectID)
 
 numRecords = property(getNumRecords)
 
 recordTypes = property(getRecordTypes)
 
 recordData = property(getRecordData)
 
 records = property(getRecords)
 

Detailed Description

A data structure for the storage of imported PDB data records (see [CTFILE]).

Constructor & Destructor Documentation

◆ __init__()

None CDPL.Biomol.PDBData.__init__ ( PDBData  data)

Initializes a copy of the PDBData instance data.

Parameters
dataThe PDBData instance to copy.

Member Function Documentation

◆ getObjectID()

int CDPL.Biomol.PDBData.getObjectID ( )

Returns the numeric identifier (ID) of the wrapped C++ class instance.

Different Python PDBData instances may reference the same underlying C++ class instance. The commonly used Python expression a is not b thus cannot tell reliably whether the two PDBData instances a and b reference different C++ objects. The numeric identifier returned by this method allows to correctly implement such an identity test via the simple expression a.getObjectID() != b.getObjectID().

Returns
The numeric ID of the internally referenced C++ class instance.

◆ getNumRecords()

int CDPL.Biomol.PDBData.getNumRecords ( )
Returns

◆ isEmpty()

bool CDPL.Biomol.PDBData.isEmpty ( )
Returns

◆ assign()

PDBData CDPL.Biomol.PDBData.assign ( PDBData  data)

Replaces the current state of self with a copy of the state of the PDBData instance data.

Parameters
dataThe PDBData instance to copy.
Returns
self

◆ containsRecord()

bool CDPL.Biomol.PDBData.containsRecord ( RecordType  type)
Parameters
type
Returns

◆ getData()

str CDPL.Biomol.PDBData.getData ( RecordType  type)
Parameters
type
Returns

◆ removeRecord()

bool CDPL.Biomol.PDBData.removeRecord ( RecordType  type)
Parameters
type
Returns

◆ setRecord()

None CDPL.Biomol.PDBData.setRecord ( RecordType  type,
str  data 
)
Parameters
type
data

◆ getRecordTypes()

object CDPL.Biomol.PDBData.getRecordTypes ( )
Returns

◆ getRecordData()

object CDPL.Biomol.PDBData.getRecordData ( )
Returns

◆ getRecords()

object CDPL.Biomol.PDBData.getRecords ( )
Returns

◆ __len__()

int CDPL.Biomol.PDBData.__len__ ( )
Returns

◆ __getitem__()

str CDPL.Biomol.PDBData.__getitem__ ( RecordType  type)
Parameters
type
Returns

◆ __setitem__()

None CDPL.Biomol.PDBData.__setitem__ ( RecordType  type,
str  data 
)
Parameters
type
data

◆ __delitem__()

bool CDPL.Biomol.PDBData.__delitem__ ( RecordType  type)
Parameters
type
Returns

◆ __contains__()

bool CDPL.Biomol.PDBData.__contains__ ( RecordType  type)

Returns the result of the membership test operation type in self.

Parameters
typeThe value to test for membership.
Returns
The result of the membership test operation.