Joint Object

Derived from: Base Object
Defined in namespace "adsk::fusion" and the header file is <Fusion/Components/Joint.h>

Description

A joint in a design.

Methods

Name Description
classType Static function that all classes support that returns the type of the class as a string. The returned string matches the string returned by the objectType property. For example if you have a reference to an object and you want to check if it's a SketchLine you can use myObject.objectType == fusion.SketchLine.classType().
createForAssemblyContext Creates or returns a proxy for the native object - i.e. a new object that represents this object but adds the assembly context defined by the input occurrence.
deleteMe Deletes this joint.
setAsBallJointMotion Redefines the relationship between the two joint geometries as a ball joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsCylindricalJointMotion Redefines the relationship between the two joint geometries as a cylindrical joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsPinSlotJointMotion Redefines the relationship between the two joint geometries as a pin-slot joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsPlanarJointMotion Redefines the relationship between the two joint geometries as a planar joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsRevoluteJointMotion Redefines the relationship between the two joint geometries as a revolute joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsRigidJointMotion Redefines the relationship between the two joint geometries as a rigid joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
setAsSliderJointMotion Redefines the relationship between the two joint geometries as a slider joint.

To use this method, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)

Properties

Name Description
angle Returns the parameter controlling the angle between the two input geometries. This is effectively the angle between the two primary axes of the two joint geometries.
assemblyContext Returns the assembly occurrence (i.e. the occurrence) of this object in an assembly. This is only valid in the case where this is acting as a proxy in an assembly. Returns null in the case where the object is not in the context of an assembly but is already the native object.
attributes Returns the collection of attributes associated with this joint.
entityToken Returns a token for the Joint object. This can be saved and used at a later time with the Design.findEntityByToken method to get back the same joint.

When using entity tokens it's important to understand that the token string returned for a specific entity can be different over time. However, even if you have two different token strings that were obtained from the same entity, when you use findEntityByToken they will both return the same entity. Because of that you should never compare entity tokens as way to determine what the token represents. Instead, you need to use the findEntityByToken method to get the two entities identified by the tokens and then compare them.
errorOrWarningMessage Returns the error or warning message in the case where the healthState property returns either WarningFeatureHealthState or ErrorFeatureHealthState. Otherwise this property returns an empty string.
geometryOrOriginOne Gets and sets the first JointGeometry or JointOrigin for this joint.

To set this property, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
geometryOrOriginTwo Gets and sets the second JointGeometry or JointOrigin for this joint.

To set this property, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
healthState Returns the current health state of the joint.
isFlipped Gets and sets if the joint direction is flipped or not. This is effectively specifying if the third axis of the two input geometries is facing (false) or opposed (true).

To set this property, you need to position the timeline marker to immediately before this joint. This can be accomplished using the following code: thisJoint.timelineObject.rollTo(True)
isLightBulbOn Gets and sets if the light bulb of this joint as displayed in the browser is on or off. A joint will only be visible if the light bulb is switched on. However, the light bulb can be on and the joint still invisible if a higher level occurrence in the assembly context is not visible because its light bulb is off or the joints folder is light bulb is off.
isLocked Gets and sets if the joint is locked.
isSuppressed Gets and sets if this joint is suppressed.
isValid Indicates if this object is still valid, i.e. hasn't been deleted or some other action done to invalidate the reference.
isVisible Gets whether the joint is visible. To change the visibility see the isLightBulbOn property. This property is affected by the assembly context.
jointMotion Returns a JointMotion object that defines the motion relationship between the two geometries.
name Gets and sets the name of the joint.
nativeObject The NativeObject is the object outside the context of an assembly and in the context of it's parent component. Returns null in the case where this object is not in the context of an assembly but is already the native object.
objectType This property is supported by all objects in the API and returns a string that contains the full name (namespace::objecttype) describing the type of the object.

It's often useful to use this in combination with the classType method to see if an object is a certain type. For example: if obj.objectType == adsk.core.Point3D.classType():
occurrenceOne Returns the first of two occurrences that this joint defines a relationship between. This is the occurrence that can also be found through the geometryOrOriginOne property.
occurrenceTwo Returns the first of two occurrences that this joint defines a relationship between. This is the occurrence that can also be found through the geometryOrOriginTwo property.
offset Returns the parameter controlling the offset between the two input geometries. This is effectively the offset distance between the two planes defined by the primary and secondary axes of the input geometries or the offset along the tertiary axis (z axis) of the joint.
offsetX Returns the parameter controlling the offset along the primary axis (x axis) of the joint. To edit this value, get the parameter and use one of its properties to edit the value.
offsetY Returns the parameter controlling the offset along the primary axis (y axis) of the joint. To edit this value, get the parameter and use one of its properties to edit the value.
parentComponent Returns the parent component that owns this joint.
timelineObject Returns the timeline object associated with this joint.

Accessed From

Component.allJoints, FlatPatternComponent.allJoints, Joint.createForAssemblyContext, Joint.nativeObject, JointList.item, JointList.itemByName, Joints.add, Joints.item, Joints.itemByName

Samples

Name Description
BallJointMotion API Sample Demonstrates creating a joint with ball joint motion
CylindricalJointMotion API Sample Demonstrates creating a joint with cylindrical joint motion.
Joint API Sample Demonstrates creating a new joint.
Pin Slot Joint Motion API Sample Demonstrates creating a joint with pin slot joint motion
Planar Joint Motion API Sample Demonstrates creating a joint with planar joint motion
RevoluteJointMotion API Sample Demonstrates creating a joint with revolute joint motion.
SliderJointMotion API Sample Demonstrates creating a joint with slider joint motion.

Version

Introduced in version July 2015