Ghidra 11.3.2
Ghidra internal decompiler documentation.
Loading...
Searching...
No Matches
ghidra::QualifierFilter Class Referenceabstract

A filter on some aspect of a specific function prototype. More...

#include <modelrules.hh>

Inheritance diagram for ghidra::QualifierFilter:
[legend]

Public Member Functions

virtual ~QualifierFilter (void)
 Destructor.
 
virtual QualifierFilterclone (void) const =0
 Make a copy of this qualifier.
 
virtual bool filter (const PrototypePieces &proto, int4 pos) const =0
 Test whether the given function prototype meets this filter's criteria.
 
virtual void decode (Decoder &decoder)
 Configure details of the criteria being filtered from the given stream.
 

Static Public Member Functions

static QualifierFilterdecodeFilter (Decoder &decoder)
 Try to instantiate a qualifier filter.
 

Detailed Description

A filter on some aspect of a specific function prototype.

An instance is configured via the decode() method, then a test of whether a function prototype meets its criteria can be performed by calling its filter() method.

Member Function Documentation

◆ clone()

virtual QualifierFilter * ghidra::QualifierFilter::clone ( void  ) const
pure virtual

Make a copy of this qualifier.

Returns
the newly allocated copy

Implemented in ghidra::AndFilter, ghidra::VarargsFilter, ghidra::PositionMatchFilter, and ghidra::DatatypeMatchFilter.

Referenced by ghidra::ModelRule::ModelRule().

◆ decode()

virtual void ghidra::QualifierFilter::decode ( Decoder decoder)
inlinevirtual

Configure details of the criteria being filtered from the given stream.

Parameters
decoderis the given stream decoder

Reimplemented in ghidra::AndFilter, ghidra::VarargsFilter, ghidra::PositionMatchFilter, and ghidra::DatatypeMatchFilter.

◆ decodeFilter()

QualifierFilter * ghidra::QualifierFilter::decodeFilter ( Decoder decoder)
static

Try to instantiate a qualifier filter.

If the next element is a qualifier filter, decode it from the stream and return it. Otherwise return null

Parameters
decoderis the given stream decoder
Returns
the new qualifier instance or null

References filter(), and ghidra::Decoder::peekElement().

Referenced by ghidra::ModelRule::decode().

◆ filter()

virtual bool ghidra::QualifierFilter::filter ( const PrototypePieces proto,
int4  pos 
) const
pure virtual

Test whether the given function prototype meets this filter's criteria.

Parameters
protois the high-level description of the function prototype to test
posis the position of a specific output (pos=-1) or input (pos >=0) in context
Returns
true if the prototype meets the criteria, false otherwise

Implemented in ghidra::AndFilter, ghidra::VarargsFilter, ghidra::PositionMatchFilter, and ghidra::DatatypeMatchFilter.

Referenced by ghidra::ModelRule::assignAddress(), and decodeFilter().


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