Stock

This page covers ISheet, ISheets, ISheetChangeEvent, ISheetChangeEventHandler, ISheetDefect, ISheetDefects, ISheetDefectChangeEvent, and ISheetDefectChangeEventHandler. These interfaces describe available stock items and the rectangular regions attached to them, which are either defects or holes (see below).

An ISheet exposes its original Defects separately from Holes, plus per-edge MinEdgeDistance and mutable ITcAlgorithmData. Its payload is opaque and implementation-defined; no public key/value schema or compatibility guarantee is provided. Preserve the stock-property distinctions when importing or exporting stock.

Interfaces

Declarations are shown in Pascal and, where the SDK's generated language-support manifest lists the member for C++, in C++; the build fails if that manifest no longer matches TonCutPluginSdk.hpp. There is no C# declaration: C# plugins are native-shim-only, so a C++ shim owns every interface on this page. Methods are listed with their accessors folded into properties; open Vtable order for the exact slot sequence, and see ABI and marshalling for type sizes and ownership rules.

ISheet

Stock sheet definition including material, edging, defect list, reuse constraints, and extraction cost.

IID
{3D92A70F-6B18-45C4-A8E1-7C204F6B9D35}
Parent
IUnknown (implicit: a Delphi interface without a parent is IUnknown)
Unit
uISheet
Vtable order (49 methods, slots 3 to 51, after the three IUnknown slots)
  1. function GetId(): Int64;
  2. procedure SetId(aId: Int64);
  3. function GetWidth(): Cardinal;
  4. procedure SetWidth(aWidth: Cardinal);
  5. function GetLength(): Cardinal;
  6. procedure SetLength(aLength: Cardinal);
  7. function GetQuantity(): Integer;
  8. procedure SetQuantity(aQuantity: Integer);
  9. function GetStackSize(): Cardinal;
  10. procedure SetStackSize(aSize: Cardinal);
  11. function GetOrnament(): TOrnament;
  12. procedure SetOrnament(aOrnament: TOrnament);
  13. function GetIdentifier(): WideString;
  14. procedure SetIdentifier(const aIdentifier: WideString);
  15. function GetDescription(): WideString;
  16. procedure SetDescription(const aDescription: WideString);
  17. function GetMaterial(): IMaterial;
  18. procedure SetMaterial(const aMaterial: IMaterial);
  19. function GetEdging(): IRectangle;
  20. function GetMinEdgeDistance(): IRectangle;
  21. function GetPriority(): Integer;
  22. procedure SetPriority(aPriority: Integer);
  23. function GetCutShiftHorzLimit(): Integer;
  24. procedure SetCutShiftHorzLimit(aLimit: Integer);
  25. function GetCutShiftVertLimit(): Integer;
  26. procedure SetCutShiftVertLimit(aLimit: Integer);
  27. function GetEffectiveCutShiftHorzLimit(): Integer;
  28. function GetEffectiveCutShiftVertLimit(): Integer;
  29. function GetExtractionCost(): TTcPrice;
  30. procedure SetExtractionCost(aCost: TTcPrice);
  31. function GetCustomData(): WideString;
  32. procedure SetCustomData(const aData: WideString);
  33. function GetAlgorithmData(): ITcAlgorithmData;
  34. function GetDefects(): ISheetDefects;
  35. function GetHoles(): ISheetDefects;
  36. function GetAvailableQuantity(): Cardinal;
  37. function GetField(): TField;
  38. function GetFieldOfAll(): TField;
  39. function IsStandard(): Boolean;
  40. procedure Assign(const aSheet: ISheet);
  41. function GetOnChange(): INotifyEvent;
  42. function GetOnIdChange(): IIdChangeEvent;
  43. function GetOnDefectAdd(): ISheetDefectChangeEvent;
  44. function GetOnDefectRemove(): ISheetDefectChangeEvent;
  45. function GetOnDefectChange(): ISheetDefectChangeEvent;
  46. procedure BeginUpdate();
  47. procedure EndUpdate();
  48. function GetPricePerSqM(): TTcPrice;
  49. procedure SetPricePerSqM(aPrice: TTcPrice);

Properties

  • Property name
    Id
    Type
    Int64
    Description

    Persistent numeric identifier used by TonCut to track the object.

    Declaration

    property Id: Int64 read GetId write SetId;
  • Property name
    Width
    Type
    Cardinal
    Description

    Width value stored on the object.

    Declaration

    property Width: Cardinal read GetWidth write SetWidth;
  • Property name
    Length
    Type
    Cardinal
    Description

    Length value stored on the object.

    Declaration

    property Length: Cardinal read GetLength write SetLength;
  • Property name
    Quantity
    Type
    Integer
    Description

    Number of sheets of this stock item.

    Declaration

    property Quantity: Integer read GetQuantity write SetQuantity;
  • Property name
    StackSize
    Type
    Cardinal
    Description

    Maximum stack size or batch size.

    Declaration

    property StackSize: Cardinal read GetStackSize write SetStackSize;
  • Property name
    Ornament
    Type
    Description

    Grain or ornament direction associated with the stock item.

    Declaration

    property Ornament: TOrnament read GetOrnament write SetOrnament;
  • Property name
    Identifier
    Type
    WideString
    Description

    Code stored with the object, such as a part number.

    Declaration

    property Identifier: WideString read GetIdentifier write SetIdentifier;
  • Property name
    Description
    Type
    WideString
    Description

    Name or descriptive text shown to the user.

    Declaration

    property Description: WideString read GetDescription write SetDescription;
  • Property name
    Material
    Type
    IMaterial
    Description

    Material linked to the object.

    Declaration

    property Material: IMaterial read GetMaterial write SetMaterial;
  • Property name
    Edging
    Type
    IRectangle
    Description

    Rectangle-like edging or margin helper attached to the object.

    Declaration

    property Edging: IRectangle read GetEdging;
  • Property name
    MinEdgeDistance
    Type
    IRectangle
    Description

    Per-edge minimum distance exposed as a signed rectangle; a negative side means inherited or unspecified.

    Declaration

    property MinEdgeDistance: IRectangle read GetMinEdgeDistance;
  • Property name
    Priority
    Type
    Integer
    Description

    Gets or sets the stock priority for this sheet: an integer from cStockPriorityMin to cStockPriorityMax (0 to 100); a higher value is consumed earlier. cStockPriorityLow (0) is the "low" label and cStockPriorityNormal (10) is the default "normal" label. It is a soft signal that factors into the sheet score and only breaks ties in consumption order. The cStockPriority* constants are defined in uICommon and in TonCutPluginSdk.hpp. Breaking change: this property used to be the TOldStockPriority enum. GetPriority/SetPriority keep the same vtable slots and interface GUID, but the signature changed in place, so a plugin built against the previous enum must be rebuilt against the current SDK.

    Declaration

    property Priority: Integer read GetPriority write SetPriority;
  • Property name
    CutShiftHorzLimit
    Type
    Integer
    Description

    Horizontal limit for cut shifting.

    Declaration

    property CutShiftHorzLimit: Integer read GetCutShiftHorzLimit write SetCutShiftHorzLimit;
  • Property name
    CutShiftVertLimit
    Type
    Integer
    Description

    Vertical limit for cut shifting.

    Declaration

    property CutShiftVertLimit: Integer read GetCutShiftVertLimit write SetCutShiftVertLimit;
  • Property name
    EffectiveCutShiftHorzLimit
    Type
    Integer
    Description

    Gets effective cut shift horz limit.

    Declaration

    property EffectiveCutShiftHorzLimit: Integer read GetEffectiveCutShiftHorzLimit;
  • Property name
    EffectiveCutShiftVertLimit
    Type
    Integer
    Description

    Effective vertical cut-shift limit after host rules are applied.

    Declaration

    property EffectiveCutShiftVertLimit: Integer read GetEffectiveCutShiftVertLimit;
  • Property name
    ExtractionCost
    Type
    TTcPrice
    Description

    Gets or sets extraction cost.

    Declaration

    property ExtractionCost: TTcPrice read GetExtractionCost write SetExtractionCost;
  • Property name
    PricePerSqM
    Type
    TTcPrice
    Description

    Gets or sets this stock item’s own price per square metre, overriding its material’s PricePerSqM for this item alone. cStockPriceAbsent (-1, defined in uICommon and TonCutPluginSdk.hpp) means no override is set, so the material price applies; any other value, including an explicit 0, must be finite and >= 0. GetPricePerSqM/SetPricePerSqM are new vtable slots appended at the end of the interface, after EndUpdate, under the same interface GUID, so no existing slot moves. TonCut implements ISheet; a plugin only calls these accessors. Engine version 24 carries these slots, and the host refuses a plugin whose EngineVersion does not match, so rebuild plugins against the current SDK.

    Declaration

    property PricePerSqM: TTcPrice read GetPricePerSqM write SetPricePerSqM;
  • Property name
    CustomData
    Type
    WideString
    Description

    Opaque custom text payload stored with the object.

    Declaration

    property CustomData: WideString read GetCustomData write SetCustomData;
  • Property name
    AlgorithmData
    Type
    ITcAlgorithmData
    Description

    Mutable access to opaque, implementation-defined algorithm data owned by the current device, material, piece, or stock sheet. No public payload schema or compatibility guarantee is provided.

    Declaration

    property AlgorithmData: ITcAlgorithmData read GetAlgorithmData;

    No C++ declaration in the SDK's language-support manifest. If your TonCutPluginSdk.hpp lacks it, declare it in the vtable order shown above.

  • Property name
    Defects
    Type
    ISheetDefects
    Description

    Read-only collection of the stock sheet’s defects: damaged material, such as a scratch. A defect is still material, so it can be cut through and may end up inside a remnant or waste, but pieces must not be placed on it. Holes are exposed separately through Holes; both use the ISheetDefects collection type.

    Declaration

    property Defects: ISheetDefects read GetDefects;
  • Property name
    Holes
    Type
    ISheetDefects
    Description

    Read-only collection of holes: areas where the stock (or a remnant, on ISolutionWaste) has no material at all. A hole comes with the stock, is never created by TonCut, is not waste, and is not usable or available area. Support is currently limited. Holes use the same ISheetDefects collection type as defects, but their meaning differs.

    Declaration

    property Holes: ISheetDefects read GetHoles;
  • Property name
    AvailableQuantity
    Type
    Cardinal
    Description

    Remaining quantity currently available.

    Declaration

    property AvailableQuantity: Cardinal read GetAvailableQuantity;
  • Property name
    Field
    Type
    TField
    Description

    Area-like value stored on the object.

    Declaration

    property Field: TField read GetField;
  • Property name
    FieldOfAll
    Type
    TField
    Description

    Gets field of all.

    Declaration

    property FieldOfAll: TField read GetFieldOfAll;
  • Property name
    OnChange
    Type
    INotifyEvent
    Description

    Event fired when the object or collection changes.

    Declaration

    property OnChange: INotifyEvent read GetOnChange;
  • Property name
    OnIdChange
    Type
    IIdChangeEvent
    Description

    Event fired when an identifier changes.

    Declaration

    property OnIdChange: IIdChangeEvent read GetOnIdChange;
  • Property name
    OnDefectAdd
    Type
    ISheetDefectChangeEvent
    Description

    Event exposed through OnDefectAdd.

    Declaration

    property OnDefectAdd: ISheetDefectChangeEvent read GetOnDefectAdd;
  • Property name
    OnDefectRemove
    Type
    ISheetDefectChangeEvent
    Description

    Event exposed through OnDefectRemove.

    Declaration

    property OnDefectRemove: ISheetDefectChangeEvent read GetOnDefectRemove;
  • Property name
    OnDefectChange
    Type
    ISheetDefectChangeEvent
    Description

    Event exposed through OnDefectChange.

    Declaration

    property OnDefectChange: ISheetDefectChangeEvent read GetOnDefectChange;

