compileToKotlin

fun SourceFile.compileToKotlin(fileName: String, packageName: String, backend: Backend, costRegime: SimpleCostRegime = SimpleCostRegime.WAN, saveLabelConstraintGraph: (graphWriter: (Writer) -> Unit) -> Unit? = null, saveInferredLabels: File? = null, saveEstimatedCost: File? = null, saveProtocolAssignment: File? = null): FileSpec

Compile this source file to a Kotlin program.

Supports writing intermediate results to files for debugging. To do so, set save parameters to a file name.

Parameters

backend

Cryptographic backends to use.

costRegime

Cost model to use for protocol selection.

saveLabelConstraintGraph

Output information flow constraint graph (in DOT format).

saveInferredLabels

Output program decorated with inferred information flow labels.

saveEstimatedCost

Output program decorated with estimated cost information.

saveProtocolAssignment

Output program decorated with selected protocols.