ScheduledThreadPoolExecutor 构造函数

定义

重载

名称 说明
ScheduledThreadPoolExecutor(Int32)

ScheduledThreadPoolExecutor使用给定的核心池大小创建新的池。

ScheduledThreadPoolExecutor(Int32, IRejectedExecutionHandler)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

ScheduledThreadPoolExecutor(Int32, IThreadFactory)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

ScheduledThreadPoolExecutor(IntPtr, JniHandleOwnership)

创建 JNI 对象的托管表示形式时使用的构造函数;由运行时调用。

ScheduledThreadPoolExecutor(Int32, IThreadFactory, IRejectedExecutionHandler)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

ScheduledThreadPoolExecutor(Int32)

ScheduledThreadPoolExecutor使用给定的核心池大小创建新的池。

[Android.Runtime.Register(".ctor", "(I)V", "")]
public ScheduledThreadPoolExecutor(int corePoolSize);
[<Android.Runtime.Register(".ctor", "(I)V", "")>]
new Java.Util.Concurrent.ScheduledThreadPoolExecutor : int -> Java.Util.Concurrent.ScheduledThreadPoolExecutor

参数

corePoolSize
Int32

要保留在池中的线程数,即使它们处于空闲状态,除非 allowCoreThreadTimeOut 已设置

属性

例外

如果 corePoolSize

注解

ScheduledThreadPoolExecutor使用给定的核心池大小创建新的池。

Java文档java.util.concurrent.ScheduledThreadPoolExecutor.ScheduledThreadPoolExecutor(int)

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于

ScheduledThreadPoolExecutor(Int32, IRejectedExecutionHandler)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

[Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/RejectedExecutionHandler;)V", "")]
public ScheduledThreadPoolExecutor(int corePoolSize, Java.Util.Concurrent.IRejectedExecutionHandler? handler);
[<Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/RejectedExecutionHandler;)V", "")>]
new Java.Util.Concurrent.ScheduledThreadPoolExecutor : int * Java.Util.Concurrent.IRejectedExecutionHandler -> Java.Util.Concurrent.ScheduledThreadPoolExecutor

参数

corePoolSize
Int32

要保留在池中的线程数,即使它们处于空闲状态,除非 allowCoreThreadTimeOut 已设置

handler
IRejectedExecutionHandler

由于达到线程边界和队列容量,因此阻止执行时使用的处理程序

属性

例外

如果 corePoolSize

如果 handler 为 null

注解

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

Java文档java.util.concurrent.ScheduledThreadPoolExecutor.ScheduledThreadPoolExecutor(int, java.util.concurrent.RejectedExecutionHandler)

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于

ScheduledThreadPoolExecutor(Int32, IThreadFactory)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

[Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/ThreadFactory;)V", "")]
public ScheduledThreadPoolExecutor(int corePoolSize, Java.Util.Concurrent.IThreadFactory? threadFactory);
[<Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/ThreadFactory;)V", "")>]
new Java.Util.Concurrent.ScheduledThreadPoolExecutor : int * Java.Util.Concurrent.IThreadFactory -> Java.Util.Concurrent.ScheduledThreadPoolExecutor

参数

corePoolSize
Int32

要保留在池中的线程数,即使它们处于空闲状态,除非 allowCoreThreadTimeOut 已设置

threadFactory
IThreadFactory

执行程序创建新线程时要使用的工厂

属性

例外

如果 corePoolSize

如果 threadFactory 为 null

注解

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

Java文档java.util.concurrent.ScheduledThreadPoolExecutor.ScheduledThreadPoolExecutor(int, java.util.concurrent.ThreadFactory)

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于

ScheduledThreadPoolExecutor(IntPtr, JniHandleOwnership)

创建 JNI 对象的托管表示形式时使用的构造函数;由运行时调用。

protected ScheduledThreadPoolExecutor(IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Java.Util.Concurrent.ScheduledThreadPoolExecutor : nativeint * Android.Runtime.JniHandleOwnership -> Java.Util.Concurrent.ScheduledThreadPoolExecutor

参数

javaReference
IntPtr

nativeint

IntPtr一个包含Java本机接口 (JNI) 对象引用。

transfer
JniHandleOwnership

指示 JniHandleOwnership如何处理 javaReference

注解

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于

ScheduledThreadPoolExecutor(Int32, IThreadFactory, IRejectedExecutionHandler)

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

[Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/ThreadFactory;Ljava/util/concurrent/RejectedExecutionHandler;)V", "")]
public ScheduledThreadPoolExecutor(int corePoolSize, Java.Util.Concurrent.IThreadFactory? threadFactory, Java.Util.Concurrent.IRejectedExecutionHandler? handler);
[<Android.Runtime.Register(".ctor", "(ILjava/util/concurrent/ThreadFactory;Ljava/util/concurrent/RejectedExecutionHandler;)V", "")>]
new Java.Util.Concurrent.ScheduledThreadPoolExecutor : int * Java.Util.Concurrent.IThreadFactory * Java.Util.Concurrent.IRejectedExecutionHandler -> Java.Util.Concurrent.ScheduledThreadPoolExecutor

参数

corePoolSize
Int32

要保留在池中的线程数,即使它们处于空闲状态,除非 allowCoreThreadTimeOut 已设置

threadFactory
IThreadFactory

执行程序创建新线程时要使用的工厂

handler
IRejectedExecutionHandler

由于达到线程边界和队列容量,因此阻止执行时使用的处理程序

属性

例外

如果 corePoolSize

如果为 null,则handlerthreadFactory null

注解

ScheduledThreadPoolExecutor使用给定的初始参数创建新的参数。

Java文档java.util.concurrent.ScheduledThreadPoolExecutor.ScheduledThreadPoolExecutor(int, java.util.concurrent.ThreadFactory, java.util.concurrent.RejectedExecutionHandler)

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于