summaryrefslogtreecommitdiff
path: root/jurt/com/sun/star/lib/uno/environments/remote
diff options
context:
space:
mode:
Diffstat (limited to 'jurt/com/sun/star/lib/uno/environments/remote')
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/IProtocol.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/IReceiver.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/IThreadPool.java10
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPool.java14
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPoolFactory.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/Job.java24
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/JobQueue.java60
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/Message.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/NativeThreadPool.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/ThreadId.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/ThreadPoolManager.java2
-rw-r--r--jurt/com/sun/star/lib/uno/environments/remote/remote_environment.java2
12 files changed, 62 insertions, 62 deletions
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/IProtocol.java b/jurt/com/sun/star/lib/uno/environments/remote/IProtocol.java
index 1fae45e9ca23..afb5fc586104 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/IProtocol.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/IProtocol.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/IReceiver.java b/jurt/com/sun/star/lib/uno/environments/remote/IReceiver.java
index be4548e5ebc0..402726188b18 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/IReceiver.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/IReceiver.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/IThreadPool.java b/jurt/com/sun/star/lib/uno/environments/remote/IThreadPool.java
index c70ccfa7e934..20017ed247e8 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/IThreadPool.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/IThreadPool.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -31,9 +31,9 @@ package com.sun.star.lib.uno.environments.remote;
* This interface is an abstraction of the various
* threadpool implementations.
* <p>
- * @version $Revision: 1.7 $ $ $Date: 2008-04-11 11:20:01 $
- * @author Joerg Budischewski
- * @author Kay Ramme
+ * @version $Revision: 1.7 $ $ $Date: 2008-04-11 11:20:01 $
+ * @author Joerg Budischewski
+ * @author Kay Ramme
* @see com.sun.star.lib.uno.environments.remote.ThreadPoolFactory
* @see com.sun.star.lib.uno.environments.remote.IThreadPoolFactory
* @since UDK1.0
@@ -101,7 +101,7 @@ public interface IThreadPool {
public Object enter( Object handle, ThreadId id ) throws Throwable;
/**
- * Queues a job into the jobQueue of the thread belonging
+ * Queues a job into the jobQueue of the thread belonging
* to the jobs threadId.
* <p>
* @param job the job
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPool.java b/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPool.java
index 3b1fee02b87d..4869d216c0c6 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPool.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPool.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -30,8 +30,8 @@ package com.sun.star.lib.uno.environments.remote;
/**
* This class implements a java thread pool.
* <p>
- * @version $Revision: 1.13 $ $ $Date: 2008-04-11 11:20:22 $
- * @author Kay Ramme
+ * @version $Revision: 1.13 $ $ $Date: 2008-04-11 11:20:22 $
+ * @author Kay Ramme
* @see com.sun.star.uno.UnoRuntime
* @see com.sun.star.lib.uno.environments.remote.ThreadPool
* @see com.sun.star.lib.uno.environments.remote.IThreadPool
@@ -66,7 +66,7 @@ public class JavaThreadPool implements IThreadPool {
jobQueue.acquire();
return jobQueue;
}
-
+
public void attach() {
attach( getThreadId() );
}
@@ -75,13 +75,13 @@ public class JavaThreadPool implements IThreadPool {
{
((JobQueue)handle).release();
}
-
+
public void detach() {
ThreadId threadId = getThreadId();
detach(_javaThreadPoolFactory.getJobQueue(threadId), threadId );
}
-
+
public Object enter( ) throws Throwable {
ThreadId threadId = getThreadId();
return enter( _javaThreadPoolFactory.getJobQueue( threadId ), threadId );
@@ -96,7 +96,7 @@ public class JavaThreadPool implements IThreadPool {
JobQueue jobQueue = _javaThreadPoolFactory.getJobQueue(job.getThreadId());
// this has not be synchronized, cause
- // sync jobs can only come over one bridge
+ // sync jobs can only come over one bridge
// (cause the thread blocks on other side)
if(jobQueue == null)
jobQueue = new JobQueue(_javaThreadPoolFactory, job.getThreadId(), true);
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPoolFactory.java b/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPoolFactory.java
index 868a4559a577..1ba1fc64179b 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPoolFactory.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/JavaThreadPoolFactory.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/Job.java b/jurt/com/sun/star/lib/uno/environments/remote/Job.java
index 41cf9706f2b6..ef99a187da7f 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/Job.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/Job.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -45,8 +45,8 @@ import com.sun.star.uno.XCurrentContext;
* The Job is an abstraction for tasks which have to be done
* remotely because of a method invocation.
* <p>
- * @version $Revision: 1.17 $ $ $Date: 2008-04-11 11:21:00 $
- * @author Kay Ramme
+ * @version $Revision: 1.17 $ $ $Date: 2008-04-11 11:21:00 $
+ * @author Kay Ramme
* @see com.sun.star.lib.uno.environments.remote.ThreadID
* @see com.sun.star.lib.uno.environments.remote.IReceiver
* @since UDK1.0
@@ -159,15 +159,15 @@ public class Job {
}
public void dispose() {
-// _oId = null;
-// _iReceiver = null;
-// _threadId = null;
-// _object = null;
-// _operation = null;
-// _param = null;
-// _exception = null;
-// _zInterface = null;
-// _disposeId = null;
+// _oId = null;
+// _iReceiver = null;
+// _threadId = null;
+// _object = null;
+// _operation = null;
+// _param = null;
+// _exception = null;
+// _zInterface = null;
+// _disposeId = null;
}
// The name of this method is chosen to generate a somewhat self-explanatory
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/JobQueue.java b/jurt/com/sun/star/lib/uno/environments/remote/JobQueue.java
index f7568a30cef7..b8700b61f5c3 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/JobQueue.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/JobQueue.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -34,11 +34,11 @@ package com.sun.star.lib.uno.environments.remote;
* at the <code>ThreadPool</code>.
* A JobQueue is splitted in a sync job queue and an async job queue.
* The sync job queue is the registerd queue, it delegates async jobs
- * (put by <code>putjob</code>) into the async queue, which is only
+ * (put by <code>putjob</code>) into the async queue, which is only
* known by the sync queue.
* <p>
- * @version $Revision: 1.19 $ $ $Date: 2008-04-11 11:21:18 $
- * @author Kay Ramme
+ * @version $Revision: 1.19 $ $ $Date: 2008-04-11 11:21:18 $
+ * @author Kay Ramme
* @see com.sun.star.lib.uno.environments.remote.ThreadPool
* @see com.sun.star.lib.uno.environments.remote.Job
* @see com.sun.star.lib.uno.environments.remote.ThreadID
@@ -88,7 +88,7 @@ public class JobQueue {
public void run() {
if(DEBUG) System.err.println("ThreadPool$JobDispatcher.run: " + Thread.currentThread());
-
+
try {
enter(2000, _disposeId);
}
@@ -104,14 +104,14 @@ public class JobQueue {
if(DEBUG) System.err.println("##### " + getClass().getName() + ".run - exit:" + _threadId);
-// try {
-// Object object = new Object();
-// synchronized(object) {
-// object.wait();
-// }
-// }
-// catch(InterruptedException interruptedException) {
-// }
+// try {
+// Object object = new Object();
+// synchronized(object) {
+// object.wait();
+// }
+// }
+// catch(InterruptedException interruptedException) {
+// }
}
}
@@ -151,7 +151,7 @@ public class JobQueue {
* @param createThread if true, the queue creates a worker thread if needed
* @see com.sun.star.lib.uno.environments.remote.ThreadID
*/
- JobQueue(JavaThreadPoolFactory javaThreadPoolFactory, ThreadId threadId, boolean createThread){
+ JobQueue(JavaThreadPoolFactory javaThreadPoolFactory, ThreadId threadId, boolean createThread){
_javaThreadPoolFactory = javaThreadPoolFactory;
_threadId = threadId;
_createThread = createThread;
@@ -172,7 +172,7 @@ public class JobQueue {
synchronized void acquire() {
// add only synchronous queues .
- if(_ref_count <= 0 && _sync_jobQueue == null )
+ if(_ref_count <= 0 && _sync_jobQueue == null )
_javaThreadPoolFactory.addJobQueue(this);
++ _ref_count;
@@ -183,7 +183,7 @@ public class JobQueue {
if(_ref_count <= 0) {
// only synchronous queues needs to be removed .
- if( _sync_jobQueue == null )
+ if( _sync_jobQueue == null )
_javaThreadPoolFactory.removeJobQueue(this);
@@ -198,7 +198,7 @@ public class JobQueue {
* Removes a job from the queue.
* <p>
* @return a job or null if timed out
- * @param waitTime the maximum amount of time to wait for a job
+ * @param waitTime the maximum amount of time to wait for a job
*/
private Job removeJob(int waitTime) throws Throwable {
if(DEBUG) System.err.println("##### " + getClass().getName() + ".removeJob:" + _head + " " + _threadId);
@@ -223,7 +223,7 @@ public class JobQueue {
catch(InterruptedException interruptedException) {
throw new com.sun.star.uno.RuntimeException(getClass().getName() + ".removeJob - unexpected:" + interruptedException);
}
-
+
// signal that we have already waited once
waited = true;
}
@@ -232,10 +232,10 @@ public class JobQueue {
if(_head != null) {
Job current = _head;
_head = _head._next;
-
+
if(_head == null)
_tail = null;
-
+
job = current;
_active = true;
}
@@ -243,7 +243,7 @@ public class JobQueue {
// always wait for asynchron jobqueue to be finished !
if(job != null && _async_jobQueue != null) {
- synchronized(_async_jobQueue) {
+ synchronized(_async_jobQueue) {
// wait for async queue to be empty and last job to be done
while(_async_jobQueue._active || _async_jobQueue._head != null) {
if(DEBUG) System.err.println("waiting for async:" + _async_jobQueue._head + " " + _async_jobQueue._worker_thread);
@@ -274,12 +274,12 @@ public class JobQueue {
*/
synchronized void putJob(Job job, Object disposeId) {
if(DEBUG) System.err.println("##### " + getClass().getName() + ".putJob todoes: " + " job:" + job);
-
- if(_tail != null)
+
+ if(_tail != null)
_tail._next = job;
else
_head = job;
-
+
_tail = job;
if(_worker_thread == null && _createThread && _createThread_now) { // if there is no thread, which dispatches and if shall create one, create one
@@ -326,10 +326,10 @@ public class JobQueue {
while(!quit) {
Job job = null;
-
+
try {
job = removeJob(waitTime);
-
+
if(job != null) {
try {
result = job.execute();
@@ -349,7 +349,7 @@ public class JobQueue {
else
quit = true;
-
+
}
finally { // ensure that this queue becomes disposed, if necessary
if(DEBUG) System.err.println("##### " + getClass().getName() + ".enter leaving: " + _threadId + " " + _worker_thread + " " + hold_worker_thread + " " + result);
@@ -359,7 +359,7 @@ public class JobQueue {
_worker_thread = hold_worker_thread;
_createThread_now = true;
-
+
_disposeId = hold_disposeId;
if(_sync_jobQueue != null)
@@ -385,10 +385,10 @@ public class JobQueue {
if(_sync_jobQueue == null) { // dispose only sync queues
_doDispose = disposeId;
_throwable = throwable;
-
+
// get thread out of wait and let it throw the throwable
if(DEBUG) System.err.println(getClass().getName() + ".dispose - notifying thread");
-
+
notifyAll();
}
}
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/Message.java b/jurt/com/sun/star/lib/uno/environments/remote/Message.java
index 918b9b1282ad..310bfc6ce488 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/Message.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/Message.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/NativeThreadPool.java b/jurt/com/sun/star/lib/uno/environments/remote/NativeThreadPool.java
index 06afce7f1e5d..91f0bd411ee8 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/NativeThreadPool.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/NativeThreadPool.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/ThreadId.java b/jurt/com/sun/star/lib/uno/environments/remote/ThreadId.java
index 0b570991c11f..e194198d8397 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/ThreadId.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/ThreadId.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/ThreadPoolManager.java b/jurt/com/sun/star/lib/uno/environments/remote/ThreadPoolManager.java
index 6187eb4b1c4e..c43ec4bad66d 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/ThreadPoolManager.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/ThreadPoolManager.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
diff --git a/jurt/com/sun/star/lib/uno/environments/remote/remote_environment.java b/jurt/com/sun/star/lib/uno/environments/remote/remote_environment.java
index 0a782783c00f..81cbf1bc4622 100644
--- a/jurt/com/sun/star/lib/uno/environments/remote/remote_environment.java
+++ b/jurt/com/sun/star/lib/uno/environments/remote/remote_environment.java
@@ -1,7 +1,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite