Hi Saheed,
The Magic Cookie identifies that the file you are reading contains data that is likely to be a database file, and that it should be in the format that you expect. If you read the Magic Cookie and the value read does not match the expected value then you know that you cannot use this file.
Max's book persists entire
Java objects to file (take a look at the persistDVD() and retrieveDVD() methods of the DVDDatabase class). By using Java's object serialization & deserialization, the same effect can be realised. If the file being read is a serialized version of a DVD object then it can be retrieved - otherwise an exception will be thrown.
So Max's book achieves the same effect as the Magic Cookie, but in a different way.
Regards, Andrew