Bug 126915 Cleanup - Random serial version ID?
'Add serial version ID' has options 'Generated' and 'Random'. Is the random really just any random number? What would be the use case for this? AFAIK, the options of the quick fix are: - Default (1L) - Generated (only useful if serialized objects already exist) I would use labels with the descriptions above to help the user decide which one is appropriate for his use case.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/fix/PotentialProgrammingProblemsCleanUp.java
private ISerialVersionFixContext getContext() {
		if (isFlag(ADD_CALCULATED_SERIAL_VERSION_ID)) {
			return fContext;
		} else if (isFlag(ADD_DEFAULT_SERIAL_VERSION_ID)){
			return new ISerialVersionFixContext() {
				public long getSerialVersionId(String qualifiedName) throws CoreException {
					return 1;
				}
			};
		} else if (isFlag(ADD_RANDOM_SERIAL_VERSION_ID)) {
			return new ISerialVersionFixContext() {
				public long getSerialVersionId(String qualifiedName) throws CoreException {
					return RANDOM_NUMBER_GENERATOR.nextLong();
				}
				
			};
		}
		return null;
	}
	/**
	 * {@inheritDoc}
	 */
	public int maximalNumberOfFixes(CompilationUnit compilationUnit) {
		if (isFlag(ADD_CALCULATED_SERIAL_VERSION_ID) || isFlag(ADD_DEFAULT_SERIAL_VERSION_ID) || isFlag(ADD_RANDOM_SERIAL_VERSION_ID))
			return getNumberOfProblems(compilationUnit.getProblems(), IProblem.MissingSerialVersion);
		
		return 0;
	}
}