# NOT RUN {
callbackFunction <- function(x, iteration, timestep) {
print(paste0("Breakpoint hit: ", scenarioId(x)))
}
temp_dir <- tempdir()
myses <- session()
mylib <- ssimLibrary(name = file.path(temp_dir,"testlib"), session = myses)
myScenario <- scenario(mylib, "testScenario")
myScenario <- addBreakpoint(x= myScenario, transformerName= "stsim_Runtime", breakpointType = "bi",
arguments = c(1,2), callback = callbackFunction)
# }
Run the code above in your browser using DataLab