Methods

  • Method name
    IsStandard()
    Type
    Boolean
    Description

    Return is standard.

    Declaration

    function IsStandard(): Boolean; safecall;
    Returns
    Returns true if the sheet comes from a standard-sheet definition.
  • Method name
    Assign()
    Type
    procedure
    Description

    Copy values from another object of the same type.

    Declaration

    procedure Assign(const aSheet: ISheet); safecall;
    Parameters
    aSheetconst
    Sheet instance being queried or modified.
  • Method name
    BeginUpdate()
    Type
    procedure
    Description

    Start a batched update so change notifications can be delayed.

    Declaration

    procedure BeginUpdate(); safecall;
  • Method name
    EndUpdate()
    Type
    procedure
    Description

    Finish a batched update and allow deferred notifications to resume.

    Declaration

    procedure EndUpdate(); safecall;

ISheets

Collection interface used to create, enumerate, query, and reload a shared Desktop object set.

IID
{66C5F864-69D6-43A0-846B-C8AF73DA21E3}
Parent
IUnknown (implicit: a Delphi interface without a parent is IUnknown)
Unit
uISheets
Vtable order (22 methods, slots 3 to 24, after the three IUnknown slots)
  1. function CreateSheet(): ISheet;
  2. procedure Add(aSheet: ISheet);
  3. procedure DeleteByIndex(aIndex: Cardinal);
  4. procedure DeleteById(aId: Int64);
  5. procedure Remove(const aSheet: ISheet);
  6. function IndexOf(const aSheet: ISheet): Integer; overload;
  7. function IndexOf(aId: Int64): Integer; overload;
  8. function IndexOf(const aOtherSheet: ISheet; aSkipId: Int64; var aRotated: Boolean): Integer; overload;
  9. function CreateDefect(): ISheetDefect;
  10. function GetCount(): Integer;
  11. function GetByIndex(aIndex: Cardinal): ISheet;
  12. function GetById(aId: Int64): ISheet;
  13. function CalcMaxLength(): Cardinal;
  14. function GetField(): TField;
  15. function GetAvailableQuantity(): Cardinal;
  16. function GetOnAdd(): ISheetChangeEvent;
  17. function GetOnRemove(): ISheetChangeEvent;
  18. function GetOnChange(): INotifyEvent;
  19. procedure BeginUpdate();
  20. procedure EndUpdate();
  21. function IsUpdating(): Boolean;
  22. procedure Reload();

