Title
h

hackerham

01/27/2017, 12:12 PM
ok, then there's one small problem. CriticalStuff() cant return value that i use for fallback. I have to use external var
e

elizarov

01/27/2017, 12:13 PM
hackerham: I don't follow your problem. What exactly is the problem you are trying to solve?
h

hackerham

01/27/2017, 12:14 PM
var marker = AnswerContainer<StuffReturns>();
try { criticalStuff(marker); } 
catch (e: CancellationException) { criticalFallback(marker); }
e

elizarov

01/27/2017, 12:14 PM
Yes. You can do it that way
h

hackerham

01/27/2017, 12:15 PM
Is there a default wrapper that I can use ?
like java.util.Optional but without null
CriticalStuff() returns something, so I pass it wrapper where it will put the thing
ok, that's not related to Jobs anymore, thank you 🙂