摘要:Byte 类字节,属于Number。 1 public final class Byte extends Number implements Comparable<Byte> { 2 3 /** 4 * A constant holding the minimum value a {@code by
阅读全文
posted @ 2018-04-06 23:45
|
|
|
随笔分类 - Java源码-通罗马
Java技术栈-基础知识-源码解析
摘要:Byte 类字节,属于Number。 1 public final class Byte extends Number implements Comparable<Byte> { 2 3 /** 4 * A constant holding the minimum value a {@code by
阅读全文
posted @ 2018-04-06 23:45
摘要:Boolean源码比较简单。 1 public final class Boolean implements java.io.Serializable, 2 Comparable<Boolean> 3 { 4 /** 5 * The {@code Boolean} object correspond
阅读全文
posted @ 2018-04-06 23:31
摘要:总体阅读了Long的源码,基本跟Integer类类似,所以特别全部贴出源码,直接注释进行理解。 1 // final修饰符 2 public final class Long extends Number implements Comparable<Long> { 3 /** 4 * A const
阅读全文
posted @ 2018-04-06 21:35
摘要:1 /** 2 * A constant holding the minimum value an {@code int} can 3 * have, -2<sup>31</sup>. 4 */ 5 @Native public static final int MIN_VALUE = 0x8000
阅读全文
posted @ 2018-04-05 16:14
摘要:String类定义实现了java.io.Serializable, Comparable<String>, CharSequence 三个接口;并且为final修饰。 public final class String defined public final class String value[
阅读全文
posted @ 2018-04-04 22:53
摘要:通过每块代码进行源码解读,并发现源码使用的技术栈,扩展视野。 关键字: native,这涉及【JNI】的一些概念。简单理解就是"定义的方法并不是用java实现的,而是由系统连接的共享库实现"。 private static native void setIn0(InputStream in); pr
阅读全文
posted @ 2018-04-01 12:48
|
|