(newbie question) Hi,
I'd like to write a set of Actors that behave very similarly, however have a few differences as well. In plain java world I'd write an Abstract parent class that includes all of the shared behavior, have each child class extend it, and override only the class methods that differ from the abstract class implementation. I'm not sure how to do it in Akka - Java. I've seen a very similar question and a really nice answer here <http://stackoverflow.com/questions/17383827/how-do-i-best-share-behavior-among-akka-actors>, but it's using scala, and scala traits. My initial thought was something like: public abstract class MyParentActor(...) extends UntypedActor { ... <few class methods and their implementations> } public class MyChildActor1(...) extends MyParentActor { super(...); <some class methods> public void onReceive(msg) { <use class or MyParentActor methods> } } Is that a good idea? will that work? BTW, since the project has yet to start, I'm not tied to a specific Akka version, so I assume 2.3.8. Thanks in advance! Alon. -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
