﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>BlogJava-手指的下面-最新评论</title><link>http://www.blogjava.net/xun56789/CommentsRSS.aspx</link><description>时间长了，手指会痛</description><language>zh-cn</language><pubDate>Sat, 04 Oct 2008 11:37:08 GMT</pubDate><lastBuildDate>Sat, 04 Oct 2008 11:37:08 GMT</lastBuildDate><generator>cnblogs</generator><item><title>re: 类的继承</title><link>http://www.blogjava.net/xun56789/archive/2008/08/20/222885.html#223348</link><dc:creator>xunSir.lee</dc:creator><author>xunSir.lee</author><pubDate>Wed, 20 Aug 2008 14:30:00 GMT</pubDate><guid>http://www.blogjava.net/xun56789/archive/2008/08/20/222885.html#223348</guid><description><![CDATA[@honeyjava<br>谢谢，现在明白<br>继承时：<br>1.子类与父类的属性都是存在<br>  引用类型是父类时就使用父类属性，是子类就使用子类属性<br>2.方法优先检索并使用子类<br>如果可以，能麻烦你解释一下，它们的内里机制吗？<img src ="http://www.blogjava.net/xun56789/aggbug/223348.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/xun56789/" target="_blank">xunSir.lee</a> 2008-08-20 22:30 <a href="http://www.blogjava.net/xun56789/archive/2008/08/20/222885.html#223348#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: 类的继承</title><link>http://www.blogjava.net/xun56789/archive/2008/08/19/222885.html#223132</link><dc:creator>honeyjava</dc:creator><author>honeyjava</author><pubDate>Tue, 19 Aug 2008 15:47:00 GMT</pubDate><guid>http://www.blogjava.net/xun56789/archive/2008/08/19/222885.html#223132</guid><description><![CDATA[没有子类覆盖父类属性一说<br><br>/**<br> * Created by IntelliJ IDEA.<br> * User: Administrator<br> * Date: 2008-8-19<br> * Time: 23:34:32<br> * To change this template use File | Settings | File Templates.<br> */<br><br>class Drived  {<br>   public int f = 2;<br><br><br>}<br><br>public class Foo extends Drived {<br>   public int f = 1;<br><br><br>    public static void main(String[] args) {<br><br>       Drived foo = new Foo();<br>       Foo foofoo = (Foo) foo;<br>       System.out.println(foo.f);<br>       System.out.println(foofoo.f);<br>    }<br>}<img src ="http://www.blogjava.net/xun56789/aggbug/223132.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/xun56789/" target="_blank">honeyjava</a> 2008-08-19 23:47 <a href="http://www.blogjava.net/xun56789/archive/2008/08/19/222885.html#223132#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>