.NET API
SplitShankApi
Split shanks - the band that opens into two arms toward the setting. Create takes the parameters that define the split; the rest of the model is adjusted afterwards through the returned handle’s setters.
from ArtisanPlugin.Scripting import SplitShankApi
See also the guide, Shanks › Split shank, and the Python package, ra.split_shank.
Methods
| Method | |
|---|---|
All | ISplitShank handles for every object of this kind in the active document (empty when there is no document). |
ByLayer | ISplitShank handles on the layer with the given full path (empty when the layer does not exist). |
Count | Number of objects of this kind in the active document. |
Create | Builds a split shank — the ArtisanSplitShank tool, headless. |
Find | The handle for id, or null when the id does not belong to an object of this kind. |
Selected | ISplitShank handles for the objects of this kind currently selected in the active document. |
All
IReadOnlyList<ISplitShank> SplitShankApi.All()
ISplitShank handles for every object of this kind in the active document (empty when there is no document).
Returns IReadOnlyList<ISplitShank>.
ByLayer
IReadOnlyList<ISplitShank> SplitShankApi.ByLayer(string layerName)
ISplitShank handles on the layer with the given full path (empty when the layer does not exist).
| Parameter | Type | Default |
|---|---|---|
layerName | string | required |
Returns IReadOnlyList<ISplitShank>.
Count
int SplitShankApi.Count()
Number of objects of this kind in the active document.
Returns int.
Create
ISplitShank SplitShankApi.Create(
double fingerDiameter = 0,
double openingLength = 0,
double armHeight = 0,
double splitWidth = 0,
double splitStart = double.NaN,
double topSize = 0,
double bottomSize = 0,
Plane? plane = null,
string element = null)
Builds a split shank — the ArtisanSplitShank tool, headless. Millimetres / degrees; 0 keeps the tool default (or the user’s saved defaults). fingerDiameter 0 = the document’s finger size. Returns an ISplitShank handle to the new shank. element = name of a saved split shank element (ElementsApi.List(“SplitShank”)) to start from instead of the tool defaults; explicit arguments override it.
| Parameter | Type | Default |
|---|---|---|
fingerDiameter | double | 0 |
openingLength | double | 0 |
armHeight | double | 0 |
splitWidth | double | 0 |
splitStart | double | double.NaN |
topSize | double | 0 |
bottomSize | double | 0 |
plane | Plane? | null |
element | string | null |
Returns ISplitShank.
Find
ISplitShank SplitShankApi.Find(Guid id)
The handle for id, or null when the id does not belong to an object of this kind.
| Parameter | Type | Default |
|---|---|---|
id | Guid | required |
Returns ISplitShank.
Selected
IReadOnlyList<ISplitShank> SplitShankApi.Selected()
ISplitShank handles for the objects of this kind currently selected in the active document.
Returns IReadOnlyList<ISplitShank>.
Handles and sections
What the methods above hand back. A handle’s setters regenerate the object; wrap changes in a Transaction so they land as one undo step.
ISplitShank
Handle — extends IParametricObject.
Split shank: a band that opens into two arms toward the setting. Multiple gems, so no single MotherGem.
| Property | Type | ||
|---|---|---|---|
Curve | ISplitShankCurve | get | |
Gems | ISplitShankGems | get | |
Id | Guid | get | (from IParametricObject) |
LayerName | string | get | (from IParametricObject) |
MotherGemId | Guid | get | (from IParametricObject) |
ObjectType | string | get | (from IParametricObject) |
Position | Point3d | get | (from IParametricObject) |
RingDiameterMm | double | get | |
RingSizeLabel | string | get | |
RingSizeRegion | string | get | |
Sections | IReadOnlyList<ISplitShankSection> | get | The three swept profiles, ordered bottom -> side -> top. |
| Method | |
|---|---|
void Delete() | (from IParametricObject) |
void Move(Vector3d translation) | (from IParametricObject) |
void SetElement(string element) | Applies a saved SplitShank element (ElementsApi.List(“SplitShank”)) to this shank: its parameters replace the current ones, the ring size stays, and the shank regenerates in place (same id). |
void SetSection( int index, double position, double width, double height, string type = null, string profileName = null) | Edits one of the three sections in place. profileName omitted keeps the section’s current asset. |
void SetSectionEnabled(int index, bool enabled) |
ISplitShankSection
Section.
One of the profiles swept along the rail. A split shank keeps exactly three — bottom (T = 0), side (movable) and top (T = 1).
| Property | Type | ||
|---|---|---|---|
Comfort | double | get | mm |
Displacement | double | get | mm |
Enabled | bool | get | |
Height | double | get | mm |
Orientation | int | get | 0 = Natural, 1 = Reverse |
Position | double | get | T along the rail: 0 = ring bottom, 1 = arm tip |
ProfileName | string | get | RING_PROFILE asset name, "" when unset |
Rotation | double | get | degrees |
Thickness | double | get | mm |
Type | string | get | ”SOLID”, “COMFORT” or “THICKNESS” |
Width | double | get | mm |
ISplitShankGems
Section.
The pave run along a split shank’s arms, with a top-to-bottom size gradient.
| Property | Type | ||
|---|---|---|---|
AutomaticProngDiameter | bool | get | |
BottomSize | double | get | stone size at the ring bottom, mm |
BrightCut | double | get | mm |
ChannelClearance | double | get | mm |
ChannelShape | string | get | |
DrillType | string | get | ”NONE”, “ROUND” or “QUAD” |
Enabled | bool | get | |
FlipEnd | bool | get | |
FlipStart | bool | get | |
GemInside | double | get | mm |
InnerHeight | double | get | mm |
InnerWidth | double | get | mm |
MarginBottom | double | get | run start, in mm of arc length from the rail start (Start gumball) |
MarginTop | double | get | how far below the arm tip the gem run stops, mm (End gumball) |
MinDistance | double | get | mm |
MoveInZ | double | get | mm |
ProngDiameter | double | get | mm |
ProngHeight | double | get | mm |
ProngType | string | get | ”NONE”, “SHARED” or “SCALLOPED” |
ShankSize | double | get | mm |
Shape | string | get | ”ROUND”, “PRINCESS”, … |
Spacing | double | get | gap between gems (arms and trunk alike), mm |
TopSize | double | get | stone size at the arm tip, mm |
TransitionSize | double | get | mm |
VCutters | bool | get | |
Vertical | double | get | mm |
| Method | |
|---|---|
void ClearGemSizes() | drop every per-stone override (back to the size gradient) |
void SetAutomaticProngDiameter(bool automatic) | |
void SetBrightCut(double brightCut) | |
void SetChannelClearance(double clearance) | |
void SetChannelShape(string shape) | |
void SetDrillType(string drillType) | ”NONE”, “ROUND” or “QUAD” |
void SetEnabled(bool enabled) | |
void SetFlipEnd(bool flip) | |
void SetFlipStart(bool flip) | |
void SetGemInside(double gemInside) | |
void SetGemSize(double position, double diameter) | per-stone override; position = normalised rail t (0..1), snaps to the nearest stone |
void SetInnerHeight(double height) | |
void SetInnerWidth(double width) | |
void SetMargins(double top, double bottom) | |
void SetMinDistance(double distance) | |
void SetMoveInZ(double move) | |
void SetProngDiameter(double diameter) | |
void SetProngHeight(double height) | |
void SetProngType(string prongType) | ”NONE”, “SHARED” or “SCALLOPED” |
void SetShankSize(double size) | |
void SetShape(string shape) | |
void SetSizes(double topSize, double bottomSize) | |
void SetSpacing(double spacing) | |
void SetTransitionSize(double size) | |
void SetVCutters(bool enabled) | |
void SetVertical(double vertical) |
ISplitShankCurve
Section.
The rail a split shank is swept along: how the arms rise, open and split.
| Property | Type | ||
|---|---|---|---|
ArmHeight | double | get | rise of the arm tips above the ring top, mm |
ArmOffset | double | get | extra outward bulge beyond the reference shape, mm |
LateralDisplacement | double | get | Y displacement of the arm tips, mm |
LateralInclination | double | get | inclination of the arms along the finger axis, degrees |
OpeningLength | double | get | frontal X distance between the arm tips, mm (0 = touching) |
SplitStart | double | get | where along the rail the split begins, 0..1 |
SplitWidth | double | get | separation between the front and back arm pairs, mm |
| Method | |
|---|---|
void SetArmHeight(double height) | |
void SetArmOffset(double offset) | |
void SetLateralDisplacement(double displacement) | |
void SetLateralInclination(double degrees) | |
void SetOpeningLength(double length) | |
void SetSplitStart(double start) | 0..1 |
void SetSplitWidth(double width) |