when Policy.Execute ,must wrap
try{
Policy.Execute()...
}catch(Exception ex){}
flag=1;
if i am not wrap with try catch ,and "flag=1" never run;
if i want deal with the exception by myself?
@taomylife521 . The three reactive Policy types propagate handled exceptions out of the Policy as follows:
The wiki pages linked above for each Policy give more information.
For the cases when a policy rethrows an exception, you can either:
try / catch; or.ExecuteAndCapture(...) to capture the result of execution into a PolicyResult, and so avoid an extra try / catch.I'm not sure if this answers your question. Let us know if you need anything else?
Closing. Extra documentation PRd onto readme, in #458
Most helpful comment
@taomylife521 . The three reactive Policy types propagate handled exceptions out of the Policy as follows:
The wiki pages linked above for each Policy give more information.
For the cases when a policy rethrows an exception, you can either:
try/catch; or.ExecuteAndCapture(...)to capture the result of execution into aPolicyResult, and so avoid an extratry/catch.I'm not sure if this answers your question. Let us know if you need anything else?