Public Member Functions | Public Attributes | List of all members
Tool Class Reference

Inherits ScriptObject.

Public Member Functions

 Tool ()
 
String getToolId ()
 
Integer getNumber ()
 
Integer getDiameterOffset ()
 
Integer getLengthOffset ()
 
Integer getSecondaryLengthOffset ()
 
Boolean isTurningTool ()
 
Boolean isJetTool ()
 
Integer getHolderNumber ()
 
Integer getSpindleMode ()
 
Number getSpindleRPM ()
 
Number getRampingSpindleRPM ()
 
Boolean isClockwise ()
 
Number getSurfaceSpeed ()
 
Number getMaximumSpindleSpeed ()
 
Integer getNumberOfFlutes ()
 
Number getThreadPitch ()
 
Number getTappingFeedrate ()
 
Boolean isDrill ()
 
Integer getCoolant ()
 
Integer getMaterial ()
 
String getDescription ()
 
String getComment ()
 
String getVendor ()
 
String getProductId ()
 
String getHolderDescription ()
 
String getHolderComment ()
 
String getHolderVendor ()
 
String getHolderProductId ()
 
String getAggregateId ()
 
Integer getUnit ()
 
Integer getType ()
 
Number getDiameter ()
 
Number getTipDiameter ()
 
Number getCornerRadius ()
 
Number getTaperAngle ()
 
Number getFluteLength ()
 
Number getShoulderLength ()
 
Number getShaftDiameter ()
 
Number getBodyLength ()
 
Number getOverallLength ()
 
Shaft getShaft ()
 
Number getJetDistance ()
 
Number getJetDiameter ()
 
Number getKerfWidth ()
 
String getMachineQualityControl ()
 
Number getCutHeight ()
 
Number getPierceHeight ()
 
Number getPressure ()
 
Number getPierceTime ()
 
Number getAbrasiveFlowRate ()
 
Number getPiercePower ()
 
Number getCutPower ()
 
String getAssistGas ()
 
Number getHolderTipDiameter ()
 
Number getHolderDiameter ()
 
Number getHolderLength ()
 
Holder getHolder ()
 
Number getBoringBarOrientation ()
 
Integer getCompensationOffset ()
 
Integer getSecondaryCompensationOffset ()
 
Boolean getManualToolChange ()
 
Boolean getBreakControl ()
 
Boolean isLiveTool ()
 
Integer getTurret ()
 
Integer getInsertType ()
 
Integer getHolderType ()
 
Integer getCompensationMode ()
 
Vector getCompensationDisplacement ()
 
BoundingBox getExtent (Boolean includeHolder)
 
Curve getCutterProfile ()
 
Curve getHolderProfile ()
 
String getCutterProfileAsSVGPath ()
 
String getHolderProfileAsSVGPath ()
 
Mesh getCutterAsMesh (Number tolerance)
 
Mesh getHolderAsMesh (Number tolerance)
 

Public Attributes

Integer number
 The tool number.
 
Integer turret
 The turret.
 
Integer diameterOffset
 The diameter offset (used for milling).
 
Integer lengthOffset
 The length offset (used for milling).
 
Integer compensationOffset
 The compensation offset (used for turning).
 
Boolean manualToolChange
 True if tool must be manually changed.
 
Boolean breakControl
 True if break control is enabled.
 
Boolean liveTool
 True if the tool is live - otherwise it is static.
 
Integer holderNumber
 Number identifying the holder.
 
Integer spindleMode
 The spindle mode.
 
Number spindleRPM
 The spindle speed in RPM. Positive for clockwise direction.
 
Number rampingSpindleRPM
 The spindle speed in RPM for ramping. Positive for clockwise direction.
 
Number surfaceSpeed
 The surface speed (CSS).
 
Number maximumSpindleSpeed
 The maximum spindle speed (RPM) when using surface speed (CSS).
 
Integer numberOfFlutes
 The number of flutes.
 
Number threadPitch
 The number of thread per unit of length.
 
Integer coolant
 The coolant.
 
Integer material
 The material.
 
String comment
 Comment.
 
String vendor
 The vendor.
 
String productId
 The product id.
 
Integer unit
 The unit.
 
Integer type
 The tool type.
 
Number diameter
 The diameter.
 
Number cornerRadius
 The corner radius.
 
Number taperAngle
 The taper angle.
 
Number fluteLength
 The flute length.
 
Number shoulderLength
 The shoulder length.
 
Number shaftDiameter
 The shaft diameter.
 
Number bodyLength
 The body length.
 
