.NET API
EternityApi
Eternity bands with stones all around.
from ArtisanPlugin.Scripting import EternityApi
See also the guide, Shanks › Eternity, and the Python package, ra.eternity.
Methods
| Method | |
|---|---|
All | IEternity handles for every object of this kind in the active document (empty when there is no document). |
ByLayer | IEternity 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 an eternity ring (the ArtisanEternity tool, headless): a band with gems all around, at the document’s finger size. |
Find | The handle for id, or null when the id does not belong to an object of this kind. |
Selected | Eternities currently selected in the active doc. |
All
IReadOnlyList<IEternity> EternityApi.All()
IEternity handles for every object of this kind in the active document (empty when there is no document).
Returns IReadOnlyList<IEternity>.
ByLayer
IReadOnlyList<IEternity> EternityApi.ByLayer(string layerName)
IEternity handles on the layer with the given full path (empty when the layer does not exist).
| Parameter | Type | Default |
|---|---|---|
layerName | string | required |
Returns IReadOnlyList<IEternity>.
Count
int EternityApi.Count()
Number of objects of this kind in the active document.
Returns int.
Create
IEternity EternityApi.Create(
double gemSize = 0,
string gemShape = null,
double shankWidth = 0,
double shankHeight = 0,
double fingerDiameter = 0,
string profile = null,
Plane? plane = null,
string element = null)
Builds an eternity ring (the ArtisanEternity tool, headless): a band with gems all around, at the document’s finger size. Standalone — no mother gem or curve needed. Millimetres; 0 keeps the tool default (or the user’s saved defaults): gemSize ~2 (round diamonds), shankWidth 2.25, shankHeight 1.5. gemShape accepts GemShape names (default ROUND). fingerDiameter 0 = the document’s finger size. plane omitted = world XY. profile picks a RING_PROFILE asset by name for the shank; omitted = the default profile. Returns an IEternity handle to the new ring group. element = name of a saved eternity element (ElementsApi.List(“Eternity”)) to start from instead of the tool defaults; explicit arguments override it.
| Parameter | Type | Default |
|---|---|---|
gemSize | double | 0 |
gemShape | string | null |
shankWidth | double | 0 |
shankHeight | double | 0 |
fingerDiameter | double | 0 |
profile | string | null |
plane | Plane? | null |
element | string | null |
Returns IEternity.
Find
IEternity EternityApi.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 IEternity.
Selected
IReadOnlyList<IEternity> EternityApi.Selected()
Eternities currently selected in the active doc.
Returns IReadOnlyList<IEternity>.
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.
IEternity
Handle — extends IParametricObject.
Eternity ring: a band with gems all around. Multiple gems, so no single MotherGem.
| Property | Type | ||
|---|---|---|---|
Bezels | IEternityBezels | get | |
Gems | IEternityGems | get | Parameter sections — each is a live view over the ring’s stored parameters; their setters regenerate the ring in place (same Guid) and call LicenseGate.RequireValid() first. Millimetres. |
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) |
Prongs | IEternityProngs | get | |
RingDiameterMm | double | get | |
RingSizeLabel | string | get | e.g. “6”, “M” |
RingSizeRegion | string | get | e.g. “US”, “EU” |
Shank | IEternityShank | get |
| Method | |
|---|---|
void Delete() | (from IParametricObject) |
void Move(Vector3d translation) | (from IParametricObject) |
void SetElement(string element) | Applies a saved Eternity element (ElementsApi.List(“Eternity”)) to this ring: its parameters replace the current ones, the ring size stays, and the ring regenerates in place (same id). |
IEternityShank
Section.
The band: an upper and a lower half plus the caps where they meet.
| Property | Type | ||
|---|---|---|---|
EndingCap | double | get | mm |
Lower | IEternityShankParams | get | |
StartingCap | double | get | mm |
Upper | IEternityShankParams | get |
| Method | |
|---|---|
void SetEndingCap(double cap) | |
void SetStartingCap(double cap) |
IEternityShankParams
Section.
One of the two band halves (upper / lower) of an eternity ring.
| Property | Type | ||
|---|---|---|---|
Height | double | get | mm |
HeightComfort | double | get | mm |
ProfileName | string | get | RING_PROFILE asset name, "" when unset |
ProfileOrientation | int | get | 0 = Natural, 1 = Reverse |
ProfileThickness | double | get | mm |
ProfileType | int | get | |
Type | string | get | ”SOLID”, “COMFORT” or “THICKNESS” |
Width | double | get | mm |
| Method | |
|---|---|
void SetHeight(double height) | |
void SetHeightComfort(double comfort) | |
void SetProfile(string assetName) | RING_PROFILE asset by name — list them with AssetsApi.List(“RING_PROFILE”) |
void SetProfileOrientation(int orientation) | |
void SetProfileThickness(double thickness) | |
void SetProfileType(int profileType) | |
void SetType(string type) | ”SOLID”, “COMFORT” or “THICKNESS” |
void SetWidth(double width) |
IEternityProngs
Section.
The prongs holding the stones.
| Property | Type | ||
|---|---|---|---|
BottomDiameter | double | get | mm |
BottomDistance | double | get | mm |
Distribution | string | get | ”SHARED” or “INDIVIDUAL_FOR_EACH_GEM” |
ExpansionManufacturing | double | get | mm |
HeightOverGirdle | double | get | mm |
IndividualBottomDistance | double | get | mm — used when Distribution is individual |
IndividualTopDistance | double | get | mm — used when Distribution is individual |
Mode | string | get | ”STRAIGHT” or “CURVED” |
TopDiameter | double | get | mm |
TopDistance | double | get | mm |
| Method | |
|---|---|
void SetBottomDiameter(double diameter) | |
void SetBottomDistance(double distance) | |
void SetDistribution(string distribution) | ”SHARED” or “INDIVIDUAL_FOR_EACH_GEM” |
void SetExpansionManufacturing(double expansion) | |
void SetHeightOverGirdle(double height) | |
void SetIndividualBottomDistance(double distance) | |
void SetIndividualTopDistance(double distance) | |
void SetMode(string mode) | ”STRAIGHT” or “CURVED” |
void SetTopDiameter(double diameter) | |
void SetTopDistance(double distance) |
IEternityGems
Section.
The stones that run around the band.
| Property | Type | ||
|---|---|---|---|
CaratWeight | double | get | |
Distribution | string | get | ”FULL”, “HALF”, “THREEQUARTERS”, “FIVESTONES”, “SEVENSTONES”, “NINESTONES” |
Material | string | get | ”Diamond”, “Ruby”, … |
MinDistance | double | get | minimum distance between stones, mm |
MoveInZ | double | get | radial displacement of the stone row, mm |
Orientation | string | get | ”NATURAL” or “ROTATED” |
Shape | string | get | ”ROUND”, “PRINCESS”, … |
SizeX | double | get | mm |
SizeY | double | get | mm |
SizeZ | double | get | mm |
| Method | |
|---|---|
void SetCaratWeight(double carat) | |
void SetDistribution(string distribution) | |
void SetMaterial(string material) | |
void SetMinDistance(double distance) | |
void SetMoveInZ(double moveInZ) | |
void SetOrientation(string orientation) | ”NATURAL” or “ROTATED” |
void SetShape(string shape) | |
void SetSize(double sizeX, double sizeY, double sizeZ) |
IEternityBezels
Section.
The bezel rails wrapping the stone row.
| Property | Type | ||
|---|---|---|---|
BottomRail | IEternityRail | get | |
ProfileShape | string | get | ”ROUND” or “SQUARE” |
RailMode | string | get | ”SINGLE” or “DOUBLE” |
RailShape | string | get | ”ROUND”, “RECTANGLE” or “OVAL” |
RemoveFinger | bool | get | |
TopRail | IEternityRail | get |
| Method | |
|---|---|
void SetProfileShape(string shape) | ”ROUND” or “SQUARE” |
void SetRailMode(string mode) | ”SINGLE” or “DOUBLE” |
void SetRailShape(string shape) | ”ROUND”, “RECTANGLE” or “OVAL” |
void SetRemoveFinger(bool remove) |
IEternityRail
Section.
One of the two rails that form the bezel around the stones.
| Property | Type | ||
|---|---|---|---|
Diameter | double | get | mm |
Height | double | get | mm |
MoveInZ | double | get | mm |
ThreadDiameter | double | get | mm |
ThreadX | double | get | mm |
ThreadY | double | get | mm |
Width | double | get | mm |
| Method | |
|---|---|
void SetDiameter(double diameter) | |
void SetHeight(double height) | |
void SetMoveInZ(double moveInZ) | |
void SetThread(double x, double y) | |
void SetThreadDiameter(double diameter) | |
void SetWidth(double width) |