Book a Demo

Author Topic: Java 8 Interface "default" keyword  (Read 4422 times)

Parallizer

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Java 8 Interface "default" keyword
« on: December 21, 2014, 10:09:01 pm »
I'm not able to import interfaces like this due to a "syntax error" on the "default" line:

public interface IStreamer
{

      default public int streamPos()  // *
      {
            return -1;
      }

}

, nor do i found a way to define and code-gen a "default" method implementation in the model editor.

Can someone enlighten me please ?


MMA

  • EA User
  • **
  • Posts: 63
  • Karma: +3/-0
    • View Profile
Re: Java 8 Interface "default" keyword
« Reply #1 on: December 22, 2014, 08:09:34 am »
You might need to report a bug  ;)

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Java 8 Interface "default" keyword
« Reply #2 on: December 22, 2014, 08:45:30 am »
More to the point... Java 8 didn't exist until this year. It looks like we haven't added support for it yet.

If you contact support then I would expect that would will be able to help with both adding support to future versions and possibly providing an MDG technology that will allow parsing of new language features.