FQueuedThreadPool

Interface for queued thread pools.

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Misc/QueuedThreadPool.h

Include

#include "Misc/QueuedThreadPool.h"

Syntax

class FQueuedThreadPool

Remarks

Interface for queued thread pools.

This interface is used by all queued thread pools. It used as a callback by FQueuedThreads and is used to queue asynchronous work for callers.

Destructors

Name Description

Public function Virtual

~FQueuedThreadPool()

Virtual destructor.

Functions

Name Description

Public function

void

 

AddQueuedWork

(
    IQueuedWork* InQueuedWork
)

Checks to see if there is a thread available to perform the task.

Public function Static

FQueuedThrea...

 

Allocate()

Allocates a thread pool

Public function

bool

 

Create

(
    uint32 InNumQueuedThreads,
    uint32 StackSize,
    EThreadPriority ThreadPriority
)

Creates the thread pool with the specified number of threads

Public function

void

 

Destroy()

Tells the pool to clean up all background threads

Public function Const

int32

 

GetNumThreads()

Get the number of queued threads

Public function

bool

 

RetractQueuedWork

(
    IQueuedWork* InQueuedWork
)

Attempts to retract a previously queued task.

Constants

Name

Description

OverrideStackSize

Stack size for threads created for the thread pool.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss