marcxml2mods.transformators module

marcxml2mods.transformators.transform_to_mods_mono(marc_xml, uuid)

Convert marc_xml to MODS data format.

Parameters:
  • marc_xml (str) – Filename or XML string. Don’t use \n in case of filename.
  • uuid (str) – UUID string giving the package ID.
Returns:

Collection of transformed xml strings.

Return type:

list

marcxml2mods.transformators.transform_to_mods_multimono(marc_xml, uuid)

Convert marc_xml to multimonograph MODS data format.

Parameters:
  • marc_xml (str) – Filename or XML string. Don’t use \n in case of filename.
  • uuid (str) – UUID string giving the package ID.
Returns:

Collection of transformed xml strings.

Return type:

list

marcxml2mods.transformators.transform_to_mods_periodical(marc_xml, uuid)

Convert marc_xml to periodical MODS data format.

Parameters:
  • marc_xml (str) – Filename or XML string. Don’t use \n in case of filename.
  • uuid (str) – UUID string giving the package ID.
Returns:

Collection of transformed xml strings.

Return type:

list

marcxml2mods.transformators.marcxml2mods(marc_xml, uuid)

Convert marc_xml to MODS. Decide type of the record and what template to use (monograph, multi-monograph, periodical).

Parameters:
  • marc_xml (str) – Filename or XML string. Don’t use \n in case of filename.
  • uuid (str) – UUID string giving the package ID.
Returns:

Collection of transformed xml strings.

Return type:

list