Add constants for default options in DiffXWriter.

Review Request #11728 — Created July 17, 2021 and submitted

chipx86
DiffX
master
diffx

These default options are used when writing a DiffX file. The options
were previously stored as hard-coded values in function definitions, but
this meant that other parts of the codebase couldn't refer to those
defaults.

This adds DEFAULT_ENCODING and DEFAULT_PREAMBLE_INDENT to
DiffXWriter.

It also adds a new options definition, MetaFormat, for available
metadata formats. This just includes JSON right now.

Unit tests passed.

Used this with the upcoming DOM change.

Summary
Add constants for default options in DiffXWriter.
Description From Last Updated

Mind having one arg per line instead of mixing it like this?

daviddavid
david
  1. 
      
  2. python/pydiffx/writer.py (Diff revision 1)
     
     
     
     
     

    Mind having one arg per line instead of mixing it like this?

  3. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (265f832)
Loading...