| OpendTect 8.0

Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | List of all members
SortedTable< IDT, T > Class Template Reference
Algo

A SortedTable keeps track of ids and their corresponding values. Each id can only be present once. More...

`#include <sortedtable.h>`

Inheritance diagram for SortedTable< IDT, T >:
[legend]

## Public Types
typedef T | object_type
typedef int | size_type

## Public Member Functions
| SortedTable ()
void | erase ()
bool | get (IDT id, T &val) const
const IDT & | id (size_type idx) const
bool | remove (IDT id)
void | set (IDT id, T val)
size_type | size () const
const T & | val (size_type idx) const

## Private Attributes
SortedList< IDT > | ids_
TypeSet< T > | vals_

## Detailed Description

template<class IDT, class T>
class SortedTable< IDT, T >

A SortedTable keeps track of ids and their corresponding values. Each id can only be present once.

<>

## Member Typedef Documentation

## ◆ object_type

template<class IDT , class T >

typedef T SortedTable< IDT, T >::object_type

## ◆ size_type

template<class IDT , class T >

typedef int SortedTable< IDT, T >::size_type

## Constructor & Destructor Documentation

## ◆ SortedTable()

template<class IDT , class T >

SortedTable< IDT, T >::SortedTable | ( |  | ) |
| inline

## Member Function Documentation

## ◆ erase()

template<class IDT , class T >

void SortedTable< IDT, T >::erase | ( |  | ) |
| inline

## ◆ get()

template<class IDT , class T >

bool SortedTable< IDT, T >::get | ( | IDT | id,
|  | T & | val ) const
| inline

If id is not found, val is unchanged and false is returned. If id is found, val is set and true is returned.

## ◆ id()

template<class IDT , class T >

const IDT & SortedTable< IDT, T >::id | ( | size_type | idx | ) | const
| inline

## ◆ remove()

template<class IDT , class T >

bool SortedTable< IDT, T >::remove | ( | IDT | id | ) |
| inline

## ◆ set()

template<class IDT , class T >

void SortedTable< IDT, T >::set | ( | IDT | id,
|  | T | val )
| inline

## ◆ size()

template<class IDT , class T >

size_type SortedTable< IDT, T >::size | ( |  | ) | const
| inline

## ◆ val()

template<class IDT , class T >

const T & SortedTable< IDT, T >::val | ( | size_type | idx | ) | const
| inline

## Member Data Documentation

## ◆ ids_

template<class IDT , class T >

SortedList<IDT> SortedTable< IDT, T >::ids_
| private

## ◆ vals_

template<class IDT , class T >

TypeSet<T> SortedTable< IDT, T >::vals_
| private

Generated at
for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2025