PolygonConstraint Object

Derived from: GeometricConstraint Object
Defined in namespace "adsk::fusion" and the header file is <Fusion/Sketch/PolygonConstraint.h>

Description

A polygon constraint in a sketch.

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().

deleteMe

Deletes this constraint. The IsDeletable property can be used to determine if this constraint can be deleted.

Properties

Name Description
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 geometric constraint.
centerPoint Returns the SketchPoint that acts as the center point of the polygon.
entityToken
isDeletable Indicates if this constraint is deletable.
isValid Indicates if this object is still valid, i.e. hasn't been deleted or some other action done to invalidate the reference.
lines **RETIRED** This has been retired and you should use the points property instead.
objectType Returns a string indicating the type of the object.
parentSketch Returns the parent sketch object.
points Returns the sketch points that define the vertices of the polygon. The sketch lines that draw the shape of the polygon can be obtained from the points.

Accessed From

GeometricConstraints.addPolygon

Version

Introduced in version March 2016