Package mrv :: Package maya :: Package nt :: Module base :: Class Node
[hide private]
[frames] | no frames]

Class Node

source code

object --+
         |
        Node

Common base for all maya nodes, providing access to the maya internal object representation Use this class to directly create a maya node of the required type
Instance Methods [hide private]
a new object with type S, a subtype of T
__new__(cls, *args, **kwargs)
return the proper class for the given object
source code
 
__hash_2009__(self)
Returns: hash of our object using MObjectHandle functionlity
source code

Inherited from object: __delattr__, __format__, __getattribute__, __init__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

    Overridden Methods
 
__eq__(self, other)
compare the nodes according to their api object.
source code
 
__ne__(self, other) source code
 
__hash__(self)
Returns: hash of our object using MObjectHandle functionlity
source code
    Interface
 
apiObject(self)
Returns: the highest qualified api object of the actual superclass, usually either MObject or MDagPath
source code
 
apiType(self)
Returns: the MFn Type id of the wrapped object
source code
 
hasFn(self, mfntype)
Returns: True if our object supports the given function set type
source code
Class Methods [hide private]
    Interface
 
getMFnClasses(cls)
Returns: list of all function set classes this node supports, most derived function set comes first
source code
Class Variables [hide private]
  __metaclass__ = MetaClassCreatorNodes
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__new__(cls, *args, **kwargs)

source code 
return the proper class for the given object
Parameters:
  • args - arg[0] is the node to be wrapped

    • string: wrap the API object with the respective name
    • MObject
    • MObjectHandle
    • MDagPath

    If args is empty, a new node of the given type will be created within maya. Shapes will automatically receive a parent transform. kwargs will be passed to createNode in that case.

Returns: a new object with type S, a subtype of T
Overrides: object.__new__

Note: This multi-purpose constructor is not perfectly optimized for speed, consider using NodeFromObj instead

__eq__(self, other)
(Equality operator)

source code 
compare the nodes according to their api object. Valid inputs are other Node, MObject or MDagPath instances

__hash_2009__(self)

source code 

hash(x)

Returns:
hash of our object using MObjectHandle functionlity

__hash__(self)
(Hashing function)

source code 

hash(x)

Returns:
hash of our object using MObjectHandle functionlity
Overrides: object.__hash__

apiObject(self)

source code 
Returns:
the highest qualified api object of the actual superclass, usually either MObject or MDagPath

getMFnClasses(cls)
Class Method

source code 
Returns:
list of all function set classes this node supports, most derived function set comes first

apiType(self)

source code 
Returns:
the MFn Type id of the wrapped object

hasFn(self, mfntype)

source code 
Returns:
True if our object supports the given function set type