X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.scl.runtime%2Fscl%2FAsync.scl;h=1988eb5319eebb2c29ed9fa27e2589c766b56f6b;hp=9ff397f19cdf2fec1a89dc2c933598d2c5678133;hb=3bf1cf8f931ff10ea17f0c92b94cc49eb42d07d2;hpb=c67ea430c37864915660dad647b086bfa29c7491 diff --git a/bundles/org.simantics.scl.runtime/scl/Async.scl b/bundles/org.simantics.scl.runtime/scl/Async.scl index 9ff397f19..1988eb531 100644 --- a/bundles/org.simantics.scl.runtime/scl/Async.scl +++ b/bundles/org.simantics.scl.runtime/scl/Async.scl @@ -1,3 +1,18 @@ +import "Future" + +importJava "java.util.concurrent.TimeUnit" where + data TimeUnit + NANOSECONDS :: TimeUnit + MICROSECONDS :: TimeUnit + MILLISECONDS :: TimeUnit + SECONDS :: TimeUnit + HOURS :: TimeUnit + DAYS :: TimeUnit + importJava "org.simantics.scl.runtime.utils.AsyncUtils" where runAsync :: ( a) -> () - pmap :: (a -> b) -> [a] -> [b] + pmap :: (a -> b) -> [a] -> [b] + + scheduleAtFixedRate :: ( a) -> Long -> Long -> TimeUnit -> Future a + scheduleWithFixedDelay :: ( a) -> Long -> Long -> TimeUnit -> Future a + schedule :: ( a) -> Long -> TimeUnit -> Future a \ No newline at end of file