Skip to content

slot_size

  • Return the number of bytes the object in the specified slot occupies when serialized
int64_t slot_size (
uint32_t slot_no
);
int64_t bytes_needed = slot_size(1); // get size of slot 1
NameTypeDescription
slot_nouint32_tThe slot number
TypeDescription
int64_t

The number of bytes the object occupies when serialized

If negative, an error:
DOESNT_EXIST
- the specified slot does not contain any object or it is an invalid slot