Ghidra 11.3.2
Ghidra internal decompiler documentation.
Loading...
Searching...
No Matches
ghidra::sla::FormatEncode Class Reference

The encoder for the .sla file format. More...

#include <slaformat.hh>

Inheritance diagram for ghidra::sla::FormatEncode:
[legend]
Collaboration diagram for ghidra::sla::FormatEncode:
[legend]

Public Member Functions

 FormatEncode (ostream &s, int4 level)
 Initialize an encoder at a specific compression level.
 
void flush (void)
 Flush any buffered bytes in the encoder to the backing stream.
 
- Public Member Functions inherited from ghidra::PackedEncode
 PackedEncode (ostream &s)
 Construct from a stream.
 
virtual void openElement (const ElementId &elemId)
 Begin a new element in the encoding.
 
virtual void closeElement (const ElementId &elemId)
 End the current element in the encoding.
 
virtual void writeBool (const AttributeId &attribId, bool val)
 Write an annotated boolean value into the encoding.
 
virtual void writeSignedInteger (const AttributeId &attribId, intb val)
 Write an annotated signed integer value into the encoding.
 
virtual void writeUnsignedInteger (const AttributeId &attribId, uintb val)
 Write an annotated unsigned integer value into the encoding.
 
virtual void writeString (const AttributeId &attribId, const string &val)
 Write an annotated string into the encoding.
 
virtual void writeStringIndexed (const AttributeId &attribId, uint4 index, const string &val)
 Write an annotated string, using an indexed attribute, into the encoding.
 
virtual void writeSpace (const AttributeId &attribId, const AddrSpace *spc)
 Write an address space reference into the encoding.
 
virtual void writeOpcode (const AttributeId &attribId, OpCode opc)
 Write a p-code operation opcode into the encoding, associating it with the given annotation.
 
- Public Member Functions inherited from ghidra::Encoder
virtual ~Encoder (void)
 Destructor.
 

Private Attributes

CompressBuffer compBuffer
 The compression stream filter.
 
ostream compStream
 The front-end stream receiving uncompressed bytes.
 

Detailed Description

The encoder for the .sla file format.

This provides the format header, does compression, and encodes the raw data elements/attributes.

Constructor & Destructor Documentation

◆ FormatEncode()

ghidra::sla::FormatEncode::FormatEncode ( ostream &  s,
int4  level 
)

Initialize an encoder at a specific compression level.

Parameters
sis the backing stream that will receive the final bytes of the .sla file
levelis the compression level

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