corda / net.corda.core.flows / FlowLogicRefFactory

# FlowLogicRefFactory

`class FlowLogicRefFactory : SingletonSerializeAsToken`

A class for conversion to and from FlowLogic and FlowLogicRef instances.

Validation of types is performed on the way in and way out in case this object is passed between JVMs which might have differing whitelists.

TODO: Ways to populate whitelist of "blessed" flows per node/party TODO: Ways to populate argument types whitelist. Per node/party or global? TODO: Align with API related logic for passing in FlowLogic references (FlowRef) TODO: Actual support for AppContext / AttachmentsClassLoader

### Constructors

<init> | `FlowLogicRefFactory()``FlowLogicRefFactory(flowWhitelist: Map<String, Set<String>>)` A class for conversion to and from FlowLogic and FlowLogicRef instances.

### Functions

create | `fun create(type: Class<out FlowLogic<*>>, vararg args: Any?): FlowLogicRef` Create a FlowLogicRef by matching against the available constructors and the given args.
createKotlin | `fun createKotlin(flowLogicClassName: String, args: Map<String, Any?>, attachments: List<SecureHash> = emptyList()): FlowLogicRef` Create a FlowLogicRef for the Kotlin primary constructor of a named FlowLogic `fun createKotlin(type: Class<out FlowLogic<*>>, args: Map<String, Any?>): FlowLogicRef` Create a FlowLogicRef by trying to find a Kotlin constructor that matches the given args.
toFlowLogic | `fun toFlowLogic(ref: FlowLogicRef): FlowLogic<*>`

### Inherited Functions

toToken | `open fun toToken(context: SerializeAsTokenContext): SerializationToken`