[ CLASS ] - Class to operate on referenced nodes in Maya.
More...
|
def | __init__ (self, node=None) |
| Constructor. More...
|
|
def | node (self) |
| Node. More...
|
|
def | exists (self) |
| Check whether the node exists. More...
|
|
def | setNode (self, node) |
| Set node. More...
|
|
def | reload (self) |
| Reload the referenced node. More...
|
|
def | duplicate (self) |
| Duplicate given referenced node. More...
|
|
def | remove (self) |
| Remove the given referenced node. More...
|
|
def | __init__ (self, nameSpace=None) |
| Constructor. More...
|
|
def | __init__ (self, nameSpace=None) |
| Constructor. More...
|
|
def | head (self) |
| Get name space portion of the name space. More...
|
|
def | tail (self) |
| Get the tail portion of the name space. More...
|
|
def | isValid (cls, nameSpace) |
| Determine whether given string is a valid name space. More...
|
|
def | removeNameSpace (cls, name) |
| Remove name space from the given name. More...
|
|
def | addNameSpace (cls, nameSpace, name, removeExisting=True) |
| Add given name space to given name. More...
|
|
def | nameSpace (self) |
| NameSpace. More...
|
|
def | setNameSpace (self, nameSpace) |
| Set name space. More...
|
|
[ CLASS ] - Class to operate on referenced nodes in Maya.
import sys
sys.stdout.write(reference.exists())
sys.stdout.write(reference.setNode(node='someMayaFile:pCube1'))
sys.stdout.write(reference.node())
sys.stdout.write(reference.reload())
sys.stdout.write(reference.duplicate())
sys.stdout.write(reference.remove())
◆ __init__()
def sMayaCore.referenceLib.Reference.__init__ |
( |
|
self, |
|
|
|
node = None |
|
) |
| |
Constructor.
- Parameters
-
node | [ str | None | in ] - Name of the node. |
- Exceptions
-
- Returns
- None.
◆ node()
def sMayaCore.referenceLib.Reference.node |
( |
|
self | ) |
|
Node.
- Exceptions
-
- Returns
- str - Name of the node.
-
None - If node is not set.
◆ exists()
def sMayaCore.referenceLib.Reference.exists |
( |
|
self | ) |
|
Check whether the node exists.
Checks whether node is None. Checks whether the node exists.
- Exceptions
-
- Returns
- bool - Result.
◆ setNode()
def sMayaCore.referenceLib.Reference.setNode |
( |
|
self, |
|
|
|
node |
|
) |
| |
Set node.
Returns False if the node is not a referenced node.
- Parameters
-
node | [ str | None | in ] - Name of the node. |
- Exceptions
-
- Returns
- bool - Result.
◆ reload()
def sMayaCore.referenceLib.Reference.reload |
( |
|
self | ) |
|
Reload the referenced node.
- Exceptions
-
- Returns
- bool - Result.
◆ duplicate()
def sMayaCore.referenceLib.Reference.duplicate |
( |
|
self | ) |
|
Duplicate given referenced node.
- Exceptions
-
- Returns
- str - Resolved name of the referenced file.
-
None - If not is not set.
◆ remove()
def sMayaCore.referenceLib.Reference.remove |
( |
|
self | ) |
|
Remove the given referenced node.
- Exceptions
-
- Returns
- bool - Result.
◆ isNodeReferenced()
def sMayaCore.referenceLib.Reference.isNodeReferenced |
( |
|
node | ) |
|
|
static |
Check whether the given node is a referenced node.
- Parameters
-
node | [ str | None | in ] - Name of the node. |
- Exceptions
-
- Returns
- bool - Result.
◆ create()
def sMayaCore.referenceLib.Reference.create |
( |
|
mayaFile, |
|
|
|
nameSpace = None |
|
) |
| |
|
static |
Create reference from given file.
If nameSpace argument left out, file name will be the name space for the referenced nodes.
- Parameters
-
mayaFile | [ str | None | in ] - Name of the file, Maya ASCII or Maya Binary. |
nameSpace | [ str | None | in ] - Namespace of the referenced nodes. |
- Exceptions
-
- Returns
- str - Resolved name of the referenced file.
-
None - If maya file doesn't exist.
◆ duplicateSelected()
def sMayaCore.referenceLib.Reference.duplicateSelected |
( |
| ) |
|
|
static |
Duplicate selected referenced nodes.
- Exceptions
-
- Returns
- None
◆ removeSelected()
def sMayaCore.referenceLib.Reference.removeSelected |
( |
| ) |
|
|
static |
Remove selected referenced nodes.
Method actually removes the referenced file which will be retrieved from the referenced nodes.
- Exceptions
-
- Returns
- None
◆ reloadSelected()
def sMayaCore.referenceLib.Reference.reloadSelected |
( |
| ) |
|
|
static |
Reload selected referenced nodes.
Method actually reloads the referenced file which will be retrieved from the referenced nodes.
- Exceptions
-
- Returns
- None
The documentation for this class was generated from the following file: