V - public final class RunnableAdapter<V> extends Object implements IdentifiedDataSerializable, Callable<V>, HazelcastInstanceAware, PartitionAware
| Constructor and Description | 
|---|
RunnableAdapter()  | 
RunnableAdapter(Runnable task)  | 
| Modifier and Type | Method and Description | 
|---|---|
V | 
call()  | 
int | 
getFactoryId()
Returns DataSerializableFactory factory ID for this class. 
 | 
int | 
getId()
Returns type identifier for this class. 
 | 
Object | 
getPartitionKey()
The key that will be used by Hazelcast to specify the partition. 
 | 
Runnable | 
getRunnable()  | 
void | 
readData(ObjectDataInput in)
Reads fields from the input stream 
 | 
void | 
setHazelcastInstance(HazelcastInstance hazelcastInstance)
Gets the HazelcastInstance reference when submitting a Runnable/Callable using Hazelcast ExecutorService. 
 | 
void | 
setRunnable(Runnable runnable)  | 
String | 
toString()  | 
void | 
writeData(ObjectDataOutput out)
Writes object fields to output stream 
 | 
public RunnableAdapter()
public RunnableAdapter(Runnable task)
public Runnable getRunnable()
public void setRunnable(Runnable runnable)
public Object getPartitionKey()
PartitionAwaregetPartitionKey in interface PartitionAwarepublic void setHazelcastInstance(HazelcastInstance hazelcastInstance)
HazelcastInstanceAwaresetHazelcastInstance in interface HazelcastInstanceAwarehazelcastInstance - the HazelcastInstance referencepublic void writeData(ObjectDataOutput out) throws IOException
DataSerializablewriteData in interface DataSerializableout - outputIOException - if an I/O error occurs. In particular,
                     an IOException may be thrown if the
                     output stream has been closed.public void readData(ObjectDataInput in) throws IOException
DataSerializablereadData in interface DataSerializablein - inputIOException - if an I/O error occurs. In particular,
                     an IOException may be thrown if the
                     input stream has been closed.public int getFactoryId()
IdentifiedDataSerializablegetFactoryId in interface IdentifiedDataSerializablepublic int getId()
IdentifiedDataSerializablegetId in interface IdentifiedDataSerializableCopyright © 2020 Hazelcast, Inc.. All Rights Reserved.