Java 语法 索引 ----- 接口

interface MyInterface

{

    void exposed();

}

class MyClass implements MyInterface

{

    public void exposed() {}

    public void hidden() {}

}



public static void main(String[] args)

{

    MyInterface i = new MyClass();

}

参考文献: Java Quick Syntax Reference by Mikael Olsson

你可能感兴趣的:(java)