Number overallLength
 The entire length of the tool.
 
Shaft shaft
 The tool shaft.
 
Number holderTipDiameter
 The holder tip diameter.
 
Number holderDiameter
 The holder diameter.
 
Number holderLength
 The holder length.
 
Holder holder
 The tool holder.
 
Number boringBarOrientation
 The boring bar orientation in radians.
 
Number inscribedCircleDiameter
 The inscribed circle diameter for turning tool.
 
Number edgeLength
 The edge length for turning tool.
 
Number noseRadius
 The nose radius for turning tools.
 
Number reliefAngle
 The relief angle in degrees.
 
Number thickness
 The turning tool thickness;.
 
Number grooveWidth
 The groove tool width.
 
String crossSection
 The cross section type for turning tools.
 
String tolerance
 The tolerance for turning tools.
 
Number pitch
 The thread pitch for turning tools.
 
String hand
 The holder hand. Left, Right, or Neutral.
 
String clamping
 Clamping for turning tools.
 
Number jetDistance
 The jet distance. More...
 
Number jetDiameter
 The jet diameter.
 
Number kerfWidth
 The kerf width.
 
String machineQualityControl
 The machine quality control.
 
Number cutHeight
 The cut height.
 
Number pierceHeight
 The pierce height.
 
Number pressure
 The pressure.
 
Number pierceTime
 The pierce time.
 
Number abrasiveFlowRate
 The abrasive flow rate.
 
Number piercePower
 The pierce power.
 
Number cutPower
 The cut power.
 
String assistGas
 The assist gas.
 

Detailed Description

A tool specification.

Constructor & Destructor Documentation

◆ Tool()

Tool ( )

Constructs a tool.

Member Function Documentation

◆ getAbrasiveFlowRate()

Number getAbrasiveFlowRate ( )
Returns
The abrasive flow rate for waterjet operations.
Note
Unitless.
Since
XXXXX

◆ getAggregateId()

String getAggregateId ( )

Returns the aggregate id.

◆ getAssistGas()

String getAssistGas ( )
Returns
The name of the assist gas used for laser/plasma operations.
Since
XXXXX

◆ getBodyLength()

Number getBodyLength ( )

Returns the body length.

◆ getBoringBarOrientation()

Number getBoringBarOrientation ( )

Returns the boring bar orientation in radians.

◆ getBreakControl()

Boolean getBreakControl ( )

Returns true if break control is enabled.

◆ getComment()

String getComment ( )

Returns the tool comment.

◆ getCompensationDisplacement()

Vector getCompensationDisplacement ( )

Returns the turning compensation displacement for the toolpath. The Z-coordinate is always 0.

Since
41366

◆ getCompensationMode()

Integer getCompensationMode ( )

Returns the turning compensation mode.

The available modes are:

  • TOOL_COMPENSATION_INSERT_CENTER
  • TOOL_COMPENSATION_TIP
  • TOOL_COMPENSATION_TIP_CENTER
  • TOOL_COMPENSATION_TIP_TANGENT

◆ getCompensationOffset()

Integer getCompensationOffset ( )

Returns the primary compensation offset for turning.

◆ getCoolant()

Integer getCoolant ( )

Returns the coolant mode.

◆ getCornerRadius()

Number getCornerRadius ( )

Returns the corner radius.

◆ getCutHeight()

Number getCutHeight ( )
Returns
The height above the material to cut at for waterjet/laser/plasma operations.
Since
XXXXX

◆ getCutPower()

Number getCutPower ( )
Returns
The power used for cutting the material for laser/plasma operations.
Since
XXXXX

◆ getCutterAsMesh()

Mesh getCutterAsMesh ( Number  tolerance)

Returns the cutter as a mesh.

Parameters
toleranceThe linearization tolerance.
Since
42020
var mesh = tool.getCutterAsMesh(tolerance);
mesh.scale(10);
Mesh.saveMesh("mycutter.stl", "application/sla", mesh);
mesh = tool.getHolderAsMesh(tolerance);
mesh.scale(10);
Mesh.saveMesh("myholder.stl", "application/sla", mesh);

◆ getCutterProfile()

Curve getCutterProfile ( )

Returns the profile of the cutter as a Curve.

Since
41366

◆ getCutterProfileAsSVGPath()

String getCutterProfileAsSVGPath ( )

Returns the SVG profile of the cutter.

Since
41366

◆ getDescription()

String getDescription ( )

Returns the tool description.

◆ getDiameter()

Number getDiameter ( )

Returns the cutter diameter.

◆ getDiameterOffset()

Integer getDiameterOffset ( )

Returns the diameter offset.

◆ getExtent()

BoundingBox getExtent ( Boolean  includeHolder)

Returns the tool extent.

Parameters
includeHolderSet to true to include the extent of the holder.
Since
41366

◆ getFluteLength()

Number getFluteLength ( )

Returns the flute length.

◆ getHolder()

Holder getHolder ( )

Returns the holder.

◆ getHolderAsMesh()

Mesh getHolderAsMesh ( Number  tolerance)

Returns the holder as a mesh.

Parameters
toleranceThe linearization tolerance.
Since
42020

◆ getHolderComment()

String getHolderComment ( )

Returns the holder comment.

◆ getHolderDescription()

String getHolderDescription ( )

Returns the holder description.

◆ getHolderDiameter()

Number getHolderDiameter ( )

Returns the maximum holder diameter.

◆ getHolderLength()

Number getHolderLength ( )

Returns the total holder length.

◆ getHolderNumber()

Integer getHolderNumber ( )

Returns the holder number.

◆ getHolderProductId()

String getHolderProductId ( )

Returns the holder product id.

◆ getHolderProfile()

Curve getHolderProfile ( )

Returns the profile of the holder as a Curve.

Since
41366

◆ getHolderProfileAsSVGPath()

String getHolderProfileAsSVGPath ( )

Returns the SVG profile of the holder.

Since
41366

◆ getHolderTipDiameter()

Number getHolderTipDiameter ( )

Returns the tip diameter of the holder.

◆ getHolderType()

Integer getHolderType ( )

Returns the turning holder type.

The available types are:

  • HOLDER_NONE
  • HOLDER_ISO_A
  • HOLDER_ISO_B
  • HOLDER_ISO_C
  • HOLDER_ISO_D
  • HOLDER_ISO_E
  • HOLDER_ISO_F
  • HOLDER_ISO_G
  • HOLDER_ISO_H
  • HOLDER_ISO_J
  • HOLDER_ISO_K
  • HOLDER_ISO_L
  • HOLDER_ISO_M
  • HOLDER_ISO_N
  • HOLDER_ISO_P
  • HOLDER_ISO_Q
  • HOLDER_ISO_R
  • HOLDER_ISO_S
  • HOLDER_ISO_T
  • HOLDER_ISO_U
  • HOLDER_ISO_V
  • HOLDER_ISO_W
  • HOLDER_ISO_Y
  • HOLDER_OFFSET_PROFILE
  • HOLDER_STRAIGHT_PROFILE
  • HOLDER_GROOVE_EXTERNAL
  • HOLDER_GROOVE_INTERNAL
  • HOLDER_GROOVE_FACE
  • HOLDER_THREAD_STRAIGHT
  • HOLDER_THREAD_OFFSET
  • HOLDER_THREAD_FACE
  • HOLDER_BORING_BAR_ISO_F 0 deg end clearance
  • HOLDER_BORING_BAR_ISO_G 0 deg side clearance
  • HOLDER_BORING_BAR_ISO_J -3 deg side
  • HOLDER_BORING_BAR_ISO_K 15 deg end clearance
  • HOLDER_BORING_BAR_ISO_L -5 deg side clearance
  • HOLDER_BORING_BAR_ISO_P -27.5 deg end clearance
  • HOLDER_BORING_BAR_ISO_Q 17.5 deg end clearance
  • HOLDER_BORING_BAR_ISO_S 45 deg end
  • HOLDER_BORING_BAR_ISO_U -3 deg end clearance
  • HOLDER_BORING_BAR_ISO_W -30 deg end
  • HOLDER_BORING_BAR_ISO_Y 5 deg end
  • HOLDER_BORING_BAR_ISO_X 5 deg back boring

◆ getHolderVendor()

String getHolderVendor ( )

Returns the holder vendor.

◆ getInsertType()

Integer getInsertType ( )

Returns the turning insert type.

The available types are:

  • TURNING_INSERT_USER_DEFINED
  • TURNING_INSERT_ISO_A - 85deg parallelogram - 85deg
  • TURNING_INSERT_ISO_B - 82deg parallelogram - 82deg
  • TURNING_INSERT_ISO_C - 80deg diamond - 80deg
  • TURNING_INSERT_ISO_D - 55deg diamond - 55deg
  • TURNING_INSERT_ISO_E - 75deg diamond - 75deg
  • TURNING_INSERT_ISO_H - hexagon - 120deg
  • TURNING_INSERT_ISO_K - 55deg parallelogram - 55deg
  • TURNING_INSERT_ISO_L - rectangle - 90deg
  • TURNING_INSERT_ISO_M - 86deg diamond - 86deg
  • TURNING_INSERT_ISO_O - octagon - 135deg
  • TURNING_INSERT_ISO_P - pentagon - 108deg
  • TURNING_INSERT_ISO_R - round - full radius
  • TURNING_INSERT_ISO_S - square - 90deg
  • TURNING_INSERT_ISO_T - triangle - 60deg
  • TURNING_INSERT_ISO_V - 35deg diamond - 35deg
  • TURNING_INSERT_ISO_W - trigon - 80deg
  • TURNING_INSERT_GROOVE_ROUND
  • TURNING_INSERT_GROOVE_RADIUS
  • TURNING_INSERT_GROOVE_SQUARE
  • TURNING_INSERT_GROOVE_CHAMFER
  • TURNING_INSERT_GROOVE_40DEG
  • TURNING_INSERT_THREAD_ISO_DOUBLE_FULL
  • TURNING_INSERT_THREAD_ISO_TRIPLE_FULL
  • TURNING_INSERT_THREAD_UTS_DOUBLE_FULL
  • TURNING_INSERT_THREAD_UTS_TRIPLE_FULL
  • TURNING_INSERT_THREAD_ISO_DOUBLE_VPROFILE
  • TURNING_INSERT_THREAD_ISO_TRIPLE_VPROFILE
  • TURNING_INSERT_THREAD_UTS_DOUBLE_VPROFILE
  • TURNING_INSERT_THREAD_UTS_TRIPLE_VPROFILE

◆ getJetDiameter()

Number getJetDiameter ( )
Returns
The waterjet/laser/plasma nozzle diameter.
Since
XXXXX

◆ getJetDistance()

Number getJetDistance ( )

Deprecated (not used).

Deprecated:
XXXXX

◆ getKerfWidth()

Number getKerfWidth ( )
Returns
The waterjet/laser/plasma kerf width.
Since
XXXXX

◆ getLengthOffset()

Integer getLengthOffset ( )

Returns the length offset.

◆ getMachineQualityControl()

String getMachineQualityControl ( )

When set to "manual" the programmed feedrates will be used, "automatic" will disable feedrate output and the machine control will handle the feedrates of the toolpaths. The post processor must support this setting for "automatic " to have any effect on the output.

Since
XXXXX

◆ getManualToolChange()

Boolean getManualToolChange ( )

Returns true if the tool must be manually changed.

◆ getMaterial()

Integer getMaterial ( )

Returns the material.

◆ getMaximumSpindleSpeed()

Number getMaximumSpindleSpeed ( )

Returns the maximum spindle speed (RPM) when using surface speed (CSS).

◆ getNumber()

Integer getNumber ( )

Returns the tool number.

◆ getNumberOfFlutes()

Integer getNumberOfFlutes ( )

Returns the number of flutes.

◆ getOverallLength()

Number getOverallLength ( )

Returns the entire length of the tool.

Since
45845

◆ getPierceHeight()

Number getPierceHeight ( )
Returns
The height above the material to pierce the material for laser/plasma operations.
Since
XXXXX

◆ getPiercePower()

Number getPiercePower ( )
Returns
The power used for piercing the material for laser/plasma operations.
Since
XXXXX

◆ getPierceTime()

Number getPierceTime ( )
Returns
The amount of time used to pierce the material for waterjet/laser/plasma operations
Since
XXXXX

◆ getPressure()

Number getPressure ( )
Returns
The water pressure for waterjet operations and gas pressure for laser/plasme operations.
Note
PSI if tool units are IN, BAR if tool units are MM.
Since
XXXXX

◆ getProductId()

String getProductId ( )

Returns the tool product id.

◆ getRampingSpindleRPM()

Number getRampingSpindleRPM ( )

Returns the ramping spindle speed in RPM (rotations per minute).

◆ getSecondaryCompensationOffset()

Integer getSecondaryCompensationOffset ( )

Returns the secondary compensation offset for turning.

◆ getSecondaryLengthOffset()

Integer getSecondaryLengthOffset ( )

Returns the secondary length offset.

◆ getShaft()

Shaft getShaft ( )

Returns the shaft.

◆ getShaftDiameter()

Number getShaftDiameter ( )

Returns the shaft diameter.

◆ getShoulderLength()

Number getShoulderLength ( )

Returns the shoulder length.

◆ getSpindleMode()

Integer getSpindleMode ( )

Returns the spindle mode.

The available modes are:

  • SPINDLE_CONSTANT_SPINDLE_SPEED
  • SPINDLE_CONSTANT_SURFACE_SPEED

◆ getSpindleRPM()

Number getSpindleRPM ( )

Returns the spindle speed in RPM (rotations per minute).

◆ getSurfaceSpeed()

Number getSurfaceSpeed ( )

Returns the surface speed (CSS).

◆ getTaperAngle()

Number getTaperAngle ( )

Returns the taper angle in radians.

◆ getTappingFeedrate()

Number getTappingFeedrate ( )

Returns the tapping feedrate as spindle RPM * thread pitch.

◆ getThreadPitch()

Number getThreadPitch ( )

Returns the number of threads per unit of length.

◆ getTipDiameter()

Number getTipDiameter ( )

Returns the tip diameter.

◆ getToolId()

String getToolId ( )

Returns the tool id.

Note: it is an internal (unique) id of the tool in a Fusion/Inventor document. For instance, when adding/creating a tool (not exist) in the document, a new id is created for the tool, which is added into the document's tool library.

◆ getTurret()

Integer getTurret ( )

Returns the turret for turning.

◆ getType()

Integer getType ( )

Returns the tool type.

The types are:

  • TOOL_UNSPECIFIED - Unspecified tool.
  • TOOL_DRILL - Drill.
  • TOOL_DRILL_CENTER - Center drill.
  • TOOL_DRILL_SPOT - Spot drill.
  • TOOL_DRILL_BLOCK - Block drill.
  • TOOL_MILLING_END_FLAT - Flat end-mill.
  • TOOL_MILLING_END_BALL - Ball end-mill.
  • TOOL_MILLING_END_BULLNOSE - Bullnose mill.
  • TOOL_MILLING_CHAMFER - Chamfer mill.
  • TOOL_MILLING_FACE - Face mill.
  • TOOL_MILLING_SLOT - Slot mill.
  • TOOL_MILLING_RADIUS - Radius mill.
  • TOOL_MILLING_DOVETAIL - Dovetail mill.
  • TOOL_MILLING_TAPERED - Tapered mill.
  • TOOL_MILLING_LOLLIPOP - Lollipop mill.
  • TOOL_TAP_RIGHT_HAND - Right tap tool.
  • TOOL_TAP_LEFT_HAND - Left tap tool.
  • TOOL_REAMER - Reamer tool.
  • TOOL_BORING_BAR - Boring bar tool.
  • TOOL_COUNTER_BORE - Counterbore tool.
  • TOOL_COUNTER_SINK - Countersink tool.
  • TOOL_HOLDER_ONLY - Holder.
  • TOOL_TURNING_GENERAL - General turning tool.
  • TOOL_TURNING_THREADING - Thread turning tool.
  • TOOL_TURNING_GROOVING - Groove turning tool.
  • TOOL_TURNING_BORING - Boring turning tool.
  • TOOL_TURNING_CUSTOM - Custom turning tool.
  • TOOL_PROBE - Probe.
  • TOOL_WIRE - Wire.
  • TOOL_WATER_JET - Water jet.
  • TOOL_LASER_CUTTER - Laser cutter.
  • TOOL_WELDER - Welder.
  • TOOL_GRINDER - Grinder.
  • TOOL_MILLING_FORM - Form mill.
  • TOOL_PLASMA_CUTTER - Plasma cutter.
  • TOOL_MARKER - Marker tool.
  • TOOL_MILLING_THREAD - Thread mill.

◆ getUnit()

Integer getUnit ( )

Returns the tool unit.

The available values are:

  • IN - Inches
  • MM - Millimeters

◆ getVendor()

String getVendor ( )

Returns the tool vendor.

◆ isClockwise()

Boolean isClockwise ( )

Returns true if the spindle rotates in clockwise direction.

◆ isDrill()

Boolean isDrill ( )

Returns true if the tool is a drill.

◆ isJetTool()

Boolean isJetTool ( )

Returns true if the tool is a jet tool.

◆ isLiveTool()

Boolean isLiveTool ( )

Returns true if the tool is live. Otherwise tool is static (ie. mounted without a spindle).

Since
41222

◆ isTurningTool()

Boolean isTurningTool ( )

Returns true if the tool is a turning tool.

Member Data Documentation

◆ jetDistance

Number jetDistance

The jet distance.

Deprecated:


Generated by Autodesk, Inc. 19 April 2024
Copyright (c) 2012-2024 by Autodesk, Inc.