.. _bibble.people.name_reader: ========================= bibble.people.name_reader ========================= .. py:module:: bibble.people.name_reader .. autoapi-nested-parse:: See EOF for license/metadata/notes as applicable Type Aliases ------------ .. autoapisummary:: bibble.people.name_reader.Block Classes ------- .. autoapisummary:: bibble.people.name_reader.NameReader bibble.people.name_reader._NameToParts_m bibble.people.name_reader._SplitAuthors_m Module Contents =============== .. py:data:: Block :type: TypeAlias :value: model.Block .. _bibble.people.name_reader.NameReader: .. py:class:: NameReader(*, parts = True, authors = True, **kwargs) Bases: :py:obj:`bibble.util.middlecore.IdenBlockMiddleware` A Refactored version of bibtexparser's SplitNameParts and SeparateCoAuthors .. py:method:: field_h(field, entry) -> .. py:method:: on_read() -> .. py:method:: transform_Entry(entry, library) -> .. py:attribute:: _do_name_parts :value: True .. py:attribute:: _do_split_authors :value: True .. py:attribute:: _whitelist :value: ('author', 'editor', 'translator') .. bibble.people.name_reader._NameToParts_m: .. py:class:: _NameToParts_m Adapted from bibtexparser's parse_single_name_into_parts, originally by Blair Bonnett. Parses an individual name into a NameParts_d, a simple data structure containing: - first : list. First names. - von : list. - last : list. Last Names. - jr : list. Bibtex Names are of one of the forms: - first von last - von last, first - von last, jr, first .. py:method:: _build_parts_parser() -> .. py:method:: _first_von_last(p0, cases) -> .. py:method:: _name_to_parts(val, *, strict=True) -> .. py:method:: _parse_name_fsm(val, *, strict=True) -> .. py:method:: _parse_name_pp(val, *, strict=True) -> TODO .. py:method:: _von_last_first(sections, cases) -> .. bibble.people.name_reader._SplitAuthors_m: .. py:class:: _SplitAuthors_m Adapated from bibtexparser's split_multiple_persons_names, originally by Blair Bonnett Splits names by intermediary 'and's. Like its original, treats non-breaking space and '~'s as regular chars not whitespace. 'and's within braces are returned un modified. eg: '{Simon and Schuster}' -> ['{Simon and Schuster}'] .. py:method:: _build_split_parser() -> .. py:method:: _split_authors(val, *, strict=True) -> .. py:method:: _split_authors_fsm(val, *, strict=True) -> .. py:method:: _split_authors_pp(val, *, strict=True) -> TODO