package com.house365.test;

/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Date: 16/2/16</p>
 *
 * @author XN
 * @version 1.0
 */
public class BaseClass {
    private String baseName = "base";

    public BaseClass() {
        callName();
    }

    public void callName() {
        System.out.println("base,"+baseName);
    }

    static class Sub extends BaseClass {
        private String baseName = "sub";

        public void callName() {
            System.out.println("sub,"+baseName);
        }
    }

    public static void main(String[] args) {
        BaseClass b = new Sub();
    }
}
