3

I have a problem with JAXB XJC and binding. I don't know how to generate an enumeration by xsd implementing and interface and a set of method. For example I would generate something like that

public interface IService
{
 public void doSomething(SomeClass obj1, SomeClass obj2);

}

public enum EService implements IService
{
         A{
          public void doSomething(SomeClass obj1, SomeClass obj2) {
          // some code
          },
          B {
          public void doSomething(SomeClass obj1, SomeClass obj2) {
          // some other code
          };

  public void doSomething(SomeClass obj1, SomeClass obj2){
  //default implementation
  }
}

How I could do generate that from model.xsd with binding.xjc.

Thank you very much. I will really appreciate any help :) :)

Alberto

Alberto R.
  • 161
  • 2
  • 10
  • Possible duplicate of [JAXB element of type enum](http://stackoverflow.com/questions/5806923/jaxb-element-of-type-enum). You might also find [Generating a JAXB class that implements an interface](http://stackoverflow.com/q/1271980/851811) useful. – Xavi López May 09 '13 at 10:17

0 Answers0