parmed.formats.pdbx.PdbxContainers module

A collection of container classes supporting the PDBx/mmCIF storage model.

A base container class is defined which supports common features of data and definition containers. PDBx data files are organized in sections called data blocks which are mapped to data containers. PDBx dictionaries contain definition sections and data sections which are mapped to definition and data containes respectively.

Data in both PDBx data files and dictionaries are organized in data categories. In the PDBx syntax individual items or data identified by labels of the form ‘_categoryName.attributeName’. The terms category and attribute in PDBx jargon are analogous table and column in relational data model, or class and attribute in an object oriented data model.

The DataCategory class provides base storage container for instance data and definition meta data.

class parmed.formats.pdbx.PdbxContainers.CifName[source]

Bases: object

Class of utilities for CIF-style data names -

Methods

attributePart

categoryPart

static attributePart(name)[source]
static categoryPart(name)[source]
class parmed.formats.pdbx.PdbxContainers.ContainerBase(name)[source]

Bases: object

Container base class for data and definition objects.

Methods

append(obj)

Add the input object to the current object catalog.

remove(curName)

Revmove object by name.

rename(curName, newName)

Change the name of an object in place -

replace(obj)

Replace an existing object with the input object

exists

getName

getObj

getObjNameList

getType

printIt

setName

setType

append(obj)[source]

Add the input object to the current object catalog. An existing object of the same name will be overwritten.

exists(name)[source]
getName()[source]
getObj(name)[source]
getObjNameList()[source]
getType()[source]
printIt(fh=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>, type='brief')[source]
remove(curName)[source]

Revmove object by name. Return True on success or False otherwise.

rename(curName, newName)[source]

Change the name of an object in place -

replace(obj)[source]

Replace an existing object with the input object

setName(name)[source]
setType(type)[source]
class parmed.formats.pdbx.PdbxContainers.DataCategory(name, attributeNameList=None, rowList=None)[source]

Bases: parmed.formats.pdbx.PdbxContainers.DataCategoryBase

Methods for creating, accessing, and formatting PDBx cif data categories.

Methods

getFullRow(index)

Return a full row based on the length of the the attribute list.

renameAttribute(curAttributeName, …)

Change the name of an attribute in place -

append

appendAttribute

appendAttributeExtendRows

dumpIt

get

getAttributeCount

getAttributeIndex

getAttributeLengthMaximumList

getAttributeList

getAttributeListWithOrder

getAttributeValueMaxLengthList

getCurrentAttribute

getFormatTypeList

getFormatTypeListX

getIndex

getItemNameList

getName

getRow

getRowCount

getRowIndex

getRowList

getValue

getValueFormatted

getValueFormattedByIndex

hasAttribute

invokeAttributeMethod

invokeCategoryMethod

printIt

removeRow

replaceSubstring

replaceValue

setAttributeNameList

setName

setRowList

setValue

append(row)[source]
appendAttribute(attributeName)[source]
appendAttributeExtendRows(attributeName)[source]
dumpIt(fh=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>)[source]
getAttributeCount()[source]
getAttributeIndex(attributeName)[source]
getAttributeLengthMaximumList()[source]
getAttributeList()[source]
getAttributeListWithOrder()[source]
getAttributeValueMaxLengthList(steps=1)[source]
getCurrentAttribute()[source]
getFormatTypeList(steps=1)[source]
getFormatTypeListX()[source]
getFullRow(index)[source]

Return a full row based on the length of the the attribute list.

getIndex(attributeName)[source]
getItemNameList()[source]
getName()[source]
getRow(index)[source]
getRowCount()[source]
getRowIndex()[source]
getRowList()[source]
getValue(attributeName=None, rowIndex=None)[source]
getValueFormatted(attributeName=None, rowIndex=None)[source]
getValueFormattedByIndex(attributeIndex, rowIndex)[source]
hasAttribute(attributeName)[source]
invokeAttributeMethod(attributeName, type, method, db)[source]
invokeCategoryMethod(type, method, db)[source]
printIt(fh=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>)[source]
removeRow(index)[source]
renameAttribute(curAttributeName, newAttributeName)[source]

Change the name of an attribute in place -

replaceSubstring(oldValue, newValue, attributeName)[source]
replaceValue(oldValue, newValue, attributeName)[source]
setValue(value, attributeName=None, rowIndex=None)[source]
class parmed.formats.pdbx.PdbxContainers.DataCategoryBase(name, attributeNameList=None, rowList=None)[source]

Bases: object

Base object definition for a data category -

Methods

get

setAttributeNameList

setName

setRowList

get()[source]
setAttributeNameList(attributeNameList)[source]
setName(name)[source]
setRowList(rowList)[source]
class parmed.formats.pdbx.PdbxContainers.DataContainer(name)[source]

Bases: parmed.formats.pdbx.PdbxContainers.ContainerBase

Container class for DataCategory objects.

Methods

append(obj)

Add the input object to the current object catalog.

remove(curName)

Revmove object by name.

rename(curName, newName)

Change the name of an object in place -

replace(obj)

Replace an existing object with the input object

exists

getGlobal

getName

getObj

getObjNameList

getType

invokeDataBlockMethod

printIt

setGlobal

setName

setType

getGlobal()[source]
invokeDataBlockMethod(type, method, db)[source]
setGlobal()[source]
class parmed.formats.pdbx.PdbxContainers.DefinitionContainer(name)[source]

Bases: parmed.formats.pdbx.PdbxContainers.ContainerBase

Methods

append(obj)

Add the input object to the current object catalog.

remove(curName)

Revmove object by name.

rename(curName, newName)

Change the name of an object in place -

replace(obj)

Replace an existing object with the input object

exists

getName

getObj

getObjNameList

getType

isAttribute

isCategory

printIt

setName

setType

isAttribute()[source]
isCategory()[source]
printIt(fh=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>, type='brief')[source]