Suppose, for example, that you want to use
writeObject
and readObject
with Movie
instances. You
modify a Movie
definition, such as the definition shown in
Segment 251, by importing the java.io
package and
adding the Serializable
interface:
import java.io.*; public class Movie extends Attraction implements Serializable { // Remainder as in Segment 251 }