CONTENT CONTRACT · VERSION 1
Context
Frozen invocation context with checked integer helpers.
Signature
{ clamp: (SignedInt, SignedInt, SignedInt) -> SignedInt, div_floor: (SignedInt, SignedInt) -> SignedInt, event: E, event_id: OpaqueRef, format_int: (SignedInt) -> DisplayText, invocation_id: OpaqueRef, max: (SignedInt, SignedInt) -> SignedInt, min: (SignedInt, SignedInt) -> SignedInt, mul_div: (SignedInt, SignedInt, SignedInt) -> SignedInt, owner: OwnerRef, parameters: P, random_int: (Name, Count, SignedInt, SignedInt) -> SignedInt, read: Read }Fields
| Name | Type | Meaning |
|---|---|---|
clamp | (SignedInt, SignedInt, SignedInt) -> SignedInt | Clamp an integer to inclusive bounds. |
div_floor | (SignedInt, SignedInt) -> SignedInt | Checked integer division rounded toward negative infinity. |
event | E | Typed event payload selected by the script manifest. |
event_id | OpaqueRef | Stable ID of the originating committed event. Length: 1…256; Pattern: ^[\s\S]+$ |
format_int | (SignedInt) -> DisplayText | Format an exact integer without locale-dependent conversion. |
invocation_id | OpaqueRef | Stable ID for this handler invocation. Length: 1…256; Pattern: ^[\s\S]+$ |
max | (SignedInt, SignedInt) -> SignedInt | Return the larger integer. |
min | (SignedInt, SignedInt) -> SignedInt | Return the smaller integer. |
mul_div | (SignedInt, SignedInt, SignedInt) -> SignedInt | Checked multiply-then-divide using an exact integer intermediate. |
owner | OwnerRef | Resolved owner of this invocation. |
parameters | P | Exact parameter record from the selected content definition. |
random_int | (Name, Count, SignedInt, SignedInt) -> SignedInt | Deterministic named-stream draw with an explicit index and inclusive bounds. |
read | Read | Read-only functions over the frozen invocation snapshot. |