MaterialXJSON 1.39.0
Loading...
Searching...
No Matches
materialxjson.core.JsonWriteOptions Class Reference

Class for holding options for writing MaterialX to JSON. More...

Public Member Functions

 __init__ (self)
 Constructor.
 

Public Attributes

mx.ElementPredicate elementPredicate = None
 
 indent = None
 
tuple separators = (',', ': ')
 
bool addInputOutputCategories = True
 

Detailed Description

Class for holding options for writing MaterialX to JSON.

Options:

  • elementPredicate: MaterialX function predicate for filtering elements to write
  • indent: The number of spaces to indent the JSON hierarchy
  • separators: JSON separators. Default is: (',', ': ')
  • addInputOutputCategories: Add input and output categories to JSON elements. Default is False

Definition at line 31 of file core.py.

Constructor & Destructor Documentation

◆ __init__()

materialxjson.core.JsonWriteOptions.__init__ ( self)

Constructor.

Definition at line 41 of file core.py.

41 def __init__(self):
42 '''
43 @brief Constructor
44 '''
45 self.elementPredicate: mx.ElementPredicate = None
46 self.indent = None
47 self.separators = (',', ': ')
48 self.addInputOutputCategories = True
49

Member Data Documentation

◆ addInputOutputCategories

bool materialxjson.core.JsonWriteOptions.addInputOutputCategories = True

Definition at line 48 of file core.py.

◆ elementPredicate

mx.ElementPredicate materialxjson.core.JsonWriteOptions.elementPredicate = None

Definition at line 45 of file core.py.

◆ indent

materialxjson.core.JsonWriteOptions.indent = None

Definition at line 46 of file core.py.

◆ separators

tuple materialxjson.core.JsonWriteOptions.separators = (',', ': ')

Definition at line 47 of file core.py.


The documentation for this class was generated from the following file: