标签:xtend 学习 AC ring ntb erb print world end
A:类与类,类与接口,接口与接口的关系class Demo3_Interface {
public static void main(String[] args) {
System.out.println("Hello World!");
}
}
interface InterA {
public abstract void printA();
}
interface InterB {
public abstract void printB();
}
interface InterC extends InterB,InterA {
}
//class Demo implements InterA,implements InterB { //这么做不允许是非法的
class Demo extends Object implements InterA,InterB {
public void printA() {
System.out.println("printA");
}
public void printB() {
System.out.println("printB");
}
}
标签:xtend 学习 AC ring ntb erb print world end
原文地址:http://blog.51cto.com/357712148/2132102