Class AddSerialVersion
- java.lang.Object
-
- com.ibm.wala.shrikeBT.shrikeCT.tools.AddSerialVersion
-
public class AddSerialVersion extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AddSerialVersion.SinkOutputStream
This class implements a stream that just discards everything written to it.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
addSerialVersionUID(ClassReader r, ClassWriter w)
This method computes the serialVersionUID for class r (if there isn't one already) and adds the field to the classwriter w.static long
computeSerialVersionUID(ClassReader r)
This method computes the serialVersionUID for class r.static void
main(String[] args)
-
-
-
Method Detail
-
addSerialVersionUID
public static void addSerialVersionUID(ClassReader r, ClassWriter w) throws InvalidClassFileException
This method computes the serialVersionUID for class r (if there isn't one already) and adds the field to the classwriter w. When run as a program, just takes a list of class files as command line arguments and computes their serialVersionUIDs.- Throws:
IllegalArgumentException
- if r is nullInvalidClassFileException
-
computeSerialVersionUID
public static long computeSerialVersionUID(ClassReader r) throws InvalidClassFileException
This method computes the serialVersionUID for class r. See the specification at http://java.sun.com/j2se/1.4.2/docs/guide/serialization/spec/class.html- Throws:
IllegalArgumentException
- if r is nullInvalidClassFileException
-
main
public static void main(String[] args)
-
-