Пространства имён
Варианты
Действия

std::priority_queue

Материал из cppreference.com

 
 
 
зЬй :: priority_queue
Член функций
Original:
Member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
priority_queue::priority_queue
priority_queue::~priority_queue
priority_queue::operator=
Элемент доступа
Original:
Element access
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
priority_queue::top
Потенциала
Original:
Capacity
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
priority_queue::empty
priority_queue::size
Модификаторы
Original:
Modifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
priority_queue::push
priority_queue::emplace
priority_queue::pop
priority_queue::swap
 
Заголовочный файл <queue>
template<

    class T,
    class Container = std::vector<T>,
    class Compare = std::less<typename Container::value_type>

> class priority_queue;
Приоритетные очереди является контейнером, который позволяет постоянное максимальное время (или минимальные, в зависимости от Compare) добыча за счет логарифмического вставки. Работа с priority_queue похоже на управление куча в некоторых случайных контейнеров доступа, благо не в состоянии случайно недействительным кучи.
Original:
Priority queue is a container that allows for constant time maximum (or minimum, depending on Compare) extraction at the expense of logarithmic insertion. Working with a priority_queue is similar to managing a куча in some random access container, with the benefit of not being able to accidentally invalidate the heap.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Содержание

[править] Член типов

Член типа
Original:
Member type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Definition
container_type Container [edit]
value_type Container::value_type [edit]
size_type Container::size_type [edit]
reference Container::reference [edit]
const_reference Container::const_reference [edit]

[править] Член функций

строит priority_queue
Original:
constructs the priority_queue
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(public функция-член) [edit]
destructs the priority_queue
(public функция-член) [edit]
Шаблон:tlist frontr
(public функция-член) [edit]
Элемент доступа
Original:
Element access
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
доступ к верхнему элементу
Original:
access the top element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(public функция-член) [edit]
Потенциала
Original:
Capacity
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
проверяет отсутствие элементов в контейенре, используемом для реализации
(public функция-член) [edit]
возвращает количество элементов
Original:
returns the number of elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(public функция-член) [edit]
Модификаторы
Original:
Modifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
вставляет элемент и сортирует базовый контейнер
(public функция-член) [edit]
(C++11)
конструирует элемент "на месте" и сортирует базовый контейнер
(public функция-член) [edit]
удаляет первый элемент
Original:
removes the first element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(public функция-член) [edit]
обмениевает содержимое
(public функция-член) [edit]

Член объектов
Original:
Member objects
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Container c
базового контейнера
Original:
the underlying container
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(protected объект-член) [edit]
Compare comp
объект функции сравнения
Original:
the comparison function object
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(protected объект-член)

[править] Не являющиеся членами функций

Специализируется std::swap алгоритм
Original:
specializes the std::swap algorithm
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон функции) [edit]

[править] Вспомогательные классы

Специализируется черта std::uses_allocator типа
Original:
specializes the std::uses_allocator type trait
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон функции) [edit]