# Uses of Interface
org.talend.transform.runtime.api.MapExecutionContext

## Uses of MapExecutionContext in org.talend.transform.runtime.api

Methods in org.talend.transform.runtime.api that return MapExecutionContext
Modifier and Type
Method
Description
`MapExecutionContext`
ExecutionStatus.`getMapExecutionContext()`
Returns the `MapExecutionContext` object associated with the execution of this map.
`MapExecutionContext`
RuntimeEngine.`getMapExecutionContext()`
Returns a map execution context which is optionally used when executing a map.
Methods in org.talend.transform.runtime.api with parameters of type MapExecutionContext
Modifier and Type
Method
Description
`InputStream`
MapRuntime.`getResultAsInputStream(MapExecutionContext ec)`
Returns an InputStream object that will execute the map and provide the result data.
`String`
MapRuntime.`getRuntimeCodeString(MapExecutionContext ec, boolean optimize)`
Returns the generated underlying engine runtime code associated with this map.
`String`
MapRuntime.`getRuntimeCodeString(MapExecutionContext ec, boolean compile, boolean optimize)`
Returns the generated underlying engine runtime code associated with this map.
`ExecutionStatus`
MapRuntime.`prepare(MapExecutionContext ec)`
Prepares the map for execution by validating it and compiling it.
`Source`
MessageAdaptor.`readMessage(MapExecutionContext ec, Class sourceClass, int sourceType, Object endpoint, Map<String,Object> properties)`
Reads a message with the given endpoint from the messaging system.
`ExecutionStatus`
MapOrStructRuntime.`run(MapExecutionContext ec)`
Executes this map or structure.
`void`
MapRuntime.`runAsync(MapExecutionContext ec)`
Executes the map in asynchronous mode one time.
`void`
MapRuntime.`runAsyncForever(MapExecutionContext ec)`
Executes the map in asynchronous mode until shutdown.
`ExecutionStatus`
MapOrStructRuntime.`validate(MapExecutionContext ec)`
`void`
MessageAdaptor.`writeMessageFinish(MapExecutionContext ec, Result result, Object endpoint, Map<String,Object> properties)`
Called when writing to the Result is finished for a message.
`void`
MessageAdaptor.`writeMessageProperties(MapExecutionContext ec, Map<String,Object> properties)`
Used to set the properties of the message being written.
`Result`
MessageAdaptor.`writeMessageStart(MapExecutionContext ec, Class resultClass, int resultType, Object endpoint, boolean waitForProperties, Map<String,Object> properties)`
Called before the writing is to begin on a message.