hasmer
Static Public Attributes | Properties | List of all members
Hasmer.HbcHeader Class Reference

Represents the header of a Hermes bytecode file. More...

Inheritance diagram for Hasmer.HbcHeader:
Hasmer.HbcEncodedItem

Static Public Attributes

const ulong HBC_MAGIC_HEADER = 0x1F1903C103BC1FC6
 The constant magic header that is present at the start of all Hermes bytecode files. More...
 

Properties

ulong Magic [get, set]
 The magic header of the file. This should be equal to HBC_MAGIC_HEADER. More...
 
uint Version [get, set]
 The Hermes bytecode version of the file. More...
 
byte[] SourceHash [get, set]
 A hex string representing the SHA1 hash of the original JavaScript source code that was compiled into Hermes bytecode. More...
 
uint FileLength [get, set]
 The total length in bytes of the bytecode file. More...
 
uint GlobalCodeIndex [get, set]
 The index in the functions table of the global function. More...
 
uint FunctionCount [get, set]
 The total amount of functions declared in the binary. More...
 
uint StringKindCount [get, set]
 
uint IdentifierCount [get, set]
 
uint StringCount [get, set]
 The amount of strings defined in the strings table. More...
 
uint OverflowStringCount [get, set]
 The amount of strings who have overflows (i.e. too long to be treated normally). More...
 
uint StringStorageSize [get, set]
 The total size in bytes of the raw string storage buffer. More...
 
uint? BigIntCount [get, set]
 
uint? BigIntStorageSize [get, set]
 
uint RegExpCount [get, set]
 
uint RegExpStorageSize [get, set]
 
uint ArrayBufferSize [get, set]
 The total size in bytes of the array buffer, where constant array data is stored. More...
 
uint ObjKeyBufferSize [get, set]
 The total size in bytes of the object key buffer, where constant object keys are stored. More...
 
uint ObjValueBufferSize [get, set]
 The total size in bytes of the object galue buffer, where constant object values are stored. More...
 
uint SegmentID [get, set]
 
uint CjsModuleOffset [get, set]
 
uint CjsModuleCount [get, set]
 
uint FunctionSourceCount [get, set]
 
uint DebugInfoOffset [get, set]
 The offset in the binary of debug information, if present. More...
 
HbcBytecodeOptions Options [get, set]
 The global options of the bytecode file, which are used by the Hermes runtime. More...
 
byte[] Padding [get, set]
 31 bytes of arbitrary padding. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Hasmer.HbcEncodedItem
static void WriteFromDefinition (HbcWriter writer, JToken def, object value)
 Writes a complex value given the definition and corresponding object. More...
 
static object ReadFromDefinition (HbcReader reader, JToken def)
 Reads a simple value given its definition. More...
 
static T Decode< T > (HbcReader reader, JObject obj)
 Reads a complex value from a stream given its definition. More...
 
static void Encode< T > (HbcWriter writer, JObject obj, T item)
 Encodes a complex value to a stream given its definition. More...
 

Detailed Description

Represents the header of a Hermes bytecode file.

Member Data Documentation

◆ HBC_MAGIC_HEADER

const ulong Hasmer.HbcHeader.HBC_MAGIC_HEADER = 0x1F1903C103BC1FC6
static

The constant magic header that is present at the start of all Hermes bytecode files.

Property Documentation

◆ ArrayBufferSize

uint Hasmer.HbcHeader.ArrayBufferSize
getset

The total size in bytes of the array buffer, where constant array data is stored.

◆ DebugInfoOffset

uint Hasmer.HbcHeader.DebugInfoOffset
getset

The offset in the binary of debug information, if present.

◆ FileLength

uint Hasmer.HbcHeader.FileLength
getset

The total length in bytes of the bytecode file.

◆ FunctionCount

uint Hasmer.HbcHeader.FunctionCount
getset

The total amount of functions declared in the binary.

◆ GlobalCodeIndex

uint Hasmer.HbcHeader.GlobalCodeIndex
getset

The index in the functions table of the global function.

◆ Magic

ulong Hasmer.HbcHeader.Magic
getset

The magic header of the file. This should be equal to HBC_MAGIC_HEADER.

◆ ObjKeyBufferSize

uint Hasmer.HbcHeader.ObjKeyBufferSize
getset

The total size in bytes of the object key buffer, where constant object keys are stored.

◆ ObjValueBufferSize

uint Hasmer.HbcHeader.ObjValueBufferSize
getset

The total size in bytes of the object galue buffer, where constant object values are stored.

◆ Options

HbcBytecodeOptions Hasmer.HbcHeader.Options
getset

The global options of the bytecode file, which are used by the Hermes runtime.

◆ OverflowStringCount

uint Hasmer.HbcHeader.OverflowStringCount
getset

The amount of strings who have overflows (i.e. too long to be treated normally).

◆ Padding

byte [] Hasmer.HbcHeader.Padding
getset

31 bytes of arbitrary padding.

◆ SourceHash

byte [] Hasmer.HbcHeader.SourceHash
getset

A hex string representing the SHA1 hash of the original JavaScript source code that was compiled into Hermes bytecode.

◆ StringCount

uint Hasmer.HbcHeader.StringCount
getset

The amount of strings defined in the strings table.

◆ StringStorageSize

uint Hasmer.HbcHeader.StringStorageSize
getset

The total size in bytes of the raw string storage buffer.

◆ Version

uint Hasmer.HbcHeader.Version
getset

The Hermes bytecode version of the file.


The documentation for this class was generated from the following file: