API Documentation > Interfaces > Interface WDimension
Interface WDimension
Description
Extends the functionality of Dimension
This is the actual type of Dimension Items in Object Toolkit.
Methods Inherited from Interface com.ptc.wfc.wfcLayerState.LayerItem :
Methods Inherited from Interface com.ptc.pfc.pfcBase.ActionSource :
Methods Inherited from Interface com.ptc.pfc.pfcObject.Parent :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.ParameterOwner :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WParameterOwner :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.RelationOwner :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WRelationOwner :
Methods Inherited from Interface com.ptc.pfc.pfcObject.Child :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.ModelItem :
Methods Inherited from Interface com.ptc.wfc.wfcModelItem.WModelItem :
Methods Inherited from Interface com.ptc.wfc.wfcAnnotation.Annotation :
Methods Inherited from Interface com.ptc.pfc.pfcModelItem.BaseParameter :
Methods Inherited from Interface com.ptc.pfc.pfcDimension.BaseDimension :
Methods Inherited from Interface com.ptc.pfc.pfcDimension.Dimension :
Method Summary
void
Add dimension references.
boolean
CanRegenerate ( /*optional*/ Drawing Drw)
/*optional*/ AnnotationElement
LICENSE: 222
void
CreateJog (Point3Ds JogPoints, int WitnessLineIndex, /*optional*/ Drawing Drawing)
LICENSE: 222
void
CreateSimpleBreak (Point3D BreakStart, Point3D BreakEnd, int WitnessLineIndex, /*optional*/ Drawing Drawing)
LICENSE: 222
void
LICENSE: 222
void
Delete dimension reference.
void
LICENSE: 222
void
DisplayValueAsRounded (boolean Value)
void
EraseWitnessLine (int WitnessLineIndex, /*optional*/ Drawing Drawing)
Get dimension references.
LICENSE: 222
/*optional*/ Dimension
LICENSE: 222
GetChamferLeaderStyle ( /*optional*/ Drawing Drw)
/*optional*/ DimChamferStyle
GetChamferStyle ( /*optional*/ Drawing Drawing)
LICENSE: 222
GetConfiguration ( /*optional*/ Drawing Drw)
Obtains the dimension configuration.
/*optional*/ Integer
GetDenominator (boolean Tolerance)
LICENSE: 222
LICENSE: 222
GetDimLocation ( /*optional*/ Drawing Drawing, /*optional*/ View View)
/*optional*/ Double
/*optional*/ Double
double
Get display format of dimension.
GetDualOptions ( /*optional*/ Drawing Drw)
Gets the dual dimension display options.
GetEnvelope ( /*optional*/ Drawing Drawing, int Line)
Get the envelope of a line in a specified dimension. For getting coordinates of dimension displayed in solid and same dimension is displayed in drawing then drawing should not be active.
GetFirstDimArrowType ( /*optional*/ Drawing Drawing, /*optional*/ View View)
LICENSE: 222
Returns the arrow type used for first dimension arrow.
double
LICENSE: 222
LICENSE: 222
/*optional*/ Integer
Identify if dimension has an origin side
/*optional*/ Double
/*optional*/ Feature
/*optional*/ Dimension
Retrieves the parent dimension of the value dependent dimension.
/*optional*/ String
/*optional*/ LeaderArrowType
GetSecondDimArrowType ( /*optional*/ Drawing Drawing, /*optional*/ View View)
LICENSE: 222
Returns the arrow type used for second dimension arrow.
/*optional*/ Integer
GetSignificantDigits (boolean Tolerance)
/*optional*/ String
boolean
boolean
LICENSE: 222
boolean
boolean
boolean
LICENSE: 222
boolean
boolean
boolean
LICENSE: 222
boolean
Identifies if the dimension always uses a true sign.
boolean
void
LICENSE: 222
void
Move (Point3D Location)
LICENSE: 222
void
LICENSE: 222
void
LICENSE: 222
void
SetAsBasic (boolean Basic)
void
SetAsInspection (boolean Inspection)
void
SetBound (Model Model, DimBound DimBound)
void
SetChamferLeaderStyle (DimChamferLeaderStyle ChamferLeaderStyle, /*optional*/ Drawing Drw)
void
SetChamferStyle (DimChamferStyle ChamferStyle, /*optional*/ Drawing Drawing)
LICENSE: 222
void
SetConfiguration (DimLeaderConfig Config, /*optional*/ Drawing Drw)
Assigns the dimension configuration.
void
SetDenominator (int Denominator, boolean Tolerance)
void
SetDimensionArrowType (int ArrowIndex, LeaderArrowType ArrowType, /*optional*/ Drawing Drawing)
void
LICENSE: 222
void
void
Set display format of dimension.
void
Sets the dual dimension display using specified options.
void
SetElbowLength (double ElbowLength, /*optional*/ Drawing Drw)
void
LICENSE: 222
void
LICENSE: 222
void
SetOriginSide (int WitnessLineIndex)
Sets origin side to dimension.
void
SetOverrideValue (double Value)
void
SetPrefix (String Prefix)
void
SetSignificantDigits (int Digits, boolean Tolerance)
void
SetSuffix (String Suffix)
void
ShowWitnessLine ( /*optional*/ Drawing Drawing)
Method Detail
GetNominalValue
double
GetNominalValue
()
User Guide References:
Returns:
SetBound
void
SetBound
(Model Model, DimBound DimBound)
Exceptions thrown (but not limited to):
XToolkitCantModify- The dimension's owner model or the TableModel are read-only.
XToolkitBadContext- cannot set bound for this dimension.
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
Model
DimBound
Returns:
GetBound
GetBound
()
User Guide References:
Returns:
GetSymbolModeText
GetSymbolModeText
()
User Guide References:
Returns:
IsFractional
boolean
IsFractional
()
User Guide References:
Returns:
GetSignificantDigits
/*optional*/ Integer
GetSignificantDigits
(boolean Tolerance)
Exceptions thrown (but not limited to):
XToolkitNotFound- The number of decimals is driven by the number of decimals for the dimension.
XToolkitBadContext- The dimension is fractional.
User Guide References:
Parameters:
Tolerance
Returns:
SetSignificantDigits
void
SetSignificantDigits
(int Digits, boolean Tolerance)
Exceptions thrown (but not limited to):
XToolkitBadContext- The dimension is fractional, so this value cannot be set.
XToolkitNotValid- The input "decimals" argument is out-of-range .
User Guide References:
Parameters:
Digits
Tolerance
Returns:
GetDenominator
/*optional*/ Integer
GetDenominator
(boolean Tolerance)
Exceptions thrown (but not limited to):
XToolkitNotFound- The denominator is driven by the denominator for the dimension.
XToolkitBadContext- The dimension is not fractional.
User Guide References:
Parameters:
Tolerance
Returns:
SetDenominator
void
SetDenominator
(int Denominator, boolean Tolerance)
Exceptions thrown (but not limited to):
XToolkitBadContext- The dimension is not fractional.
User Guide References:
Parameters:
Denominator
Tolerance
Returns:
CanRegenerate
boolean
CanRegenerate
( /*optional*/ Drawing Drw)
User Guide References:
Parameters:
Drw
Returns:
GetPrefix
/*optional*/ String
GetPrefix
()
Exceptions thrown (but not limited to):
XToolkitInvalidType- The dimension type is invalid.
XToolkitNotFound- The dimension or prefix is not found.
User Guide References:
Returns:
SetPrefix
void
SetPrefix
(String Prefix)
Exceptions thrown (but not limited to):
XToolkitInvalidType- The dimension type is invalid.
XToolkitNotFound- The dimension isn't found.
XToolkitCantModify- The dimension isn't modifiable.
User Guide References:
Parameters:
Prefix
Returns:
GetSuffix
/*optional*/ String
GetSuffix
()
Exceptions thrown (but not limited to):
XToolkitInvalidType- The dimension type is invalid.
XToolkitNotFound- The dimension or suffix is not found.
User Guide References:
Returns:
SetSuffix
void
SetSuffix
(String Suffix)
Exceptions thrown (but not limited to):
XToolkitInvalidType- The dimension type is invalid.
XToolkitNotFound- The dimension isn't found.
XToolkitCantModify- The dimension isn't modifiable.
User Guide References:
Parameters:
Suffix
Returns:
IsToleranceDisplayed
boolean
IsToleranceDisplayed
()
User Guide References:
Returns:
IsBasic
boolean
IsBasic
()
User Guide References:
Returns:
IsInspection
boolean
IsInspection
()
User Guide References:
Returns:
SetAsInspection
void
SetAsInspection
(boolean Inspection)
Exceptions thrown (but not limited to):
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
Inspection
Returns:
SetAsBasic
void
SetAsBasic
(boolean Basic)
Exceptions thrown (but not limited to):
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
Basic
Returns:
GetOwnerFeature
/*optional*/ Feature
GetOwnerFeature
()
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension is not owned by a particular feature.
User Guide References:
Returns:
GetDisplayedValue
double
GetDisplayedValue
()
Exceptions thrown (but not limited to):
XToolkitAmbiguous- The displayed format is not decimal
User Guide References:
Returns:
GetDisplayedUpperLimitTolerance
/*optional*/ Double
GetDisplayedUpperLimitTolerance
()
Exceptions thrown (but not limited to):
XToolkitAmbiguous- The displayed format is not decimal
User Guide References:
Returns:
GetDisplayedLowerLimitTolerance
/*optional*/ Double
GetDisplayedLowerLimitTolerance
()
Exceptions thrown (but not limited to):
XToolkitAmbiguous- The displayed format is not decimal
User Guide References:
Returns:
DisplayValueAsRounded
void
DisplayValueAsRounded
(boolean Value)
Exceptions thrown (but not limited to):
XToolkitNoChange- The input attribute is the same as an existing one
XToolkitCantModify- Modification of the attribute is not allowed
User Guide References:
Parameters:
Value
Returns:
IsDisplayedValueRounded
boolean
IsDisplayedValueRounded
()
Exceptions thrown (but not limited to):
XToolkitBadContext- Option is set, but the display is not decimal
User Guide References:
Returns:
GetOverrideValue
/*optional*/ Double
GetOverrideValue
()
Exceptions thrown (but not limited to):
XToolkitNotFound- The override value is not set.
User Guide References:
Returns:
SetOverrideValue
void
SetOverrideValue
(double Value)
User Guide References:
Parameters:
Value
Returns:
GetDisplayedValueType
GetDisplayedValueType
()
User Guide References:
Returns:
SetDisplayedValueType
void
SetDisplayedValueType
(DimValueDisplay DisplayValueType)
User Guide References:
Parameters:
DisplayValueType
Returns:
SetElbowLength
void
SetElbowLength
(double ElbowLength, /*optional*/ Drawing Drw)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension is not a chamfer dimension.
User Guide References:
Parameters:
ElbowLength
Drw
Returns:
GetChamferLeaderStyle
/*optional*/ DimChamferLeaderStyle
GetChamferLeaderStyle
( /*optional*/ Drawing Drw)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension is not a chamfer dimension.
User Guide References:
Parameters:
Drw
Returns:
SetChamferLeaderStyle
void
SetChamferLeaderStyle
(DimChamferLeaderStyle ChamferLeaderStyle, /*optional*/ Drawing Drw)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension style is not chamfer.
User Guide References:
Parameters:
ChamferLeaderStyle
Drw
Returns:
GetConfiguration
GetConfiguration
( /*optional*/ Drawing Drw)
Obtains the dimension configuration.
Exceptions thrown (but not limited to):
XToolkitNotFound- Dimension not found.
User Guide References:
Parameters:
Drw
Optional - The Drawing if dimension belongs to a drawing.
Returns:
wfcDimLeaderConfig - Dimension leader configuration
SetConfiguration
void
SetConfiguration
(DimLeaderConfig Config, /*optional*/ Drawing Drw)
Assigns the dimension configuration.
User Guide References:
Parameters:
Config
Dimension leader configuration to assign.
Drw
Optional - The Drawing if dimension belongs to a drawing.
Returns:
IsSignDriven
boolean
IsSignDriven
()
Identifies if the dimension always uses a true sign.
Note:for dimensions which use the sign to flip the direction, this behavior can be overridden by setting the config option 'show_dim_sign' to 'yes'. By default it is set to 'no'.
User Guide References:
Returns:
xbool - boolean indicating if dimension is sign driven or not.
CreateSimpleBreak
void
CreateSimpleBreak
(Point3D BreakStart, Point3D BreakEnd, int WitnessLineIndex, /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitCantModify- The object or cosmetic model can't be modified.
XToolkitInvalidItem- The dimension is not valid.
XToolkitInvalidType- The dimension can't have a witness line break.
XToolkitAbort- The dimension witness line couldn't be broken.
User Guide References:
Parameters:
BreakStart
BreakEnd
WitnessLineIndex
Drawing
Returns:
CreateJog
void
CreateJog
(Point3Ds JogPoints, int WitnessLineIndex, /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitCantModify- The object or cosmetic model can't be modified.
XToolkitInvalidItem- The dimension is not valid for this operation.
XToolkitInvalidType- The dimension can't have a witness line jog.
XToolkitAbort- The dimension witness line couldn't be jogged.
User Guide References:
Parameters:
JogPoints
WitnessLineIndex
Drawing
Returns:
GetDimLocation
GetDimLocation
( /*optional*/ Drawing Drawing, /*optional*/ View View)
Exceptions thrown (but not limited to):
XToolkitNotDisplayed- The function succeeded, but only after internally selecting a default orientation where one was not supplied, for a dimension which could have different locations given different views. This error can only occur if both drawing and view are NULL.
XToolkitNotFound- This dimension is not displayable.
XToolkitNotValid- A drawing view was passed with a drawing.
Parameters:
Drawing
View
Returns:
GetFirstDimArrowType
GetFirstDimArrowType
( /*optional*/ Drawing Drawing, /*optional*/ View View)
Returns the arrow type used for first dimension arrow.
Parameters:
Drawing
The drawing handle. Passnullif not using a drawing.
View
The orientation of the model that will be applied before determining the arrow type. Pass nullto use the current model view, if the model is current, or a default model orientation otherwise. Pass nullif using a drawing.
Returns:
The arrow type for first dimension arrow.
GetSecondDimArrowType
/*optional*/ LeaderArrowType
GetSecondDimArrowType
( /*optional*/ Drawing Drawing, /*optional*/ View View)
Returns the arrow type used for second dimension arrow.
Parameters:
Drawing
The drawing handle. Passnullif not using a drawing.
View
The orientation of the model that will be applied before determining the arrow type. Pass nullto use the current model view, if the model is current, or a default model orientation otherwise. Pass nullif using a drawing.
Returns:
The arrow type for second dimension arrow.
Delete
void
Delete
()
Exceptions thrown (but not limited to):
XToolkitCantWrite- Could not delete the given item because it has read-only access.
XToolkitInvalidItem- The input dimension is invalid (non-driven).
User Guide References:
Returns:
IsDriving
boolean
IsDriving
()
User Guide References:
Returns:
SetAnnotationPlane
void
SetAnnotationPlane
(AnnotationPlane Plane)
Exceptions thrown (but not limited to):
XToolkitInvalidMatrix- The orientation cannot be used for the input dimension.
XToolkitNotValid- For a driving dimension annotation element, the annotation orientation provided is not frozen.
XToolkitBadContext- The driving dimension is not in an annotation element.
User Guide References:
Parameters:
Plane
Returns:
GetAnnotationPlane
GetAnnotationPlane
()
User Guide References:
Returns:
Move
void
Move
(Point3D Location)
Parameters:
Location
Returns:
IsBaseline
boolean
IsBaseline
()
User Guide References:
Returns:
IsAccessibleInModel
boolean
IsAccessibleInModel
()
User Guide References:
Returns:
SetOrdinateStandard
void
SetOrdinateStandard
(DimOrdinateStandard Standard)
Exceptions thrown (but not limited to):
XToolkitCantModify- The input ordinate dimension is not a baseline dimension.
User Guide References:
Parameters:
Standard
Returns:
GetOrdinateStandard
GetOrdinateStandard
()
User Guide References:
Returns:
IsOrdinate
boolean
IsOrdinate
()
User Guide References:
Returns:
GetBaselineDimension
/*optional*/ Dimension
GetBaselineDimension
()
User Guide References:
Returns:
CreateAnnotationElement
/*optional*/ AnnotationElement
CreateAnnotationElement
(AnnotationPlane Plane)
Exceptions thrown (but not limited to):
XToolkitInvalidType- The dimension is not a driving dimension.
XToolkitInvalidItem- This type of driving dimension is not suitable for incorporation into a driving dimension annotation element.
XToolkitFound- The dimension already has an annotation element.
XToolkitInvalidMatrix- The orientation provided cannot be used for this dimension.
User Guide References:
Parameters:
Plane
Returns:
DeleteAnnotationElement
void
DeleteAnnotationElement
()
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension does not have an annotation element.
User Guide References:
Returns:
GetChamferStyle
/*optional*/ DimChamferStyle
GetChamferStyle
( /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension is not a chamfer dimension.
User Guide References:
Parameters:
Drawing
Returns:
SetChamferStyle
void
SetChamferStyle
(DimChamferStyle ChamferStyle, /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension style is not chamfer.
User Guide References:
Parameters:
ChamferStyle
Drawing
Returns:
GetDimensionAttachPoints
GetDimensionAttachPoints
()
Exceptions thrown (but not limited to):
XToolkitInvalidItem- The input dimension is invalid (non-driven).
User Guide References:
Returns:
GetDimensionSenses
GetDimensionSenses
()
Exceptions thrown (but not limited to):
XToolkitInvalidItem- The input dimension is invalid (non-driven).
User Guide References:
Returns:
GetOrientationHint
GetOrientationHint
()
Exceptions thrown (but not limited to):
XToolkitInvalidItem- The input dimension is invalid (non-driven).
User Guide References:
Returns:
SetDimensionAttachPoints
void
SetDimensionAttachPoints
(DimensionAttachments DimAttachments, DimSenses DimSenses, DimOrientationHint OrientHint, AnnotationPlane AnnotPlane)
Exceptions thrown (but not limited to):
XToolkitBadDimAttach- A dimension could not be created with the attachments and sense specified.
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
DimAttachments
DimSenses
OrientHint
AnnotPlane
Returns:
EraseWitnessLine
void
EraseWitnessLine
(int WitnessLineIndex, /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNoChange- The dimension witnessline could not be erased.
User Guide References:
Parameters:
WitnessLineIndex
Drawing
Returns:
ShowWitnessLine
void
ShowWitnessLine
( /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNoChange- The dimension witnessline could not be shown or input dimension does not have erased witnessline.
User Guide References:
Parameters:
Drawing
Returns:
SetOrdinateReferences
void
SetOrdinateReferences
(DimensionAttachment DimAttachment, DimSenses DimSenses, DimOrientationHint OrientHint)
Exceptions thrown (but not limited to):
XToolkitBadDimAttach- Invalid attachment geometry for this ordinate dimension.
XToolkitInvalidType- The dimension is not an ordinate dimension.
User Guide References:
Parameters:
DimAttachment
DimSenses
OrientHint
Returns:
OrdinateDimensionToLinear
void
OrdinateDimensionToLinear
()
Exceptions thrown (but not limited to):
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Returns:
LinearDimensionToOrdinate
void
LinearDimensionToOrdinate
(Dimension Dimension)
Exceptions thrown (but not limited to):
XToolkitCantWrite- Could not modify the given item because it has read-only access.
User Guide References:
Parameters:
Dimension
Returns:
SetDimensionArrowType
void
SetDimensionArrowType
(int ArrowIndex, LeaderArrowType ArrowType, /*optional*/ Drawing Drawing)
Exceptions thrown (but not limited to):
XToolkitNotFound- The dimension does not exist.
XToolkitInvalidPtr- The dimension owner is invalid.
XToolkitCantModify- The dimension cannot be modified.
User Guide References:
Parameters:
ArrowIndex
ArrowType
Drawing
Returns:
GetParentDimension
/*optional*/ Dimension
GetParentDimension
()
Retrieves the parent dimension of the value dependent dimension.
Returns:
The parent dimension.
GetOriginSide
/*optional*/ Integer
GetOriginSide
()
Identify if dimension has an origin side
Returns:
The witness line index: 1 or 2. Returns -1 if dimension has no origin side.
SetOriginSide
void
SetOriginSide
(int WitnessLineIndex)
Sets origin side to dimension.
Parameters:
WitnessLineIndex
The witness line index: 1 or 2. Pass -1 to remove origin set on either side.
Returns:
GetDualOptions
GetDualOptions
( /*optional*/ Drawing Drw)
Gets the dual dimension display options.
Parameters:
Drw
The drawing handle. Pass nullif not using a drawing.
Returns:
The dual dimension instructions object.
SetDualOptions
void
SetDualOptions
( /*optional*/ Drawing Drw, DualDimensionInstructions DDInst)
Sets the dual dimension display using specified options.
Parameters:
Drw
The drawing handle. Pass nullif not using a drawing.
DDInst
The dual dimension instructions object.
Returns:
GetDisplayFormat
GetDisplayFormat
()
Get display format of dimension.
Returns:
The dimension display format type.
SetDisplayFormat
void
SetDisplayFormat
Set display format of dimension.
Parameters:
Format
The dimension display format type.
Returns:
GetAdditionalReferences
GetAdditionalReferences
Get dimension references.
Parameters:
RefType
The type of dimension reference.
Returns:
Sequence of additional references.
AddAdditionalReferences
void
AddAdditionalReferences
Add dimension references.
Parameters:
RefType
The type of dimension reference.
Refs
Sequence of additional references to add.
Returns:
DeleteAdditionalReferences
void
DeleteAdditionalReferences
(DimensionReferenceType RefType, int Index)
Delete dimension reference.
Parameters:
RefType
The type of dimension reference.
Index
The index of reference to delete. Indices start from 0. Get additional references using WDimension.GetAdditionalReferences(DimensionReferenceType).
Returns:
GetEnvelope
GetEnvelope
( /*optional*/ Drawing Drawing, int Line)
Get the envelope of a line in a specified dimension. For getting coordinates of dimension displayed in solid and same dimension is displayed in drawing then drawing should not be active.
Exceptions thrown (but not limited to):
XToolkitNotFound- The indicated line does not exist.
User Guide References:
Parameters:
Drawing
Pass only for solid dim shown in drawing. Otherwise pass NULL.
Line
The line number of the dimension.
Returns:
The envelope surrounding the text line, in the model's coordinate system. For drawing it is in the screen coordinates.
Was this helpful?