Hello everyone. I could not find if this was possible anywhere in the docs
I have one class called:
and i have Extented the class with concrete classes:
BooleanQuestion, MultipleChoiceQuestion, NumericQuestion.
Is it possible use the "abstract" class Question when Remoting via BlazeDS ?
There is no such thing as abstract classes in ActionScript.
Either your classes implement an interface or they extend a superclass.
If you use an ActionScript superclass Question, you can map it to its Java counterpart with the [RemoteClass] metadata tag.
I'm not sure what will happen if you send an abstract class.
Karl, thanks for your reply.
To be thorough:
I was able to do remoting using an abstract class on the java (server) side. The problem is that when you use the new Data/Services option the concrete classes are mapped without extending the abstract class (or "father" class on the AS3 side). So that breaks down the polymorphism.
As you correctly pointed out, I have hand mapped the classes using [RemoteClass], but in order to use the generated services by the Data/Services Wizard you must modify them, so the hand mapped classes are used instead of the generated Classes (which don't extend the abstract class). This is a major issue since the "refresh" option for the services is currently not working with BlazeDS Spring Integration/Hibernate.
Again thank you!