IDA C++ SDK 9.2
Loading...
Searching...
No Matches
range_t Struct Reference

Base class for an range. More...

#include <range.hpp>

Inheritance diagram for range_t:
func_t hidden_range_t memory_info_t qbasic_block_t regvar_t scattered_segm_t segment_t sreg_range_t

Public Member Functions

 range_t (ea_t ea1=0, ea_t ea2=0)
 DECLARE_COMPARISONS (range_t)
 Compare two range_t instances, based on the start_ea.
bool contains (ea_t ea) const
 Is 'ea' in the address range?
bool contains (const range_t &r) const
 Is every ea in 'r' also in this range_t?
bool overlaps (const range_t &r) const
 Is there an ea in 'r' that is also in this range_t?
void clear ()
 Set start_ea, end_ea to 0.
bool empty () const
 Is the size of the range_t <= 0?
asize_t size () const
 Get end_ea - start_ea.
void intersect (const range_t &r)
 Assign the range_t to the intersection between the range_t and 'r'.
void extend (ea_t ea)
 Ensure that the range_t includes 'ea'.
size_t print (char *buf, size_t bufsize) const
 Print the range_t.

Public Attributes

ea_t start_ea
 start_ea included
ea_t end_ea
 end_ea excluded

Friends

size_t ida_export range_t_print (const range_t *cb, char *buf, size_t bufsize)
 Helper function. Should not be called directly!

Detailed Description

Base class for an range.

This class is used as a base class for a class with real information - see segment.hpp for example. The end address is excluded, it points past the range end.

Constructor & Destructor Documentation

◆ range_t()

range_t::range_t ( ea_t ea1 = 0,
ea_t ea2 = 0 )
inline

Member Function Documentation

◆ DECLARE_COMPARISONS()

range_t::DECLARE_COMPARISONS ( range_t )
inline

Compare two range_t instances, based on the start_ea.

◆ contains() [1/2]

bool range_t::contains ( ea_t ea) const
inline

Is 'ea' in the address range?

◆ contains() [2/2]

bool range_t::contains ( const range_t & r) const
inline

Is every ea in 'r' also in this range_t?

◆ overlaps()

bool range_t::overlaps ( const range_t & r) const
inline

Is there an ea in 'r' that is also in this range_t?

◆ clear()

void range_t::clear ( )
inline

Set start_ea, end_ea to 0.

◆ empty()

bool range_t::empty ( ) const
inline

Is the size of the range_t <= 0?

◆ size()

asize_t range_t::size ( ) const
inline

Get end_ea - start_ea.

◆ intersect()

void range_t::intersect ( const range_t & r)
inline

Assign the range_t to the intersection between the range_t and 'r'.

◆ extend()

void range_t::extend ( ea_t ea)
inline

Ensure that the range_t includes 'ea'.

◆ print()

size_t range_t::print ( char * buf,
size_t bufsize ) const
inline

Print the range_t.

Parameters
bufthe output buffer
bufsizethe size of the buffer

◆ range_t_print

size_t ida_export range_t_print ( const range_t * cb,
char * buf,
size_t bufsize )
friend

Helper function. Should not be called directly!

Member Data Documentation

◆ start_ea

ea_t range_t::start_ea

start_ea included

◆ end_ea

ea_t range_t::end_ea

end_ea excluded


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