All Frameworks  Object Hierarchy  This Framework  Indexes   

RectPattern (Object)

Represents the rectangular pattern.
The shape is copied along two directions. Two linear repartitions control the shape copy.
See also:
LinearRepartition

Property Index

FirstDirectionRepartition
Returns the linear repartition along the first direction.
FirstDirectionRow
Returns the position of the shape to be copied along the first linear direction.
FirstOrientation
Returns or sets whether the pattern is built towards the first direction orientation.
FirstRectangularPatternParameters
Returns or sets the rectangular pattern parameters required to define the pattern.
SecondDirectionRepartition
Returns the linear repartition along the second direction.
SecondDirectionRow
Returns the position of the shape to be copied along the second linear direction.
SecondOrientation
Returns or sets whether the pattern is built towards the second direction orientation.
SecondRectangularPatternParameters
Returns or sets the rectangular pattern parameters required to define the pattern.

Method Index

GetFirstDirection
Returns the first repartition direction.
GetSecondDirection
Returns the second repartition direction.
SetFirstDirection
Sets the first repartition direction.
SetInstanceSpacing
Sets the InstanceSpacing.
SetSecondDirection
Sets the second repartition direction.
SetUnequalInstanceNumber
Sets the Instance Number.

Properties


o Property FirstDirectionRepartition() As (Read Only)
Returns the linear repartition along the first direction.
Example:
The following example returns in repart1 the first linear repartition of the rectangular pattern firstPattern:
 Set repart1 = firstPattern.FirstDirectionRepartition
 
o Property FirstDirectionRow() As (Read Only)
Returns the position of the shape to be copied along the first linear direction.
Example:
The following example returns in FirstDirPos the position of the shape to be copied along the first linear direction in the rectangular pattern firstPattern:
 Set FirstDirPos = firstPattern.FirstDirectionRow
 
o Property FirstOrientation() As
Returns or sets whether the pattern is built towards the first direction orientation.
True if the pattern is built towards the first direction orientation.
Example:
The following example returns in aligned1 whether the rectangular pattern firstPattern is built towards the first direction orientation, and then sets its to True:
 Set aligned1 = firstPattern.FirstOrientation
 firstPattern.FirstOrientation = True
 
o Property FirstRectangularPatternParameters() As
Returns or sets the rectangular pattern parameters required to define the pattern. These parameters are used when reading the CATIALinearRepartition properties.
Example:
The following example returns in parameters the rectangular pattern parameters of the firstPattern rectangular pattern, and then sets it to catUnequalSpacing, so that the unqual spacing will be defined in first direction:
 Set parameters = firstPattern.FirstCircularPatternParameters
 Set firstPattern.FirstCircularPatternParameters = catUnequalSpacing
 
o Property SecondDirectionRepartition() As (Read Only)
Returns the linear repartition along the second direction.
Example:
The following example returns in repart2 the second linear repartition of the rectangular pattern firstPattern:
 Set repart2 = firstPattern.SecondDirectionRepartition
 
o Property SecondDirectionRow() As (Read Only)
Returns the position of the shape to be copied along the second linear direction.
Example:
The following example returns in SecondDirPos the position of the shape to be copied along the second linear direction in the rectangular pattern firstPattern:
 Set SecondDirPos = firstPattern.SecondDirectionRow
 
o Property SecondOrientation() As
Returns or sets whether the pattern is built towards the second direction orientation.
True if the pattern is built towards the second direction orientation.
Example:
The following example returns in aligned2 whether the rectangular pattern firstPattern is built towards the second direction orientation, and then sets its to False, meaning the pattern is built in the opposite direction:
 Set aligned2 = firstPattern.SecondOrientation
 firstPattern.SecondOrientation = False
 
o Property SecondRectangularPatternParameters() As
Returns or sets the rectangular pattern parameters required to define the pattern. These parameters are used when reading the CATIALinearRepartition properties.
Example:
The following example returns in parameters the rectangular pattern parameters of the secondPattern rectangular pattern, and then sets it to catUnequalSpacing, so that the unqual spacing will be defined in second direction:
 Set parameters = secondPattern.SecondCircularPatternParameters
 Set secondPattern.SecondCircularPatternParameters = catUnequalSpacing
 

Methods


o Sub GetFirstDirection( ioFirstDirection)
Returns the first repartition direction. The first repartition direction is returned as an array containing the direction vector components. Assume this array is o1stDirRep. It contains:
o1stDirRep[0],o1stDirRep[1],o1stDirRep[2]
The X, Y, and Z direction vector components
Example:
The following example returns in FirstDir the first repartition direction vector components of the rectangular pattern firstPattern and saves them in variables:
 Dim FirstDir()
 Call firstPattern.GetFirstDirection(FirstDir)
 x = FirstDir(0)
 y = FirstDir(1)
 z = FirstDir(2)
 
o Sub GetSecondDirection( ioSecondDirection)
Returns the second repartition direction. The second repartition direction is returned as an array containing the direction vector components. Assume this array is o2ndDirRep. It contains:
o2ndDirRep[0],o2ndDirRep[1],o2ndDirRep[2]
The X, Y, and Z direction vector components
Example:
The following example returns in SecondDir the second repartition direction vector components of the rectangular pattern firstPattern and saves them in variables:
 Call firstPattern.GetSecondDirection(SecondDir)
 x = SecondDir[0]
 y = SecondDir[1]
 z = SecondDir[2]
 
o Sub SetFirstDirection( iFirstDirection)
Sets the first repartition direction.
Parameters:
iFirstDirection
The first repartition direction. It is passed as a
Reference and can be valuated with a reference to a line or an edge.
The following Boundary objects are supported: PlanarFace, RectilinearTriDimFeatEdge and RectilinearBiDimFeatEdge.
Example:
The following example sets the first repartition direction of the rectangular pattern firstPattern with the refToLine1 reference :
 firstPattern.SetFirstDirection refToLine1
 
o Sub SetInstanceSpacing( iInstanceNumber,
iSpacing,
iDirection)
Sets the InstanceSpacing.
Parameters:
iInstanceNumber
The Instance Number
iSpacing
The Spacing
iDirection
The Instance direction
Example:
The following example sets the InstanceSpacing in a direction for unequal spacing
o Sub SetSecondDirection( iSecondDirection)
Sets the second repartition direction.
Parameters:
iSecondDirection
The second repartition direction. It is passed as a
Reference and can be valuated with a reference to a line or an edge.
The following Boundary objects are supported: PlanarFace, RectilinearTriDimFeatEdge and RectilinearBiDimFeatEdge.
Example:
The following example sets the second repartition direction of the rectangular pattern firstPattern with the refToLine2 reference :
 firstPattern.SetSecondDirection refToLine2
 
o Sub SetUnequalInstanceNumber( iInstanceNumber,
iDirection)
Sets the Instance Number.
Parameters:
iInstanceNumber
The Instance Number
iDirection
The Instance direction
Example:
The following example modifies the instance number for unequal spacing

Copyright © 2003, Dassault Systèmes. All rights reserved.