argclz.core.parse_args#

argclz.core.parse_args(instance, args=None)[source]#

Parse the command-list arguments and apply the parsed values to the given instance

Parameters:
  • instance (T) – any instance that contains argument.

  • args (list[str] | None) – A list of strings representing command-line arguments. If None, uses sys.argv

Returns:

instance itself, with attributes populated

Return type:

T