Topic: 想了解一下内部类和外部类的知识 |
Print this page |
1.想了解一下内部类和外部类的知识 | Copy to clipboard |
Posted by: wslss007 Posted on: 2005-10-29 18:53 如题,请朋友提供一个链接,谢谢了。 |
2.Re:想了解一下内部类和外部类的知识 [Re: wslss007] | Copy to clipboard |
Posted by: 冷血无情 Posted on: 2005-10-29 20:20 public class A { public static void main(String args[]) { B a=new B(); a.num(5); } static class B { int b; void num(int n) { b=n; System.out.println("b="+b); } } } 类A表示外部类,类B表示内部类 |
3.Re:想了解一下内部类和外部类的知识 [Re: wslss007] | Copy to clipboard |
Posted by: wslss007 Posted on: 2005-10-30 12:13 我想具体的了解,而不是这样走马观花。 |
4.Re:想了解一下内部类和外部类的知识 [Re: wslss007] | Copy to clipboard |
Posted by: Jcat Posted on: 2005-10-30 13:34 《think in java》里有关于内部类的详细讲解 chapt 8: Interfaces & Inner Classes |
5.Re:想了解一下内部类和外部类的知识 [Re: wslss007] | Copy to clipboard |
Posted by: 冷血无情 Posted on: 2005-10-30 18:10 如果在类A的内部再定义一个类B,此时类B称为内部类,而类A则称为外部类。 |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |