Remote System Explorer DataStore
Release 3.3

org.eclipse.dstore.core.server
Class SecuredThread

java.lang.Object
  extended by java.lang.Thread
      extended by org.eclipse.dstore.core.server.SecuredThread
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
Handler, MinerThread, Receiver

public class SecuredThread
extends Thread

Since:
3.0

Field Summary
 DataStore _dataStore
           
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
SecuredThread()
          Constructs a new SecuredThread without a DataStore.
SecuredThread(DataStore dataStore)
          Constructs a new SecuredThread given a DataStore.
SecuredThread(Runnable runnable, DataStore dataStore)
          Constructs a new SecuredThread with a DataStore and a runnable.
SecuredThread(Runnable runnable, String threadName, DataStore dataStore)
          Constructs a new SecuredThread with a DataStore, a runnable and name for the thread.
SecuredThread(ThreadGroup group, Runnable runnable, DataStore dataStore)
          Constructs a new SecuredThread with a DataStore, a runnable and a ThreadGroup.
SecuredThread(ThreadGroup group, Runnable runnable, String threadName, DataStore dataStore)
          Constructs a new SecuredThread with a DataStore, a runnable, a name and a ThreadGroup.
 
Method Summary
 void run()
          When run() is called, a check is made to see if there is an ISystemService.
 void setDataStore(DataStore dataStore)
          Sets the DataStore associated with the client
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_dataStore

public DataStore _dataStore
Constructor Detail

SecuredThread

public SecuredThread()
Constructs a new SecuredThread without a DataStore. In this case, the DataStore needs to be set sometime after creation via setDataStore(DataStore).


SecuredThread

public SecuredThread(DataStore dataStore)
Constructs a new SecuredThread given a DataStore.

Parameters:
dataStore - used to extract user id and password for a client

SecuredThread

public SecuredThread(Runnable runnable,
                     DataStore dataStore)
Constructs a new SecuredThread with a DataStore and a runnable. After the thread starts, the runnable will be implicitly executed.

Parameters:
runnable - the runnable to be executed by the thread
dataStore - used to extract user id and password for a client

SecuredThread

public SecuredThread(Runnable runnable,
                     String threadName,
                     DataStore dataStore)
Constructs a new SecuredThread with a DataStore, a runnable and name for the thread. After the thread starts, the runnable will be implicitly executed.

Parameters:
runnable - the runnable to be executed by the thread
threadName - the name for the SecuredThread being created
dataStore - used to extract user id and password for a client

SecuredThread

public SecuredThread(ThreadGroup group,
                     Runnable runnable,
                     DataStore dataStore)
Constructs a new SecuredThread with a DataStore, a runnable and a ThreadGroup. After the thread starts, the runnable will be implicitly executed.

Parameters:
group - the thread group for which this thread will belong
runnable - the runnable to be executed by the thread
dataStore - used to extract user id and password for a client

SecuredThread

public SecuredThread(ThreadGroup group,
                     Runnable runnable,
                     String threadName,
                     DataStore dataStore)
Constructs a new SecuredThread with a DataStore, a runnable, a name and a ThreadGroup. After the thread starts, the runnable will be implicitly executed.

Parameters:
group - the thread group for which this thread will belong
runnable - the runnable to be executed by the thread
threadName - the name for the SecuredThread being created
dataStore - used to extract user id and password for a client
Method Detail

setDataStore

public void setDataStore(DataStore dataStore)
Sets the DataStore associated with the client

Parameters:
dataStore -

run

public void run()
When run() is called, a check is made to see if there is an ISystemService. If there is the ISystemService.setThreadSecurity(Client) is called before Thread.run() is called. If a Runnable was passed into the constructor for SecuredThread then, when Thread.run() is called, the Runnable will be invoked.

Specified by:
run in interface Runnable
Overrides:
run in class Thread

Remote System Explorer DataStore
Release 3.3

Copyright (c) IBM Corporation and others 2000, 2011. All Rights Reserved.