Reference

class cgp_maya_utils.scene.Reference(name)

Bases: cgp_maya_utils.scene.Node

node object that manipulates a reference node

classmethod create(path=None, namespace=None, **__)

create a reference

Parameters:
Returns:

the created reference

Return type:

cgp_maya_utils.scene.Reference

data()

data necessary to store the reference node on disk and/or recreate it from scratch

Returns:the data of the reference
Return type:dict
delete()

delete the reference

file_()

the file associated to the reference node

Returns:the file of the reference node
Return type:cgp_maya_utils.scene.MayaFile
import_(namespaceSubstitute=None)

import the objects from reference

Parameters:namespaceSubstitute (str) – string that will replace the : of the namespace
namespace()

the namespace of the node

Returns:the namespace of the node
Return type:cgp_maya_utils.scene.Namespace
setNamespace(namespace, renameNode=True)

set the namespace

Parameters:
  • namespace (str or cgp_maya_utils.scene.Namespace) – namespace to set
  • renameNode (bool) – True : the reference node is renamed - False : the reference node is not renamed