[ CLASS ] - Class provides functionalities to operate on optionVar in Maya.
More...
[ CLASS ] - Class provides functionalities to operate on optionVar in Maya.
import sys
sys.stdout.write(optionVar.exists())
optionVar.setValue('cube1')
sys.stdout.write(optionVar.exists())
sys.stdout.write(optionVar.value())
sys.stdout.write(optionVar.name())
◆ __init__()
def mMayaCore.optionVarLib.OptionVar.__init__ |
( |
|
self, |
|
|
|
name |
|
) |
| |
Constructor.
- Parameters
-
name | [ str | None | in ] - Name of the variable. |
- Exceptions
-
- Returns
- None
◆ name()
def mMayaCore.optionVarLib.OptionVar.name |
( |
|
self | ) |
|
Name of the option variable.
- Exceptions
-
- Returns
- str - Name of the option variable.
-
None - If name is not set.
◆ exists()
def mMayaCore.optionVarLib.OptionVar.exists |
( |
|
self | ) |
|
Check whether the option variable exists.
- Exceptions
-
- Returns
- bool - Result.
◆ remove()
def mMayaCore.optionVarLib.OptionVar.remove |
( |
|
self | ) |
|
Remove the option variable.
- Exceptions
-
- Returns
- None
◆ setValue()
def mMayaCore.optionVarLib.OptionVar.setValue |
( |
|
self, |
|
|
|
value |
|
) |
| |
Set value of the option variable.
- Parameters
-
value | [ int, float, str | None | in ] - Value to be set. |
- Exceptions
-
- Returns
- None
◆ value()
def mMayaCore.optionVarLib.OptionVar.value |
( |
|
self | ) |
|
Get the value of the option variable.
- Exceptions
-
- Returns
- int, float, str - Value of the option variable.
-
None - If option variable doesn't exist.
◆ list()
def mMayaCore.optionVarLib.OptionVar.list |
( |
| ) |
|
|
static |
List all option variables.
- Exceptions
-
- Returns
- str list - Option variables
The documentation for this class was generated from the following file: