In Java I would declare a function like this:
public boolean Test(boolean test) throws Exception { if (test == true) return false; throw new Excepti
It is not possible at this moment. You can check out this requested feature: https://github.com/microsoft/TypeScript/issues/13219