EffectPriorityScheduler Class
Namespace: Stride.Shaders.CompilerAssembly: Stride.Shaders.dll
A System.Threading.Tasks.TaskScheduler with control over concurrency and priority, useful with EffectCompilerCache.
System.Object → System.Threading.Tasks.TaskScheduler →
EffectPriorityScheduler
Derived from EffectPriorityScheduler:
public class EffectPriorityScheduler : TaskScheduler, IDisposable
Name | Description | |
---|---|---|
Constructors | ||
EffectPriorityScheduler(ThreadPriority, Int32) | ||
Properties | ||
MaximumConcurrencyLevel | ||
QueuedTaskCount | ||
Methods | ||
Dispose() | ||
GetOrCreatePriorityGroup(Int32) | Gets the or create a task scheduler for the given priority. |
|
GetScheduledTasks() | ||
QueueTask(Task) | ||
TryExecuteTaskInline(Task, Boolean) |
Constructors
EffectPriorityScheduler(ThreadPriority, Int32)
public EffectPriorityScheduler(ThreadPriority threadPriority, int maximumConcurrencyLevel)
Parameters
Type | Name | Description |
---|---|---|
System.Threading.ThreadPriority | threadPriority | |
System.Int32 | maximumConcurrencyLevel |
Properties
MaximumConcurrencyLevel
public override int MaximumConcurrencyLevel { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Overrides
System.Threading.Tasks.TaskScheduler.MaximumConcurrencyLevel
QueuedTaskCount
public int QueuedTaskCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Methods
Dispose()
public void Dispose()
GetOrCreatePriorityGroup(Int32)
Gets the or create a task scheduler for the given priority.
public TaskScheduler GetOrCreatePriorityGroup(int priority)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | priority | The priority. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.TaskScheduler |
GetScheduledTasks()
protected override IEnumerable<Task> GetScheduledTasks()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<System.Threading.Tasks.Task> |
Overrides
System.Threading.Tasks.TaskScheduler.GetScheduledTasks()
QueueTask(Task)
protected override void QueueTask(Task task)
Parameters
Type | Name | Description |
---|---|---|
System.Threading.Tasks.Task | task |
Overrides
System.Threading.Tasks.TaskScheduler.QueueTask(System.Threading.Tasks.Task)
TryExecuteTaskInline(Task, Boolean)
protected override bool TryExecuteTaskInline(Task task, bool taskWasPreviouslyQueued)
Parameters
Type | Name | Description |
---|---|---|
System.Threading.Tasks.Task | task | |
System.Boolean | taskWasPreviouslyQueued |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
System.Threading.Tasks.TaskScheduler.TryExecuteTaskInline(System.Threading.Tasks.Task, System.Boolean)
Inherited Members
System.Threading.Tasks.TaskScheduler.FromCurrentSynchronizationContext()
System.Threading.Tasks.TaskScheduler.TryDequeue(System.Threading.Tasks.Task)
System.Threading.Tasks.TaskScheduler.TryExecuteTask(System.Threading.Tasks.Task)
System.Threading.Tasks.TaskScheduler.Current
System.Threading.Tasks.TaskScheduler.Default
System.Threading.Tasks.TaskScheduler.Id
System.Threading.Tasks.TaskScheduler.UnobservedTaskException