Number is an abstract type in Java meant to be inherited by concrete subclasses. It does not have math operators; such operators are available in various instance implementations of subclasses. Being an abstract class in java means it cannot be instantiated and thus cannot exist as an actual object by itself.
I believe Number isn’t what you want. Instead, I’d recommend the Numeric typeclass, which is a reasonably useful generalization of numbers. Here’s an example.
The Number class does not have a “+” operator (nor an “add” method). You must use one of the Number.xyzValue() methods (such as intValue(), byteValue(), etc.) to cast/convert the Number to a specific numeric value, which then you can add together
Well, there’s no syntax sugar for it (the sugar only exists for the basic arithmetic operations) – you have to use the operation directly on the typeclass instead. Updated example.