PyMaterialXCore.UnitDef

class UnitDef

Bases: Element

A unit definition element within a Document.

See:

https://materialx.org/docs/api/class_unit_def.html

Methods

__init__(*args, **kwargs)

addUnit(self, arg0)

getUnit(self, arg0)

getUnitType(self)

getUnits(self)

hasUnitType(self)

setUnitType(self, arg0)

Attribute Names

UNITTYPE_ATTRIBUTE = 'unittype'

Properties

CATEGORY = 'unitdef'

Methods

__init__(*args, **kwargs)
addUnit(self: UnitDef, arg0: str) Unit
getUnit(self: UnitDef, arg0: str) Unit
getUnitType(self: UnitDef) str
getUnits(self: UnitDef) list[Unit]
hasUnitType(self: UnitDef) bool
setUnitType(self: UnitDef, arg0: str) None