Properties

  • Property name
    Count
    Type
    Integer
    Description

    Number of items currently exposed by the interface.

    Declaration

    property Count: Integer read GetCount;
  • Property name
    Items
    Type
    ISheet
    Description

    Indexed property used to read one item from the collection.

    Declaration

    property Items[aIndex: Cardinal]: ISheet read GetByIndex; default;
    Index Parameters
    aIndex
    Cardinal
    Zero-based position within a collection.
    Value
    The collection item located at the supplied index.
  • Property name
    Field
    Type
    TField
    Description

    Area-like value stored on the object.

    Declaration

    property Field: TField read GetField;
  • Property name
    AvailableQuantity
    Type
    Cardinal
    Description

    Remaining quantity currently available.

    Declaration

    property AvailableQuantity: Cardinal read GetAvailableQuantity;
  • Property name
    OnAdd
    Type
    ISheetChangeEvent
    Description

    Event fired when an item is added.

    Declaration

    property OnAdd: ISheetChangeEvent read GetOnAdd;
  • Property name
    OnRemove
    Type
    ISheetChangeEvent
    Description

    Event fired when an item is removed.

    Declaration

    property OnRemove: ISheetChangeEvent read GetOnRemove;
  • Property name
    OnChange
    Type
    INotifyEvent
    Description

    Event fired when the object or collection changes.

    Declaration

    property OnChange: INotifyEvent read GetOnChange;

Methods

  • Method name
    CreateSheet()
    Type
    ISheet
    Description

    Create a new, empty sheet. No dialog opens, the result is never null, and the object is not in the collection until you pass it to Add. A new object has a temporary negative Id.

    Declaration

    function CreateSheet(): ISheet; safecall;
    Returns
    A new, empty sheet that is not yet in the collection; never null.
  • Method name
    Add()
    Type
    procedure
    Description

    Add an object created by this collection’s factory method. In LoadFile, add to the staging collection you received. Add does not check title uniqueness, and adding an object that is already in the collection raises an error.

    Declaration

    procedure Add(aSheet: ISheet); safecall;
    Parameters
    aSheet
    Sheet instance being queried or modified.
  • Method name
    DeleteByIndex()
    Type
    procedure
    Description

    Delete the item at the specified zero-based index.

    Declaration

    procedure DeleteByIndex(aIndex: Cardinal); safecall;
    Parameters
    aIndex
    Cardinal
    Zero-based position within a collection.
  • Method name
    DeleteById()
    Type
    procedure
    Description

    Delete the item with the specified TonCut identifier.

    Declaration

    procedure DeleteById(aId: Int64); safecall;
    Parameters
    aId
    Int64
    TonCut object identifier.
  • Method name
    Remove()
    Type
    procedure
    Description

    Remove an item or handler.

    Declaration

    procedure Remove(const aSheet: ISheet); safecall;
    Parameters
    aSheetconst
    Sheet instance being queried or modified.
  • Method name
    IndexOf()
    Type
    Integer
    Description

    Return the zero-based index of the matching item.

    Declaration

    function IndexOf(const aSheet: ISheet): Integer; overload; safecall;

    C++ name: IndexOfByObject. The C++ header gives each Pascal overload its own name; the vtable slot is the same.

    Parameters
    aSheetconst
    Sheet instance being queried or modified.
    Returns
    Zero-based index of the matching item, or -1 when no match exists.
  • Method name
    IndexOf()
    Type
    Integer
    Description

    Return the zero-based index of the matching item.

    Declaration

    function IndexOf(aId: Int64): Integer; overload; safecall;

    C++ name: IndexOfById. The C++ header gives each Pascal overload its own name; the vtable slot is the same.

    Parameters
    aId
    Int64
    TonCut object identifier.
    Returns
    Zero-based index of the matching item, or -1 when no match exists.
  • Method name
    IndexOf()
    Type
    Integer
    Description

    Return the zero-based index of the matching item.

    Declaration

    function IndexOf(const aOtherSheet: ISheet; aSkipId: Int64; var aRotated: Boolean): Integer; overload; safecall;

    C++ name: IndexOfByOther. The C++ header gives each Pascal overload its own name; the vtable slot is the same.

    Parameters
    aOtherSheetconst
    The other sheet interface instance to use.
    aSkipId
    Int64
    skip id value used to identify an object.
    aRotatedvar
    Boolean
    Boolean flag controlling rotated. Passed by reference and may be updated by the callee.
    Returns
    Zero-based index of the matching item, or -1 when no match exists.
  • Method name
    CreateDefect()
    Type
    ISheetDefect
    Description

    Create a new defect instance.

    Declaration

    function CreateDefect(): ISheetDefect; safecall;
    Returns
    A new sheet defect interface instance.
  • Method name
    GetById()
    Type
    ISheet
    Description

    Return the item stored under the specified TonCut identifier.

    Declaration

    function GetById(aId: Int64): ISheet; safecall;
    Parameters
    aId
    Int64
    TonCut object identifier.
    Returns
    The matching sheet interface instance.
  • Method name
    CalcMaxLength()
    Type
    Cardinal
    Description

    Calculate max length.

    Declaration

    function CalcMaxLength(): Cardinal; safecall;
    Returns
    The calculated max length value.
  • Method name
    BeginUpdate()
    Type
    procedure
    Description

    Start a batched update so change notifications can be delayed.

    Declaration

    procedure BeginUpdate(); safecall;
  • Method name
    EndUpdate()
    Type
    procedure
    Description

    Finish a batched update and allow deferred notifications to resume.

    Declaration

    procedure EndUpdate(); safecall;
  • Method name
    IsUpdating()
    Type
    Boolean
    Description

    Report whether the interface is currently inside an update batch.

    Declaration

    function IsUpdating(): Boolean; safecall;
    Returns
    Returns true while the interface is inside a BeginUpdate / EndUpdate batch.
  • Method name
    Reload()
    Type
    procedure
    Description

    Reload the underlying data from the host or storage layer.

    Declaration

    procedure Reload(); safecall;

ISheetChangeEventHandler

Callback sink consumed by the matching change-event interface.

IID
{F6388A56-8F89-4635-BFAC-BAA45913138B}
Parent
IUnknown
Unit
uISheetChangeEvent

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (1 methods, slots 3 to 3, after the three IUnknown slots)
  1. procedure Invoke(aSender: IUnknown; aSheet: ISheet; aIndex: Integer);

Methods

  • Method name
    Invoke()
    Type
    procedure
    Description

    Handle the event callback when the owning event interface invokes it.

    Declaration

    procedure Invoke(aSender: IUnknown; aSheet: ISheet; aIndex: Integer); safecall;
    Parameters
    aSender
    IUnknown
    Object that raised the event.
    aSheet
    Sheet instance being queried or modified.
    aIndex
    Integer
    Zero-based position within a collection.

ISheetChangeEvent

Event interface with Add, Remove, and Invoke hooks for collection or entity change notifications.

IID
{A740ABB2-3DA4-4DA8-904E-893B9AD65CFB}
Parent
IUnknown
Unit
uISheetChangeEvent

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (3 methods, slots 3 to 5, after the three IUnknown slots)
  1. procedure Add(aHandler: ISheetChangeEventHandler);
  2. procedure Remove(aHandler: ISheetChangeEventHandler);
  3. procedure Invoke(aSender: IUnknown; aSheet: ISheet; aIndex: Integer);

Methods

  • Method name
    Add()
    Type
    procedure
    Description

    Add an item or handler.

    Declaration

    procedure Add(aHandler: ISheetChangeEventHandler); safecall;
    Parameters
    aHandler
    The handler interface instance to use.
  • Method name
    Remove()
    Type
    procedure
    Description

    Remove an item or handler.

    Declaration

    procedure Remove(aHandler: ISheetChangeEventHandler); safecall;
    Parameters
    aHandler
    The handler interface instance to use.
  • Method name
    Invoke()
    Type
    procedure
    Description

    Raise the typed change event for the current payload.

    Declaration

    procedure Invoke(aSender: IUnknown; aSheet: ISheet; aIndex: Integer); safecall;
    Parameters
    aSender
    IUnknown
    Object that raised the event.
    aSheet
    Event payload field for sheet.
    aIndex
    Integer
    Event payload field for index.

ISheetDefect

Rectangular region tracked on a stock sheet, either a defect (damaged material) or a hole (no material), depending on the collection that holds it.

IID
{3F5E61BF-595F-4213-92C4-040A9F8949C2}
Parent
IUnknown (implicit: a Delphi interface without a parent is IUnknown)
Unit
uISheetDefect

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (12 methods, slots 3 to 14, after the three IUnknown slots)
  1. function GetPosX(): Cardinal;
  2. procedure SetPosX(aPosX: Cardinal);
  3. function GetPosY(): Cardinal;
  4. procedure SetPosY(aPosY: Cardinal);
  5. function GetLength(): Cardinal;
  6. procedure SetLength(aLength: Cardinal);
  7. function GetWidth(): Cardinal;
  8. procedure SetWidth(aWidth: Cardinal);
  9. function GetOnChange(): INotifyEvent;
  10. procedure Assign(const aSheetDefect: ISheetDefect);
  11. procedure BeginUpdate();
  12. procedure EndUpdate();

Properties

  • Property name
    PosX
    Type
    Cardinal
    Description

    X position of the object within solution space.

    Declaration

    property PosX: Cardinal read GetPosX write SetPosX;
  • Property name
    PosY
    Type
    Cardinal
    Description

    Y position of the object within solution space.

    Declaration

    property PosY: Cardinal read GetPosY write SetPosY;
  • Property name
    Length
    Type
    Cardinal
    Description

    Length value stored on the object.

    Declaration

    property Length: Cardinal read GetLength write SetLength;
  • Property name
    Width
    Type
    Cardinal
    Description

    Width value stored on the object.

    Declaration

    property Width: Cardinal read GetWidth write SetWidth;
  • Property name
    OnChange
    Type
    INotifyEvent
    Description

    Event fired when the object or collection changes.

    Declaration

    property OnChange: INotifyEvent read GetOnChange;

Methods

  • Method name
    Assign()
    Type
    procedure
    Description

    Copy values from another object of the same type.

    Declaration

    procedure Assign(const aSheetDefect: ISheetDefect); safecall;
    Parameters
    aSheetDefectconst
    The sheet defect interface instance to use.
  • Method name
    BeginUpdate()
    Type
    procedure
    Description

    Start a batched update so change notifications can be delayed.

    Declaration

    procedure BeginUpdate(); safecall;
  • Method name
    EndUpdate()
    Type
    procedure
    Description

    Finish a batched update and allow deferred notifications to resume.

    Declaration

    procedure EndUpdate(); safecall;

ISheetDefects

Collection of rectangular regions. The type is shared by ISheet.Defects (damaged material) and by Holes (no material), and the meaning differs between them.

IID
{0761BD5F-0F91-47E8-AA25-EDEFEEC7BEC4}
Parent
IUnknown (implicit: a Delphi interface without a parent is IUnknown)
Unit
uISheetDefects

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (11 methods, slots 3 to 13, after the three IUnknown slots)
  1. procedure Assign(const aOther: ISheetDefects);
  2. procedure Clear();
  3. procedure Add(aSheetDefect: ISheetDefect);
  4. procedure DeleteByIndex(aIndex: Cardinal);
  5. procedure Remove(const aSheetDefect: ISheetDefect);
  6. function IndexOf(const aSheetDefect: ISheetDefect): Integer; overload;
  7. function Find(aPosX, aPosY, aLength, aWidth: Cardinal): ISheetDefect; overload;
  8. function GetCount(): Integer;
  9. function GetByIndex(aIndex: Cardinal): ISheetDefect;
  10. function GetOnAdd(): ISheetDefectChangeEvent;
  11. function GetOnRemove(): ISheetDefectChangeEvent;

Properties

  • Property name
    Count
    Type
    Integer
    Description

    Number of items currently exposed by the interface.

    Declaration

    property Count: Integer read GetCount;
  • Property name
    Items
    Type
    ISheetDefect
    Description

    Indexed property used to read one item from the collection.

    Declaration

    property Items[aIndex: Cardinal]: ISheetDefect read GetByIndex; default;
    Index Parameters
    aIndex
    Cardinal
    Zero-based position within a collection.
    Value
    The collection item located at the supplied index.
  • Property name
    OnAdd
    Type
    ISheetDefectChangeEvent
    Description

    Event fired when an item is added.

    Declaration

    property OnAdd: ISheetDefectChangeEvent read GetOnAdd;
  • Property name
    OnRemove
    Type
    ISheetDefectChangeEvent
    Description

    Event fired when an item is removed.

    Declaration

    property OnRemove: ISheetDefectChangeEvent read GetOnRemove;

Methods

  • Method name
    Assign()
    Type
    procedure
    Description

    Copy values from another object of the same type.

    Declaration

    procedure Assign(const aOther: ISheetDefects); safecall;
    Parameters
    aOtherconst
    Source object whose values should be copied.
  • Method name
    Clear()
    Type
    procedure
    Description

    Remove all items from the collection.

    Declaration

    procedure Clear(); safecall;
  • Method name
    Add()
    Type
    procedure
    Description

    Add an item or handler.

    Declaration

    procedure Add(aSheetDefect: ISheetDefect); safecall;
    Parameters
    aSheetDefect
    The sheet defect interface instance to use.
  • Method name
    DeleteByIndex()
    Type
    procedure
    Description

    Delete the item at the specified zero-based index.

    Declaration

    procedure DeleteByIndex(aIndex: Cardinal); safecall;
    Parameters
    aIndex
    Cardinal
    Zero-based position within a collection.
  • Method name
    Remove()
    Type
    procedure
    Description

    Remove an item or handler.

    Declaration

    procedure Remove(const aSheetDefect: ISheetDefect); safecall;
    Parameters
    aSheetDefectconst
    The sheet defect interface instance to use.
  • Method name
    IndexOf()
    Type
    Integer
    Description

    Return the zero-based index of the matching item.

    Declaration

    function IndexOf(const aSheetDefect: ISheetDefect): Integer; overload; safecall;
    Parameters
    aSheetDefectconst
    The sheet defect interface instance to use.
    Returns
    Zero-based index of the matching item, or -1 when no match exists.
  • Method name
    Find()
    Type
    ISheetDefect
    Description

    Find an item matching the supplied criteria.

    Declaration

    function Find(aPosX: Cardinal; aPosY: Cardinal; aLength: Cardinal; aWidth: Cardinal): ISheetDefect; overload; safecall;
    Parameters
    aPosX
    Cardinal
    X position in solution space.
    aPosY
    Cardinal
    Y position in solution space.
    aLength
    Cardinal
    Length value in hundredths of a millimeter.
    aWidth
    Cardinal
    Width value in hundredths of a millimeter.
    Returns
    The matching sheet defect interface instance, or null when not found.

ISheetDefectChangeEventHandler

Callback sink consumed by the matching change-event interface.

IID
{E0280F1A-F065-4CDF-8AF6-99898C55BBD4}
Parent
IUnknown
Unit
uISheetDefectChangeEvent

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (1 methods, slots 3 to 3, after the three IUnknown slots)
  1. procedure Invoke(aSender: IUnknown; aSheetDefect: ISheetDefect; aIndex: Integer);

Methods

  • Method name
    Invoke()
    Type
    procedure
    Description

    Handle the event callback when the owning event interface invokes it.

    Declaration

    procedure Invoke(aSender: IUnknown; aSheetDefect: ISheetDefect; aIndex: Integer); safecall;
    Parameters
    aSender
    IUnknown
    Object that raised the event.
    aSheetDefect
    The sheet defect interface instance to use.
    aIndex
    Integer
    Zero-based position within a collection.

ISheetDefectChangeEvent

Event interface with Add, Remove, and Invoke hooks for collection or entity change notifications.

IID
{EF2DD7A4-1957-4C72-AC8F-EC6D6793E30D}
Parent
IUnknown
Unit
uISheetDefectChangeEvent

The SDK's language-support manifest lists no C++ member of this interface. If your TonCutPluginSdk.hpp leaves it opaque, declare the interface yourself in the vtable order below.

Vtable order (3 methods, slots 3 to 5, after the three IUnknown slots)
  1. procedure Add(aHandler: ISheetDefectChangeEventHandler);
  2. procedure Remove(aHandler: ISheetDefectChangeEventHandler);
  3. procedure Invoke(aSender: IUnknown; aSheetDefect: ISheetDefect; aIndex: Integer);

Methods

  • Method name
    Add()
    Type
    procedure
    Description

    Add an item or handler.

    Declaration

    procedure Add(aHandler: ISheetDefectChangeEventHandler); safecall;
    Parameters
    aHandler
    The handler interface instance to use.
  • Method name
    Remove()
    Type
    procedure
    Description

    Remove an item or handler.

    Declaration

    procedure Remove(aHandler: ISheetDefectChangeEventHandler); safecall;
    Parameters
    aHandler
    The handler interface instance to use.
  • Method name
    Invoke()
    Type
    procedure
    Description

    Raise the typed change event for the current payload.

    Declaration

    procedure Invoke(aSender: IUnknown; aSheetDefect: ISheetDefect; aIndex: Integer); safecall;
    Parameters
    aSender
    IUnknown
    Object that raised the event.
    aSheetDefect
    Event payload field for sheet defect.
    aIndex
    Integer
    Event payload field for index.

Was this page helpful?