.NET API
PlainBandApi
Single plain bands.
from ArtisanPlugin.Scripting import PlainBandApi
See also the Python package, ra.plain_band.
Methods
| Method | |
|---|---|
All | IPlainBand handles for every object of this kind in the active document (empty when there is no document). |
ByLayer | IPlainBand 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. |
Find | The handle for id, or null when the id does not belong to an object of this kind. |
Selected | IPlainBand handles for the objects of this kind currently selected in the active document. |
All
IReadOnlyList<IPlainBand> PlainBandApi.All()
IPlainBand handles for every object of this kind in the active document (empty when there is no document).
Returns IReadOnlyList<IPlainBand>.
ByLayer
IReadOnlyList<IPlainBand> PlainBandApi.ByLayer(string layerName)
IPlainBand handles on the layer with the given full path (empty when the layer does not exist).
| Parameter | Type | Default |
|---|---|---|
layerName | string | required |
Returns IReadOnlyList<IPlainBand>.
Count
int PlainBandApi.Count()
Number of objects of this kind in the active document.
Returns int.
Find
IPlainBand PlainBandApi.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 IPlainBand.
Selected
IReadOnlyList<IPlainBand> PlainBandApi.Selected()
IPlainBand handles for the objects of this kind currently selected in the active document.
Returns IReadOnlyList<IPlainBand>.
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.
Also used here: IWeddingRing, IWeddingProfile, IWeddingGems.
IPlainBand
Handle — extends IParametricObject.
A single plain band.
| Property | Type | ||
|---|---|---|---|
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) |
Region | string | get | sizing region, "" when unset |
Ring | IWeddingRing | get |
| Method | |
|---|---|
void Delete() | (from IParametricObject) |
void Move(Vector3d translation) | (from IParametricObject) |
void SetElement(string element) | Applies a saved PlainBand element (ElementsApi.List(“PlainBand”)) to this band: its profile, gems and metal replace the current ones, the ring size stays, and the band regenerates in place (same id). |