Public Member Functions | Public Attributes

MLSolidWorksDimension Class Reference

MLSolidWorksDimension implements the IDimension interface of SolidWorks. More...

#include <+SolidWorks/MLSolidWorksDimension.h>

Inheritance diagram for MLSolidWorksDimension:
Inheritance graph
[legend]
Collaboration diagram for MLSolidWorksDimension:
Collaboration graph
[legend]

List of all members.

Public Member Functions

function MLSolidWorksDimension (in rawISketchMgrPointer)
 Class constructor.
function GetDimensionValue (in obj)
 Gets the dimensional value of the dimension.
function SetDimensionValue (in obj, in dimValue)
 Sets the dimensional value of the dimension.
function GetArcEndCondition (in obj, in endPointIndex)
 Gets the end conditions for linear dimensions that end on an arc.
function GetFeatureOwner (in obj)
 Gets the parent feature associated with this dimension.
function GetNameForSelection (in obj)
 Gets the name of the selected dimension needed by IModelDoc.SelectType.
function GetReferencePointsCount (in obj)
 Gets the reference points count of the selected dimension needed by CADLab.SolidWorks.IModelDoc.SelectType method.
function GetType (in obj)
 Gets the type of dimension.
function GetReferencePoints (in obj, in PointsCount)
 Gets the reference points for this dimension.

Public Attributes

 FullName
 Gets the full name of a dimension including the feature and the model.
 DimensionTolerance
 Gets the MLSolidWorksDimensionTolerance object associated with this dimension.
 DimensionLineDirection
 Get or set the Direction Vector of the Dimension.
 DrivenState
 Get or set the Driven State of the dimension.
 ExtensionLineDirection
 Gets or sets the direction of the extension line of the dimension.
 Name
 Gets or sets the name of a dimension.
 ReadOnly
 Gets or sets the read-only state of a dimension.
 ReferencePoints
 Gets or sets the reference points for this dimension.
 m_CADRawPointer

Detailed Description

MLSolidWorksDimension implements the IDimension interface of SolidWorks.

The MLSolidWorksDimension class allows you to get and set dimension values and tolerances.

For more information please refer to the SolidWorks API documentation.


Constructor & Destructor Documentation

function MLSolidWorksDimension ( in  rawISketchMgrPointer )

Class constructor.

Parameters:
rawISketchMgrPointeris the COM pointer to the dimension object.

Member Function Documentation

function GetArcEndCondition ( in  obj,
in  endPointIndex 
)

Gets the end conditions for linear dimensions that end on an arc.

Parameters:
objis the instance if the object calling and is implicit.
endPointIndexis the endpoint to get the end condition from; 1 is the first endpoint, 2 is the second endpoint.
Return values:
swArcEndCondition_eis the end condition as defined in CADLab.SolidWorks.MLSWConst.swArcEndCondition.

EXAMPLE: swArcEndCondition_e = thisObj.GetArcEndCondition(1);

function GetDimensionValue ( in  obj )

Gets the dimensional value of the dimension.

Parameters:
objis the instance if the object calling and is implicit.
Return values:
dimValueis a scalar number representing the value of the dimension.

EXAMPLE: dim = this.GetDimensionValue();

function GetFeatureOwner ( in  obj )

Gets the parent feature associated with this dimension.

Parameters:
objis the instance if the object calling and is implicit.
Return values:
IMLSWFeatureis the CADLab.SolidWorks.MLSolidWorksFeature object.

EXAMPLE: IMLSWFeature = thisObj.GetFeatureOwner()

function GetNameForSelection ( in  obj )

Gets the name of the selected dimension needed by IModelDoc.SelectType.

Parameters:
objis the instance if the object calling and is implicit.
Return values:
nameis a string value.

EXAMPLE: naam = thisObj.GetNameForSelection();

function GetReferencePoints ( in  obj,
in  PointsCount 
)

Gets the reference points for this dimension.

Parameters:
objis the instance if the object calling and is implicit.
PointsCountis the number of reference points for this dimension. It is a scalar value.
Return values:
refPointXYZis a 1x3 vector representing the co-ordinates of the reference point.

EXAMPLE: [X Y Z] = thisObj.GetReferencePoints(2);

function GetReferencePointsCount ( in  obj )

Gets the reference points count of the selected dimension needed by CADLab.SolidWorks.IModelDoc.SelectType method.

Parameters:
objis the instance if the object calling and is implicit.
Return values:
refCountis an integer value.

EXAMPLE: refCount = thisObj.GetReferencePointsCount();

function GetType ( in  obj )

Gets the type of dimension.

Parameters:
objis the instance if the object calling and is implicit.
Return values:
swDimensionParamType_eis the enum defined in CADLab.SolidWorks.MLSWConst.swDimensionParamType.

EXAMPLE: swDimensionParamType_e = thisObj.GetType();

function SetDimensionValue ( in  obj,
in  dimValue 
)

Sets the dimensional value of the dimension.

Parameters:
objis the instance if the object calling and is implicit.
dimValueis a scalar value of the dimension.

EXAMPLE: this.GetDimensionValue(5.3);


Member Data Documentation

Get or set the Direction Vector of the Dimension.

The value is a 1x3 vector.

EXAMPLE: dimLineVector = thisObj.DimensionLineDirection; thisObj.DimensionLineDirection = [1 1 1];

Gets the MLSolidWorksDimensionTolerance object associated with this dimension.

This is a read-only property.

EXAMPLE: iMLSWDimTol = thisObj.DimensionTolerance;

Get or set the Driven State of the dimension.

The value is specified by the enum CADLab.SolidWorks.MLSWConst.swDimensionDrivenState.

EXAMPLE: retVal = thisObj.DrivenState; thisObj.DrivenState = CADLab.SolidWorks.MLSWConst.swDimensionDrivenState.swDimensionDriving;

Gets or sets the direction of the extension line of the dimension.

The value is a 1x3 vector.

EXAMPLE: dirVector = thisObj.ExtensionLineDirection; thisObj.ExtensionLineDirection = [1 1 1];

Gets the full name of a dimension including the feature and the model.

This is a read-only property.

EXAMPLE: naam = thisObj.FullName;

m_CADRawPointer [inherited]

Gets or sets the name of a dimension.

The value is a string.

EXAMPLE: naam = thisObj.Name; thisObj.Name = "MyDim";

Gets or sets the read-only state of a dimension.

The value is a boolean.

EXAMPLE: onlyRead = thisObj.ReadOnly thisObj.isReadOnly = false;

Gets or sets the reference points for this dimension.

The value is a 1x3 vector that contains the X, Y and Z coordinates.

EXAMPLE: [X Y Z] = thisObj.ReferencePoints; thisObj.ReferencePoints = [1 1 1];


The documentation for this class was generated from the following file: