I have a class like this:
private static class Num { private int val; public Num(int val) { this.val = val; } }
Is it
No, it is not possible, as Java doesn't support operator overloading.