Table of Contents

Class Thread

Namespace
Java.Lang
Assembly
MASES.Netdroid.dll
public class Thread : JVMBridgeBase<Thread>, IDynamicMetaObjectProvider, IJVMBridgeCore, IDisposable, IJVMBridgeBaseStatic, IJVMBridgeBase, IJVMBridgeDefinition
Inheritance
JVMBridgeBase
JVMBridgeBase<Thread>
Thread
Implements
IJVMBridgeCore
IJVMBridgeBaseStatic
IJVMBridgeBase
IJVMBridgeDefinition
Derived
Inherited Members
JVMBridgeBase<Thread>.IsAssignableFrom(IJavaType)
JVMBridgeBase<Thread>.IsAssignableFrom<T>()
JVMBridgeBase<Thread>.Execute<T>(params T[])
JVMBridgeBase<Thread>.DynBridgeClazz
JVMBridgeBase<Thread>.BridgeClazz
JVMBridgeBase.RuntimeClassNameOf<T>()
JVMBridgeBase.ClassNameOf<T>()
JVMBridgeBase.ClassOf<T>()
JVMBridgeBase.WrapsDirect<TNewClass>(IJavaObject)
JVMBridgeBase.Wraps<TNewClass>(IJavaObject)
JVMBridgeBase.Wraps<TNewClass, TReturn>(IJavaObject)
JVMBridgeBase.Wraps<TNewClass, TReturn, TConverter>(IJavaObject)
JVMBridgeBase.MonitorEnter()
JVMBridgeBase.MonitorExit()
JVMBridgeBase.IsInstanceOf(IJavaType)
JVMBridgeBase.IsInstanceOf<T>()
JVMBridgeBase.RuntimeIsInstanceOf<T>()
JVMBridgeBase.CastTo<TNewClass>()
JVMBridgeBase.CastDirect<TNewClass>()
JVMBridgeBase.Dispose()
JVMBridgeBase.ToString()
JVMBridgeBase.GetHashCode()
JVMBridgeBase.Notify()
JVMBridgeBase.NotifyAll()
JVMBridgeBase.Wait()
JVMBridgeBase.DynBridgeInstance
JVMBridgeBase.BridgeInstance
JVMBridgeBase.IsBridgeListener
Extension Methods

Constructors

Thread()

Default constructor: even if the corresponding Java class does not have one, it is mandatory for JCOBridge

public Thread()

Thread(Runnable)

public Thread(Runnable arg0)

Parameters

arg0 Runnable

Runnable

Thread(Runnable, String)

public Thread(Runnable arg0, String arg1)

Parameters

arg0 Runnable

Runnable

arg1 String

String

Thread(String)

public Thread(String arg0)

Parameters

arg0 String

String

Thread(ThreadGroup, Runnable)

public Thread(ThreadGroup arg0, Runnable arg1)

Parameters

arg0 ThreadGroup

ThreadGroup

arg1 Runnable

Runnable

Thread(ThreadGroup, Runnable, String)

public Thread(ThreadGroup arg0, Runnable arg1, String arg2)

Parameters

arg0 ThreadGroup

ThreadGroup

arg1 Runnable

Runnable

arg2 String

String

Thread(ThreadGroup, Runnable, String, long)

public Thread(ThreadGroup arg0, Runnable arg1, String arg2, long arg3)

Parameters

arg0 ThreadGroup

ThreadGroup

arg1 Runnable

Runnable

arg2 String

String

arg3 long

long

Thread(ThreadGroup, Runnable, String, long, bool)

public Thread(ThreadGroup arg0, Runnable arg1, String arg2, long arg3, bool arg4)

Parameters

arg0 ThreadGroup

ThreadGroup

arg1 Runnable

Runnable

arg2 String

String

arg3 long

long

arg4 bool

bool

Thread(ThreadGroup, String)

public Thread(ThreadGroup arg0, String arg1)

Parameters

arg0 ThreadGroup

ThreadGroup

arg1 String

String

Thread(params object[])

Generic constructor: it is useful for JCOBridge when there is a derived class which needs to pass arguments to the highest JVMBridgeBase class

public Thread(params object[] args)

Parameters

args object[]

Properties

BridgeClassName

public override string BridgeClassName { get; }

Property Value

string

