symmetric behavior load/save
default name reflects fact that material.yaml has a fixed name
This commit is contained in:
parent
ae959b9cc2
commit
01af348cd9
|
@ -24,6 +24,20 @@ class ConfigMaterial(Config):
|
|||
super().save(fname,**kwargs)
|
||||
|
||||
|
||||
@classmethod
|
||||
def load(cls,fname='material.yaml'):
|
||||
"""
|
||||
Load from yaml file.
|
||||
|
||||
Parameters
|
||||
----------
|
||||
fname : file, str, or pathlib.Path, optional
|
||||
Filename or file for writing. Defaults to 'material.yaml'.
|
||||
|
||||
"""
|
||||
return super(ConfigMaterial,cls).load(fname)
|
||||
|
||||
|
||||
@staticmethod
|
||||
def from_table(table,constituents={},**kwargs):
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue