# MObject

## Constants

Name | Type | Description
--- | --- | ---
kNullObj | MObject | Used to indicate that an MObject instance does not refer to any internal Maya object. Also used as a default value for MObject parameters to many methods.

## Static Methods

None.

## Static Attributes

None.

## Constructors

Signature | Parameters | Description
--- | --- | ---
MObject() |  | Default constructor. Returns an empty MObject instance (i.e. one which contains kNullObj).
MObject(src) | src - MObject | Copy constructor. Returns a new MObject instance which references the same internal Maya object as src, which must be another MObject instance.

## Object Methods

Signature | Parameters | Returns | Description
--- | --- | --- | ---
hasFn(fn) | fn - MFn type constant | Bool | Returns True if the internal Maya object supports the specified function set specified by fn.
isNull() |  | Bool | Returns True if the MObject is not referring to any Maya internal internal object (i.e. it is equivalent to kNullObj).
apiType() |  | MFn type constant | Returns a constant indicating the type of the internal Maya object. If the MObject is null `MFn.kInvalid` will be returned.

## Object Attributes

Name | Type | Access | Description
--- | --- | --- | ---
apiTypeStr | string | R | The internal Maya object's MFn type as a string. E.g. 'kTime' for a time node.

## Sequence Support

None.

## Number Support

None.

## Comparison Support

== | True if both MObjects refer to the same internal Maya object, False otherwise.
!= | True if the two MObjects refer to different internal Maya objects, or one is null and the other is not. False otherwise.

© 2011 Autodesk, Inc. All rights reserved.