摘要: 隐式类型转换1. 基本数据类型 1.1: byte、short、char --> int --> long --> float --> double 基本数据类型能够进行隐式的类型转换2. 对象数据类型 可以将子类隐式的转换成为父类.在继承的结构可以安全的往上进行转型。显式的类型转换1. 基本数据类型 1.1: 基本数据类型进行反方向的类型转换需要进行显式的类型转换定义。 int i = 0x11; short s = (short)i; (short)需要加入进来... 阅读全文
posted @ 2012-10-16 23:27 papertiger 阅读(201) 评论(0) 推荐(0)