随笔分类 -  java

摘要:Runtime type information (RTTI) allow you to discover and use type information while a program is running This take two forms: 1. "traditional" ... 阅读全文
posted @ 2016-01-25 15:59 nicke 阅读(290) 评论(0) 推荐(0)
摘要:Immutable Strings Objects of the String class are immutable. If you examine the JDK documentation for the String class, you’ll see that every method... 阅读全文
posted @ 2016-01-22 11:02 nicke 阅读(611) 评论(0) 推荐(0)
摘要:The ideal time to catch an error is at compile time, before you even try to run the program. However, not all errors can be detected at compile time... 阅读全文
posted @ 2016-01-19 12:56 nicke 阅读(416) 评论(0) 推荐(0)
摘要:To solve the general programming problem, you need to create any number of objects, anytime, anywhere. So you can't rely on creating a named referen... 阅读全文
posted @ 2016-01-14 23:46 nicke 阅读(307) 评论(0) 推荐(0)
摘要:The inner class is a valuable feature because it allows you to group classes that logically belong together and to control the visibility of one wit... 阅读全文
posted @ 2016-01-12 12:10 nicke 阅读(259) 评论(0) 推荐(0)
摘要:Interfaces and abstract classes provide more structured way to separate interface from implementation. the abstract class, which is a kind of midway ... 阅读全文
posted @ 2016-01-08 13:27 nicke 阅读(315) 评论(0) 推荐(0)
摘要:Polymorphism is the third essential feature of an object-oriented programming language,after data abastraction and inheritance.It provides another d... 阅读全文
posted @ 2016-01-07 23:08 nicke 阅读(273) 评论(0) 推荐(0)
摘要:The trick is to use the classes without soiling the existing code. 1. composition--simply create objects of your existing class inside the new class.... 阅读全文
posted @ 2015-12-31 23:42 nicke 阅读(272) 评论(0) 推荐(0)
摘要:Access control ( or implementation hiding) is about "not getting it right the first time."refactoringa primary consideration in object-oriented design... 阅读全文
posted @ 2015-12-29 22:55 nicke 阅读(436) 评论(0) 推荐(0)
摘要:Two of these safety issues are initialization and cleanup. initialization -> bug cleanup -> running out of resources (most notably, memory) Java ... 阅读全文
posted @ 2015-12-26 22:56 nicke 阅读(368) 评论(0) 推荐(0)
摘要:dataType的值不能为"", 否则会导致错误发生:Uncaught TypeError: Cannot read property '0' of null,http请求可以发送,但是callback不能触发 阅读全文
posted @ 2015-12-17 12:00 nicke 阅读(316) 评论(0) 推荐(0)
摘要:At the lowest level, data in Java is manipulated using operatorsUsing Java Operators An operator takes one or more argument and produces a new valu... 阅读全文
posted @ 2015-12-14 23:04 nicke 阅读(578) 评论(0) 推荐(0)
摘要:安装JDK时,自动将java.exe复制到C:\Windows\System32下 阅读全文
posted @ 2015-12-10 17:20 nicke 阅读(376) 评论(0) 推荐(0)