JAR: JAM Axiomatic Reference

4.2. Service Account Types (§8)🔗

🔗structure
Jar.ServiceAccount : Type
Jar.ServiceAccount : Type

𝔸 : Service account. GP eq (9.3). A = ⟨s, p, l, f, c, b, g, m, i, r, a⟩

Contains code, storage, preimages, and gas configuration.

Constructor

Jar.ServiceAccount.mk

Fields

storage : Dict ByteArray ByteArray

s : Key-value storage. ⟨𝔹→𝔹⟩.

preimages : Dict Hash ByteArray

p : Preimage lookup. ⟨ℍ→𝔹⟩.

preimageInfo : Dict (Hash × Jar.BlobLength) (Array Jar.Timeslot)

l : Preimage request metadata. ⟨(ℍ, ℕ_L) → ⟦ℕ_T⟧_{:3}⟩.

gratis : Jar.Balance

f : Free (gratis) storage allowance. ℕ_B.

codeHash : Hash

c : Service code hash. ℍ.

balance : Jar.Balance

b : Account balance. ℕ_B.

minAccGas : Jar.Gas

g : Minimum accumulation gas. ℕ_G.

minOnTransferGas : Jar.Gas

m : Minimum on-transfer (memo) gas. ℕ_G.

itemCount : UInt32

a_i : Number of storage items. ℕ_I.

creationSlot : Jar.Timeslot

a_r : Creation timeslot. ℕ_T.

lastAccumulation : Jar.Timeslot

a_a : Most recent accumulation timeslot. ℕ_T.

parentServiceId : Nat

a_p : Parent service ID. ℕ_S.

totalFootprint : Nat

a_o : Total storage footprint in octets (computed). Preserved from serialized state.

🔗structure
Jar.PrivilegedServices : Type
Jar.PrivilegedServices : Type

χ : Privileged service identifiers. GP §9.4. χ = ⟨χ_M, χ_A, χ_V, χ_R, χ_Z⟩

Constructor

Jar.PrivilegedServices.mk

Fields

manager : Jar.ServiceId

χ_M : Manager (blessed) service. ℕ_S.

assigners : Array Jar.ServiceId

χ_A : Core assigner services. ⟦ℕ_S⟧_C.

designator : Jar.ServiceId

χ_V : Validator-set designator service. ℕ_S.

registrar : Jar.ServiceId

χ_R : Registrar service. ℕ_S.

alwaysAccumulate : Dict Jar.ServiceId Jar.Gas

χ_Z : Always-accumulate services with gas limits. ⟨ℕ_S → ℕ_G⟩.

🔗structure
Jar.DeferredTransfer : Type
Jar.DeferredTransfer : Type

𝕏 : Deferred transfer. GP eq (12.3). X = ⟨s, d, a, m, g⟩

Constructor

Jar.DeferredTransfer.mk

Fields

source : Jar.ServiceId

s : Source service. ℕ_S.

dest : Jar.ServiceId

d : Destination service. ℕ_S.

amount : Jar.Balance

a : Amount. ℕ_B.

memo : OctetSeq Jar.W_T

m : Memo. 𝔹_{W_T} (128 bytes).

gas : Jar.Gas

g : Gas limit for on-transfer. ℕ_G.