I am using an integer ID in parts of my program, I want to ensure that the ID is an actual ID that I have returned. In a strongly typed language that also has a well fleshed out subtyping system, this would be trivial!
subtype AlbumID is long
The benefit of course would be that I could keep track of my AlbumID types and not have to worry about anything else!
Now the proper Java way is to make a new class called AlbumID that has a single long field and… bleck! I just want compile time checking darnit, I don’t need anything instantiated.