4.1. The SW-Design of namedtupledefs

Changes to the original code extracted from standard library collections:

  1. The template for the created tuple class:

    1. Added member variable _fielddefaults - for documentation and online use.

    2. Changed the call parameters of __new__ to {new_args} - with default values.

    3. Added method _merge

  2. The fabric code - namedtuple function:

    1. Added documentation in functions doc-string.

    2. Added code block for the creation of the call argument string of ‘__new__’.

    3. Added ‘new_args’ and ‘_fielddefaults’ to the format parameters of the class template.