/ILSpy.BamlDecompiler/Ricciolo.StylesExplorer.MarkupReflection/BAML format.txt

http://github.com/icsharpcode/ILSpy · Plain Text · 22 lines · 11 code · 11 blank · 0 comment · 0 complexity · 6b4d8f9bb5cd87ce281daaeedb7c0447 MD5 · raw file

  1. BAML format description
  2. A BAML stream consists of a header and sequential records that contain the data.
  3. The Header
  4. The header is 28 bytes long. The first four bytes are a little endian integer containing the length of the preamble in bytes. The preamble is the UTF-16 string "MSBAML", followed by three integers with the value 0x60000.
  5. Record format:
  6. In general a record consists of a type byte and its content. Some records also have a field, following the type byte, containing the remaining length of the record, encoded as 7-bit encoded integer.
  7. Record Types:
  8. DocumentStart (= 0x01):
  9. The document start (after the type byte) is 6 Bytes long. Usually 00 FF FF FF FF 00. These bytes can be safely ignored.
  10. AssemblyInfo (= 0xC1):
  11. The length field is followed by a 2 byte long ID. The ID is followed by a string containing the assembly name.