reset password
Author Message
dgomei
Posts: 7
Posted 21:52 May 05, 2017 |

I'm confused with MonsterPersister. You want this to become the interface correct? I'm confused because the VampirePersister in the example  is a class that implements serializable. Instead of using serializable , you wanted us to make it an interface so that BinaryMonsterPersister can implement from MosnterPersister? 

jhurley
Posts: 207
Posted 08:48 May 06, 2017 |

Yes.  VampirePersister did not need to implement Serializable; that was a typo by me, which I have just corrected.  The idea here is that you can create the interface and implement it in different ways.  The assignment  requires you to implement it one way, using binary file I/O.  In other circumstances you might implement the interface it some other way, for example using text I/O.