org.codehaus.gpars

groovyx.gpars.serial
[Java] Class SerialContext

java.lang.Object
  groovyx.gpars.serial.SerialContext

public abstract class SerialContext

Authors:
Alex Tkachman


Field Summary
protected java.util.UUID hostId

protected SerialHandles localHost

private static java.lang.ThreadLocal threadContext

 
Constructor Summary
SerialContext(SerialHandles localHost, java.util.UUID hostId)

 
Method Summary
void add(SerialHandle serialHandle)

void enter()

Enter to the context

void finalizeHandle(SerialHandle handle)

static SerialContext get()

SerialHandle get(java.util.UUID id)

java.util.UUID getHostId()

java.util.UUID getLocalHostId()

SerialContext getSerialHost(java.util.UUID hostId, java.lang.Object attachment)

void leave()

Leave this context

void remove(SerialHandle serialHandle)

void write(SerialMsg msg)

 
Methods inherited from class java.lang.Object
java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#wait(long, int), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Field Detail

hostId

protected final java.util.UUID hostId


localHost

protected final SerialHandles localHost


threadContext

private static final java.lang.ThreadLocal threadContext


 
Constructor Detail

SerialContext

public SerialContext(SerialHandles localHost, java.util.UUID hostId)


 
Method Detail

add

public void add(SerialHandle serialHandle)


enter

public final void enter()
Enter to the context


finalizeHandle

public void finalizeHandle(SerialHandle handle)


get

public static SerialContext get()


get

public SerialHandle get(java.util.UUID id)


getHostId

public java.util.UUID getHostId()


getLocalHostId

public java.util.UUID getLocalHostId()


getSerialHost

public SerialContext getSerialHost(java.util.UUID hostId, java.lang.Object attachment)


leave

public final void leave()
Leave this context


remove

public void remove(SerialHandle serialHandle)


write

public void write(SerialMsg msg)


 

Copyright © 2008–2012 Václav Pech. All Rights Reserved.