class
DocumentMethods
- def add_copied_block(self, block: Block, pos: int = -1) -> Block
- def add_new_block(self, name: str, pos: int = -1) -> Block
- def as_json(self, mmjson: bool = False, lowercase_names: bool = True) -> str
- Returns JSON representation in a string.
- def as_string(self, options: WriteOptions = gemmi.cif.WriteOptions()) -> str
- Returns a string in CIF format.
- def as_string(self, style: Style) -> str
- def check_for_duplicates(self, /) -> None
- def check_for_missing_values(self, /) -> None
- def clear(self, /) -> None
- def find_block(self, name: str) -> Block
- def parse_file(self, arg0: str, /) -> None
- def parse_string(self, arg0: str, /) -> None
- def sole_block(self, /) -> Block
- Returns the only block if there is exactly one
- def write_file(self, filename: str, options: WriteOptions = gemmi.cif.WriteOptions()) -> None
- Write data to a CIF file.
- def write_file(self, filename: str, style: Style) -> None
Special methods
- def __contains__(self, name: str) -> bool
- def __delitem__(self, index: int) -> None
- def __getitem__(self, name: str) -> Block
- def __getitem__(self, index: int) -> Block
- def __getitem__(self, arg0: slice, /) -> list
- def __init__(self, /) -> None
- def __iter__(self, /) -> typing.Iterator
- def __len__(self, /) -> int
- def __repr__(self, /) -> str
Properties
- source: str get set