Java9 Interface privateメソッドの確認

#Java9でInterfaceにprivateメソッドが定義可能に
なりましたね。
Java8でdefaultが追加された際にダイアモンド継承の問題とかよく出ていたので、気になったので確認してみます。

##結果
- スーパークラスのprivateメソッドが呼べないのと同じく、実装クラスはInterfaceのprivateメソッドを呼べない
- Interface privateメソッドは実体が必須
    - こうなる　→　![java: メソッド本体がないか、abstractとして宣言されています](https://qiita-image-store.s3.amazonaws.com/0/48666/784afbda-fd6f-3041-e167-bc4ea96984a2.png)
- 上記から同じく実体が必須なdefaultとの併用は不可
    - こうなる　→　![java: 修飾子privateとdefaultの組合せは不正です](https://qiita-image-store.s3.amazonaws.com/0/48666/508efe96-9bd7-5d24-6fb7-395c76d6019b.png)
- 上記から参照不可なメソッドについて、多重継承、隠蔽、オーバーライドを考慮する必要はない

##結論
同Interface内でのヘルパメソッドを作成するための機能と考えられる。
少なくともprivateメソッドの実装強要とかテンプレートメソッドパターンに使うようなものではない。
とか考えてたら大分前に普通に言及ありますね。 →　[Javaインターフェースメモ(Hishidama's Java Interface Memo)#インターフェースのprivateメソッド](http://www.ne.jp/asahi/hishidama/home/tech/java/interface.html#h_private_method)

##サンプルクラス構成
![キャプチャ.PNG](https://qiita-image-store.s3.amazonaws.com/0/48666/2189f7e4-8f52-bc37-ca41-d50970f47080.png)


##サンプルコード
```SampleInterfaceA.java
public interface SampleInterfaceA {
    /** いつもの。 */
    String get();
    /** 明示的ないつもの。 */
    public abstract String getDetail();
    /** defaultメソッド。 */
    default String getDefault() {return "default IA";}
    /** staticなヤツ。 */
    static String getStatic() {return "static IA";}
//    これはダメ
//    /** privateなヤツ。 */
//    private String getPrivate();
    /** private staticなヤツ。 */
    private static String getPrivateStatic() {return "private static IA";}
//    これもダメ
//    /** private defaultなヤツ。 */
//    private default String getPrivateDefault() {return "private default";}
    /** privateなヤツ。 */
    private String getPrivate() {return "private IA";}
    /** いつもので細かいシグニチャ検討。 */
    String getException() throws IOException;
    /** privateで細かいシグニチャ検討。 */
    private String getPrivateException() throws IOException {return "private Exception IA";}
}
```
```SampleInterfaceB.java
public interface SampleInterfaceB {
    String get();
    public abstract String getDetail();
    default String getDefault() {return "default IB";}
    static String getStatic() {return "static IB";}
    private static String getPrivateStatic() {return "private static IB";}
    private String getPrivate() {return "private IB";}
//    これは元からダメなヤツ
//    String getException() throws NoClassDefFoundError;
    private String getPrivateException() throws NoClassDefFoundError {return "private Exception IA";}
}
```
```ImplementA.java
public class ImplementA implements SampleInterfaceA {
    @Override
    public String get() {return "public XA";}
    @Override
    public String getDetail() {return "public detail XA";}
    @Override
    public String toString() {
        try {
            return "ImplementA["
                    + this.get() + "\n"
                    + this.getDetail() + "\n"
                    + this.getDefault() + "\n"
                    + this.getException() + "\n"
                    + SampleInterfaceA.getStatic() + "\n"
//                    Interface private は実装クラスからも呼び出すことができない
//                    + super.getPrivate() + "\n"
//                    + SampleInterfaceA.getPrivateStatic() + "\n"
                    + this.getPrivate() + "\n"
                    + super.toString()
                    + "]";
        } catch (Exception e) {
            return "ｵｷﾅｲﾖ";
        }
    }

    @Override
    public String getException() throws IOException {return "public Exception XA";}
//    当然ながらOverrideアノテーションは付与できない
//    @Override
    private String getPrivate() {return "private XA";}
}
```
```ExtendsAImplementB.java
public class ExtendsAImplementB extends ImplementA implements SampleInterfaceB {
    // SampleInterfaceA#get()はSampleInterfaceB#get()と同シグニチャであるため、親クラス実装が適用される
    @Override
    public String getDefault() {
        return "public default extends XAB";
    }
    // SampleInterfaceA#getPrivate()とSampleInterfaceB#getPrivate()は競合しない
    // SampleInterfaceA#getException()とSampleInterfaceB#getException()は競合しない
}
```
```TestInterface.java
public class TestInterface {
    public static void main(String... args) {
        System.out.println(new ImplementA());
        System.out.println();
        System.out.println(new ExtendsAImplementB());
    }
}
```

##サンプル実行結果
```
ImplementA[public XA
public detail XA
default IA
public Exception XA
static IA
private XA
co.jp.qualysite.qm.java9.exam.privateInterface.ImplementA@13b6d03]

ImplementA[public XA
public detail XA
public default extends XAB
public Exception XA
static IA
private XA
co.jp.qualysite.qm.java9.exam.privateInterface.ExtendsAImplementB@783e6358]

Process finished with exit code 0
```

##サンプルjavap結果
```SampleInterfaceA.dec.txt
  Last modified 2017/10/04; size 853 bytes
  MD5 checksum 43c60e1b8af3c04d6cbf41b17a047927
  Compiled from "SampleInterfaceA.java"
public interface co.jp.qualysite.qm.java9.exam.privateInterface.SampleInterfaceA
  minor version: 0
  major version: 53
  flags: (0x0601) ACC_PUBLIC, ACC_INTERFACE, ACC_ABSTRACT
  this_class: #6                          // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA
  super_class: #7                         // java/lang/Object
  interfaces: 0, fields: 0, methods: 8, attributes: 1
Constant pool:
   #1 = String             #26            // default IA
   #2 = String             #27            // static IA
   #3 = String             #28            // private static IA
   #4 = String             #29            // private IA
   #5 = String             #30            // private Exception IA
   #6 = Class              #31            // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA
   #7 = Class              #32            // java/lang/Object
   #8 = Utf8               get
   #9 = Utf8               ()Ljava/lang/String;
  #10 = Utf8               getDetail
  #11 = Utf8               getDefault
  #12 = Utf8               Code
  #13 = Utf8               LineNumberTable
  #14 = Utf8               LocalVariableTable
  #15 = Utf8               this
  #16 = Utf8               Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA;
  #17 = Utf8               getStatic
  #18 = Utf8               getPrivateStatic
  #19 = Utf8               getPrivate
  #20 = Utf8               getException
  #21 = Utf8               Exceptions
  #22 = Class              #33            // java/io/IOException
  #23 = Utf8               getPrivateException
  #24 = Utf8               SourceFile
  #25 = Utf8               SampleInterfaceA.java
  #26 = Utf8               default IA
  #27 = Utf8               static IA
  #28 = Utf8               private static IA
  #29 = Utf8               private IA
  #30 = Utf8               private Exception IA
  #31 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA
  #32 = Utf8               java/lang/Object
  #33 = Utf8               java/io/IOException
{
  public abstract java.lang.String get();
    descriptor: ()Ljava/lang/String;
    flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT

  public abstract java.lang.String getDetail();
    descriptor: ()Ljava/lang/String;
    flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT

  public java.lang.String getDefault();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #1                  // String default IA
         2: areturn
      LineNumberTable:
        line 16: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA;

  public static java.lang.String getStatic();
    descriptor: ()Ljava/lang/String;
    flags: (0x0009) ACC_PUBLIC, ACC_STATIC
    Code:
      stack=1, locals=0, args_size=0
         0: ldc           #2                  // String static IA
         2: areturn
      LineNumberTable:
        line 20: 0

  private static java.lang.String getPrivateStatic();
    descriptor: ()Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=1, locals=0, args_size=0
         0: ldc           #3                  // String private static IA
         2: areturn
      LineNumberTable:
        line 27: 0

  private java.lang.String getPrivate();
    descriptor: ()Ljava/lang/String;
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #4                  // String private IA
         2: areturn
      LineNumberTable:
        line 36: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA;

  public abstract java.lang.String getException() throws java.io.IOException;
    descriptor: ()Ljava/lang/String;
    flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT
    Exceptions:
      throws java.io.IOException

  private java.lang.String getPrivateException() throws java.io.IOException;
    descriptor: ()Ljava/lang/String;
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #5                  // String private Exception IA
         2: areturn
      LineNumberTable:
        line 42: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA;
    Exceptions:
      throws java.io.IOException
}
SourceFile: "SampleInterfaceA.java"
```
```SampleInterfaceB.dec.txt
  Last modified 2017/10/03; size 831 bytes
  MD5 checksum ed3be9304a1489a8f0f77bb9e5657fe8
  Compiled from "SampleInterfaceB.java"
public interface co.jp.qualysite.qm.java9.exam.privateInterface.SampleInterfaceB
  minor version: 0
  major version: 53
  flags: (0x0601) ACC_PUBLIC, ACC_INTERFACE, ACC_ABSTRACT
  this_class: #6                          // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB
  super_class: #7                         // java/lang/Object
  interfaces: 0, fields: 0, methods: 7, attributes: 1
Constant pool:
   #1 = String             #25            // default IB
   #2 = String             #26            // static IB
   #3 = String             #27            // private static IB
   #4 = String             #28            // private IB
   #5 = String             #29            // private Exception IA
   #6 = Class              #30            // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB
   #7 = Class              #31            // java/lang/Object
   #8 = Utf8               get
   #9 = Utf8               ()Ljava/lang/String;
  #10 = Utf8               getDetail
  #11 = Utf8               getDefault
  #12 = Utf8               Code
  #13 = Utf8               LineNumberTable
  #14 = Utf8               LocalVariableTable
  #15 = Utf8               this
  #16 = Utf8               Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB;
  #17 = Utf8               getStatic
  #18 = Utf8               getPrivateStatic
  #19 = Utf8               getPrivate
  #20 = Utf8               getPrivateException
  #21 = Utf8               Exceptions
  #22 = Class              #32            // java/lang/NoClassDefFoundError
  #23 = Utf8               SourceFile
  #24 = Utf8               SampleInterfaceB.java
  #25 = Utf8               default IB
  #26 = Utf8               static IB
  #27 = Utf8               private static IB
  #28 = Utf8               private IB
  #29 = Utf8               private Exception IA
  #30 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB
  #31 = Utf8               java/lang/Object
  #32 = Utf8               java/lang/NoClassDefFoundError
{
  public abstract java.lang.String get();
    descriptor: ()Ljava/lang/String;
    flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT

  public abstract java.lang.String getDetail();
    descriptor: ()Ljava/lang/String;
    flags: (0x0401) ACC_PUBLIC, ACC_ABSTRACT

  public java.lang.String getDefault();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #1                  // String default IB
         2: areturn
      LineNumberTable:
        line 7: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB;

  public static java.lang.String getStatic();
    descriptor: ()Ljava/lang/String;
    flags: (0x0009) ACC_PUBLIC, ACC_STATIC
    Code:
      stack=1, locals=0, args_size=0
         0: ldc           #2                  // String static IB
         2: areturn
      LineNumberTable:
        line 10: 0

  private static java.lang.String getPrivateStatic();
    descriptor: ()Ljava/lang/String;
    flags: (0x000a) ACC_PRIVATE, ACC_STATIC
    Code:
      stack=1, locals=0, args_size=0
         0: ldc           #3                  // String private static IB
         2: areturn
      LineNumberTable:
        line 13: 0

  private java.lang.String getPrivate();
    descriptor: ()Ljava/lang/String;
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #4                  // String private IB
         2: areturn
      LineNumberTable:
        line 16: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB;

  private java.lang.String getPrivateException() throws java.lang.NoClassDefFoundError;
    descriptor: ()Ljava/lang/String;
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #5                  // String private Exception IA
         2: areturn
      LineNumberTable:
        line 21: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB;
    Exceptions:
      throws java.lang.NoClassDefFoundError
}
SourceFile: "SampleInterfaceB.java"
```
```ImplementA.dec.txt
  Last modified 2017/10/04; size 1789 bytes
  MD5 checksum 35cd13cc4e177ce294b094056750d7a2
  Compiled from "ImplementA.java"
public class co.jp.qualysite.qm.java9.exam.privateInterface.ImplementA implements co.jp.qualysite.qm.java9.exam.privateInterface.SampleInterfaceA
  minor version: 0
  major version: 53
  flags: (0x0021) ACC_PUBLIC, ACC_SUPER
  this_class: #16                         // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
  super_class: #17                        // java/lang/Object
  interfaces: 1, fields: 0, methods: 6, attributes: 3
Constant pool:
   #1 = Methodref          #17.#39        // java/lang/Object."<init>":()V
   #2 = String             #40            // public XA
   #3 = String             #41            // public detail XA
   #4 = Methodref          #16.#42        // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA.get:()Ljava/lang/String;
   #5 = Methodref          #16.#43        // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA.getDetail:()Ljava/lang/String;
   #6 = Methodref          #16.#44        // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA.getDefault:()Ljava/lang/String;
   #7 = Methodref          #16.#45        // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA.getException:()Ljava/lang/String;
   #8 = InterfaceMethodref #18.#46        // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA.getStatic:()Ljava/lang/String;
   #9 = Methodref          #16.#47        // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA.getPrivate:()Ljava/lang/String;
  #10 = Methodref          #17.#48        // java/lang/Object.toString:()Ljava/lang/String;
  #11 = InvokeDynamic      #0:#52         // #0:makeConcatWithConstants:(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
  #12 = Class              #53            // java/lang/Exception
  #13 = String             #54            // ｵｷﾅｲﾖ
  #14 = String             #55            // public Exception XA
  #15 = String             #56            // private XA
  #16 = Class              #57            // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
  #17 = Class              #58            // java/lang/Object
  #18 = Class              #59            // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA
  #19 = Utf8               <init>
  #20 = Utf8               ()V
  #21 = Utf8               Code
  #22 = Utf8               LineNumberTable
  #23 = Utf8               LocalVariableTable
  #24 = Utf8               this
  #25 = Utf8               Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;
  #26 = Utf8               get
  #27 = Utf8               ()Ljava/lang/String;
  #28 = Utf8               getDetail
  #29 = Utf8               toString
  #30 = Utf8               e
  #31 = Utf8               Ljava/lang/Exception;
  #32 = Utf8               StackMapTable
  #33 = Utf8               getException
  #34 = Utf8               Exceptions
  #35 = Class              #60            // java/io/IOException
  #36 = Utf8               getPrivate
  #37 = Utf8               SourceFile
  #38 = Utf8               ImplementA.java
  #39 = NameAndType        #19:#20        // "<init>":()V
  #40 = Utf8               public XA
  #41 = Utf8               public detail XA
  #42 = NameAndType        #26:#27        // get:()Ljava/lang/String;
  #43 = NameAndType        #28:#27        // getDetail:()Ljava/lang/String;
  #44 = NameAndType        #61:#27        // getDefault:()Ljava/lang/String;
  #45 = NameAndType        #33:#27        // getException:()Ljava/lang/String;
  #46 = NameAndType        #62:#27        // getStatic:()Ljava/lang/String;
  #47 = NameAndType        #36:#27        // getPrivate:()Ljava/lang/String;
  #48 = NameAndType        #29:#27        // toString:()Ljava/lang/String;
  #49 = Utf8               BootstrapMethods
  #50 = MethodHandle       6:#63          // REF_invokeStatic java/lang/invoke/StringConcatFactory.makeConcatWithConstants:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite;
  #51 = String             #64            // ImplementA[\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001]
  #52 = NameAndType        #65:#66        // makeConcatWithConstants:(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
  #53 = Utf8               java/lang/Exception
  #54 = Utf8               ｵｷﾅｲﾖ
  #55 = Utf8               public Exception XA
  #56 = Utf8               private XA
  #57 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
  #58 = Utf8               java/lang/Object
  #59 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA
  #60 = Utf8               java/io/IOException
  #61 = Utf8               getDefault
  #62 = Utf8               getStatic
  #63 = Methodref          #67.#68        // java/lang/invoke/StringConcatFactory.makeConcatWithConstants:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite;
  #64 = Utf8               ImplementA[\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001]
  #65 = Utf8               makeConcatWithConstants
  #66 = Utf8               (Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
  #67 = Class              #69            // java/lang/invoke/StringConcatFactory
  #68 = NameAndType        #65:#73        // makeConcatWithConstants:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite;
  #69 = Utf8               java/lang/invoke/StringConcatFactory
  #70 = Class              #75            // java/lang/invoke/MethodHandles$Lookup
  #71 = Utf8               Lookup
  #72 = Utf8               InnerClasses
  #73 = Utf8               (Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite;
  #74 = Class              #76            // java/lang/invoke/MethodHandles
  #75 = Utf8               java/lang/invoke/MethodHandles$Lookup
  #76 = Utf8               java/lang/invoke/MethodHandles
{
  public co.jp.qualysite.qm.java9.exam.privateInterface.ImplementA();
    descriptor: ()V
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: aload_0
         1: invokespecial #1                  // Method java/lang/Object."<init>":()V
         4: return
      LineNumberTable:
        line 5: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       5     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;

  public java.lang.String get();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #2                  // String public XA
         2: areturn
      LineNumberTable:
        line 8: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;

  public java.lang.String getDetail();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #3                  // String public detail XA
         2: areturn
      LineNumberTable:
        line 13: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;

  public java.lang.String toString();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=7, locals=2, args_size=1
         0: aload_0
         1: invokevirtual #4                  // Method get:()Ljava/lang/String;
         4: aload_0
         5: invokevirtual #5                  // Method getDetail:()Ljava/lang/String;
         8: aload_0
         9: invokevirtual #6                  // Method getDefault:()Ljava/lang/String;
        12: aload_0
        13: invokevirtual #7                  // Method getException:()Ljava/lang/String;
        16: invokestatic  #8                  // InterfaceMethod co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceA.getStatic:()Ljava/lang/String;
        19: aload_0
        20: invokespecial #9                  // Method getPrivate:()Ljava/lang/String;
        23: aload_0
        24: invokespecial #10                 // Method java/lang/Object.toString:()Ljava/lang/String;
        27: invokedynamic #11,  0             // InvokeDynamic #0:makeConcatWithConstants:(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
        32: areturn
        33: astore_1
        34: ldc           #13                 // String ｵｷﾅｲﾖ
        36: areturn
      Exception table:
         from    to  target type
             0    32    33   Class java/lang/Exception
      LineNumberTable:
        line 19: 0
        line 20: 1
        line 21: 5
        line 22: 9
        line 23: 13
        line 24: 16
        line 28: 20
        line 29: 24
        line 19: 32
        line 31: 33
        line 32: 34
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
           34       3     1     e   Ljava/lang/Exception;
            0      37     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;
      StackMapTable: number_of_entries = 1
        frame_type = 97 /* same_locals_1_stack_item */
          stack = [ class java/lang/Exception ]

  public java.lang.String getException() throws java.io.IOException;
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #14                 // String public Exception XA
         2: areturn
      LineNumberTable:
        line 38: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;
    Exceptions:
      throws java.io.IOException

  private java.lang.String getPrivate();
    descriptor: ()Ljava/lang/String;
    flags: (0x0002) ACC_PRIVATE
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #15                 // String private XA
         2: areturn
      LineNumberTable:
        line 44: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ImplementA;
}
SourceFile: "ImplementA.java"
InnerClasses:
  public static final #71= #70 of #74;    // Lookup=class java/lang/invoke/MethodHandles$Lookup of class java/lang/invoke/MethodHandles
BootstrapMethods:
  0: #50 REF_invokeStatic java/lang/invoke/StringConcatFactory.makeConcatWithConstants:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/invoke/CallSite;
    Method arguments:
      #51 ImplementA[\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001\n\u0001]
```
```ExtendsAImplementB.dec.txt
  Last modified 2017/10/04; size 612 bytes
  MD5 checksum 1fa0fadf291413f1950fd318148fe45a
  Compiled from "ExtendsAImplementB.java"
public class co.jp.qualysite.qm.java9.exam.privateInterface.ExtendsAImplementB extends co.jp.qualysite.qm.java9.exam.privateInterface.ImplementA implements co.jp.qualysite.qm.java9.exam.privateInterface.SampleInterfaceB
  minor version: 0
  major version: 53
  flags: (0x0021) ACC_PUBLIC, ACC_SUPER
  this_class: #3                          // co/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB
  super_class: #4                         // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
  interfaces: 1, fields: 0, methods: 2, attributes: 1
Constant pool:
   #1 = Methodref          #4.#17         // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA."<init>":()V
   #2 = String             #18            // public default extends XAB
   #3 = Class              #19            // co/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB
   #4 = Class              #20            // co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
   #5 = Class              #21            // co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB
   #6 = Utf8               <init>
   #7 = Utf8               ()V
   #8 = Utf8               Code
   #9 = Utf8               LineNumberTable
  #10 = Utf8               LocalVariableTable
  #11 = Utf8               this
  #12 = Utf8               Lco/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB;
  #13 = Utf8               getDefault
  #14 = Utf8               ()Ljava/lang/String;
  #15 = Utf8               SourceFile
  #16 = Utf8               ExtendsAImplementB.java
  #17 = NameAndType        #6:#7          // "<init>":()V
  #18 = Utf8               public default extends XAB
  #19 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB
  #20 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA
  #21 = Utf8               co/jp/qualysite/qm/java9/exam/privateInterface/SampleInterfaceB
{
  public co.jp.qualysite.qm.java9.exam.privateInterface.ExtendsAImplementB();
    descriptor: ()V
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: aload_0
         1: invokespecial #1                  // Method co/jp/qualysite/qm/java9/exam/privateInterface/ImplementA."<init>":()V
         4: return
      LineNumberTable:
        line 3: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       5     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB;

  public java.lang.String getDefault();
    descriptor: ()Ljava/lang/String;
    flags: (0x0001) ACC_PUBLIC
    Code:
      stack=1, locals=1, args_size=1
         0: ldc           #2                  // String public default extends XAB
         2: areturn
      LineNumberTable:
        line 7: 0
      LocalVariableTable:
        Start  Length  Slot  Name   Signature
            0       3     0  this   Lco/jp/qualysite/qm/java9/exam/privateInterface/ExtendsAImplementB;
}
SourceFile: "ExtendsAImplementB.java"
```