class Novika::BuiltinSnapshot

Overview

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.

Defined in:

novika/image.cr

Constant Summary

ENDIAN = ["big"]

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.

KLASS_NAME = [Novika::BuiltinSnapshot]

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.

PARTS = [{type: "string", name: id, cls: String, onlyif: nil, verify: nil, length: nil, value: nil, encoding: nil}] of Nil

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.

REMAINING = [] of Nil

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.

Constructors

Class Method Summary

Macro Summary

Instance Method Summary

Instance methods inherited from class Novika::Snapshot

to_form(assembler : BlockAssembler) to_form

Class methods inherited from class Novika::Snapshot

bit_fields bit_fields

Macros inherited from class Novika::Snapshot

novika_snapshot(name, onlyif = nil, verify = nil, value = nil) novika_snapshot

Constructor Detail

def self.new(form : Builtin) #

Class Method Detail

def self.bit_fields #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


Macro Detail

macro novika_block_ref_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_boolean_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_builtin_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_color_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_large_decimal_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_quote_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_quoted_word_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_small_decimal_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


macro novika_word_snapshot(name, onlyif = nil, verify = nil, value = nil) #

Snapshot of a builtin form.

Note: builtins aren't actually serialized, only their identifies are. Assuming the contract between the image emitter and image consumer is held, that builtin ids in capabilities are the same and unique -- this works.

But not builtins created dynamically! Such builtins are not easy nor safe to serialize.

TODO handle builtin serialization and/or provide serializable builtin factories.


Instance Method Detail

def __format__ : IO::ByteFormat #

def id : String #

Holds the 0-terminated unique identifier of this builtin.


def id=(id : String) #

Holds the 0-terminated unique identifier of this builtin.


def to_form(assembler) #