Why generate long serialVersionUID instead of a simple 1L?
问题 When class implements Serializable in Eclipse, I have two options: add default serialVersionUID(1L) or generated serialVersionUID(3567653491060394677L) . I think that first one is cooler, but many times I saw people using the second option. Is there any reason to generate long serialVersionUID ? 回答1: As far as I can tell, that would be only for compatibility with previous releases. This would only be useful if you neglected to use a serialVersionUID before, and then made a change that you