略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: SplPriorityQueue::setExtractFlags

2024-12-21

SplPriorityQueue::setExtractFlags

(PHP 5 >= 5.3.0, PHP 7, PHP 8)

SplPriorityQueue::setExtractFlagsSets the mode of extraction

说明

public SplPriorityQueue::setExtractFlags(int $flags): int

参数

flags

Defines what is extracted by SplPriorityQueue::current(), SplPriorityQueue::top() and SplPriorityQueue::extract().

  • SplPriorityQueue::EXTR_DATA (0x00000001): Extract the data
  • SplPriorityQueue::EXTR_PRIORITY (0x00000002): Extract the priority
  • SplPriorityQueue::EXTR_BOTH (0x00000003): Extract an array containing both

The default mode is SplPriorityQueue::EXTR_DATA.

返回值

Returns the flags of extraction.

add a noteadd a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/splpriorityqueue.setextractflags.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3