Top Fields Constructors Methods
com.sun.star.lib.uno.environments.remote

pack-priv final Class NativeThreadPool

extends Object
implements IThreadPool
Class Inheritance
All Implemented Interfaces
com.sun.star.lib.uno.environments.remote.IThreadPool

Field Summary

Modifier and TypeField and Description
private volatile Throwable
private final long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
attach()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

Attaches this thread to the thread pool.

public Object
attach(ThreadId id)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

As above, but hands in an already existing instance of the threadid of the current thread.

private static native void
attach(long pool)

private static native long
public void
destroy()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.destroy.

Destroys the thread pool and tries to join all created threads immediately.

private static native void
destroy(long pool)

public void
detach()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

Detaches this thread from the thread pool.

public void
detach(Object handle, ThreadId id)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

As above, but hands in an already existing instance of the threadid of the current thread and a handle returned by attach.

private static native void
detach(long pool)

public void
dispose(Throwable throwable)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.dispose.

Disposes this thread pool, thus releasing all threads by throwing a DisposedException with the given Throwable cause.

private static native void
dispose(long pool)

public Object
enter()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

Lets this thread enter the thread pool.

public Object
enter(Object handle, ThreadId id)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

As above but hands in an already existing instance of the threadid of the current thread and a handle returned by attach.

private static native Job
enter(long pool)

public ThreadId
getThreadId()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.getThreadId.

Retrieves the global threadId for the current thread.

public void
putJob(Job job)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.putJob.

Queues a job into the jobQueue of the thread belonging to the jobs threadId.

private static native void
putJob(long pool, byte[] threadId, Job job, boolean request, boolean oneWay)

private static native byte[]
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

disposeback to summary
private volatile Throwable dispose
poolback to summary
private final long pool

Constructor Detail

NativeThreadPoolback to summary
public NativeThreadPool()

Method Detail

attachback to summary
public void attach()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

Attaches this thread to the thread pool.

attachback to summary
public Object attach(ThreadId id)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.attach.

As above, but hands in an already existing instance of the threadid of the current thread.

The function exists for performance.

attachback to summary
private static native void attach(long pool)
createback to summary
private static native long create()
destroyback to summary
public void destroy()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.destroy.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.destroy.

Destroys the thread pool and tries to join all created threads immediately.

destroyback to summary
private static native void destroy(long pool)
detachback to summary
public void detach()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

Detaches this thread from the thread pool.

detachback to summary
public void detach(Object handle, ThreadId id)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.detach.

As above, but hands in an already existing instance of the threadid of the current thread and a handle returned by attach.

The function exists for performance.

detachback to summary
private static native void detach(long pool)
disposeback to summary
public void dispose(Throwable throwable)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.dispose.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.dispose.

Disposes this thread pool, thus releasing all threads by throwing a DisposedException with the given Throwable cause.

disposeback to summary
private static native void dispose(long pool)
enterback to summary
public Object enter() throws Throwable

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

Lets this thread enter the thread pool.

This thread then executes all jobs put via putJob until a reply job arrives.

enterback to summary
public Object enter(Object handle, ThreadId id) throws Throwable

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.enter.

As above but hands in an already existing instance of the threadid of the current thread and a handle returned by attach.

This thread then executes all jobs put via putJob until a reply job arrives.

enterback to summary
private static native Job enter(long pool)
getThreadIdback to summary
public ThreadId getThreadId()

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.getThreadId.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.getThreadId.

Retrieves the global threadId for the current thread.

putJobback to summary
public void putJob(Job job)

Implements com.sun.star.lib.uno.environments.remote.IThreadPool.putJob.

Doc from com.sun.star.lib.uno.environments.remote.IThreadPool.putJob.

Queues a job into the jobQueue of the thread belonging to the jobs threadId.

putJobback to summary
private static native void putJob(long pool, byte[] threadId, Job job, boolean request, boolean oneWay)
threadIdback to summary
private static native byte[] threadId()