IsBridgeAbstract

public override bool IsBridgeAbstract { get; }

Property Value

bool

IsBridgeCloseable

public override bool IsBridgeCloseable { get; }

Property Value

bool

IsBridgeInterface

public override bool IsBridgeInterface { get; }

Property Value

bool

IsBridgeStatic

public override bool IsBridgeStatic { get; }

Property Value

bool

MAX_PRIORITY

public static int MAX_PRIORITY { get; }

Property Value

int

MIN_PRIORITY

public static int MIN_PRIORITY { get; }

Property Value

int

NORM_PRIORITY

public static int NORM_PRIORITY { get; }

Property Value

int

Methods

ActiveCount()

public static int ActiveCount()

Returns

int

int

CheckAccess()

[Obsolete]
public void CheckAccess()

CountStackFrames()

[Obsolete]
public int CountStackFrames()

Returns

int

int

CurrentThread()

public static Thread CurrentThread()

Returns

Thread

Thread

DumpStack()

public static void DumpStack()

Enumerate(Thread[])

public static int Enumerate(Thread[] arg0)

Parameters

arg0 Thread[]

Thread

Returns

int

int

GetAllStackTraces()

public static Map<Thread, StackTraceElement[]> GetAllStackTraces()

Returns

Map<Thread, StackTraceElement[]>

Map

GetContextClassLoader()

public ClassLoader GetContextClassLoader()

Returns

ClassLoader

ClassLoader

GetId()

public long GetId()

Returns

long

long

GetName()

public String GetName()

Returns

String

String

GetPriority()

public int GetPriority()

Returns

int

int

GetStackTrace()

public StackTraceElement[] GetStackTrace()

Returns

StackTraceElement[]

StackTraceElement

GetState()

public Thread.State GetState()

Returns

Thread.State

Thread.State

GetThreadGroup()

public ThreadGroup GetThreadGroup()

Returns

ThreadGroup

ThreadGroup

HoldsLock(object)

public static bool HoldsLock(object arg0)

Parameters

arg0 object

object

Returns

bool

bool

Interrupt()

public void Interrupt()

Interrupted()

public static bool Interrupted()

Returns

bool

bool

IsAlive()

public bool IsAlive()

Returns

bool

bool

IsDaemon()

public bool IsDaemon()

Returns

bool

bool

IsInterrupted()

public bool IsInterrupted()

Returns

bool

bool

Join()

public void Join()

Exceptions

InterruptedException

Join(long)

public void Join(long arg0)

Parameters

arg0 long

long

Exceptions

InterruptedException

Join(long, int)

public void Join(long arg0, int arg1)

Parameters

arg0 long

long

arg1 int

int

Exceptions

InterruptedException

OnSpinWait()

public static void OnSpinWait()

Resume()

[Obsolete]
public void Resume()

Run()

public void Run()

SetContextClassLoader(ClassLoader)

public void SetContextClassLoader(ClassLoader arg0)

Parameters

arg0 ClassLoader

ClassLoader

SetDaemon(bool)

public void SetDaemon(bool arg0)

Parameters

arg0 bool

bool

SetName(String)

public void SetName(String arg0)

Parameters

arg0 String

String

SetPriority(int)

public void SetPriority(int arg0)

Parameters

arg0 int

int

SetUncaughtExceptionHandler(UncaughtExceptionHandler)

Set the handler invoked when this thread abruptly terminates due to an uncaught exception.

public void SetUncaughtExceptionHandler(Thread.UncaughtExceptionHandler eh)

Parameters

eh Thread.UncaughtExceptionHandler

The object to use as this thread's uncaught exception handler. If null then this thread has no explicit handler.

Sleep(long)

public static void Sleep(long arg0)

Parameters

arg0 long

long

Exceptions

InterruptedException

Sleep(long, int)

public static void Sleep(long arg0, int arg1)

Parameters

arg0 long

long

arg1 int

int

Exceptions

InterruptedException

Start()

public void Start()

Stop()

[Obsolete]
public void Stop()

Suspend()

[Obsolete]
public void Suspend()

Yield()

public static void Yield()

Operators

implicit operator Runnable(Thread)

Converter from Thread to Runnable

public static implicit operator Runnable(Thread t)

Parameters

t Thread

Returns

Runnable