{"id":72832,"date":"2026-02-06T17:00:09","date_gmt":"2026-02-06T09:00:09","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/72832.html"},"modified":"2026-02-06T17:00:09","modified_gmt":"2026-02-06T09:00:09","slug":"%e4%bb%8e0%e5%bc%80%e5%a7%8b%e5%ad%a6java%e7%ac%ac%e5%8d%81%e4%ba%94%e5%a4%a9%e9%9d%a2%e5%90%91%e5%af%b9%e8%b1%a1%e8%bf%9b%e9%98%b6%ef%bc%88%e6%8a%bd%e8%b1%a1%e7%b1%bb%e6%8e%a5%e5%8f%a3","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/72832.html","title":{"rendered":"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09"},"content":{"rendered":"<h2>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5<\/h2>\n<h3>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6982\u5ff5<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"193\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206085959-6985ad8f62128.png\" width=\"600\" \/><\/p>\n<h3>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u5b9a\u4e49\u683c\u5f0f<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"147\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206085959-6985ad8fa7455.png\" width=\"500\" \/><\/p>\n<h3>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6ce8\u610f\u4e8b\u9879<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"201\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206085959-6985ad8fc2e8c.png\" width=\"500\" \/><\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Person]<\/p>\n<p>package com.itheima.a01abstractdemo1;<\/p>\n<p>public abstract class Person {<br \/>\n    private String name;<br \/>\n    private int age;<\/p>\n<p>    \/\/\u5f53\u521b\u5efa\u5b50\u7c7b\u5bf9\u8c61\u65f6&#xff0c;\u7ed9\u5c5e\u6027\u8d4b\u503c\u7684<br \/>\n    public Person() {<br \/>\n    }<\/p>\n<p>    public Person(String name, int age) {<br \/>\n        this.name &#061; name;<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public String getName() {<br \/>\n        return name;<br \/>\n    }<\/p>\n<p>    public void setName(String name) {<br \/>\n        this.name &#061; name;<br \/>\n    }<\/p>\n<p>    public int getAge() {<br \/>\n        return age;<br \/>\n    }<\/p>\n<p>    public void setAge(int sge) {<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public abstract void work();<\/p>\n<p>    public void sleep(){<br \/>\n        System.out.println(&#034;\u7761\u89c9&#034;);<br \/>\n    }<br \/>\n}<\/p>\n<p>[Student]<\/p>\n<p>package com.itheima.a01abstractdemo1;<\/p>\n<p>public class Student extends Person{<\/p>\n<p>    public Student() {<br \/>\n    }<\/p>\n<p>    public Student(String name, int sge) {<br \/>\n        super(name, sge);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void work(){<br \/>\n        System.out.println(&#034;\u5b66\u751f\u7684\u5de5\u4f5c\u662f\u5b66\u4e60&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a01abstractdemo1;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>            Student s &#061; new Student(&#034;zhangsan&#034;,23);<br \/>\n            System.out.println(s.getName() &#043; &#034;, &#034; &#043; s.getAge());<br \/>\n    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"90\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090000-6985ad900e77b.png\" width=\"300\" \/><\/p>\n<\/p>\n<h3>\u7ec3\u4e60&#xff1a;\u7f16\u5199\u5e26\u6709\u62bd\u8c61\u7c7b\u7684\u6807\u51c6javabean\u7c7b\u7684<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"362\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090000-6985ad901b450.png\" width=\"1235\" \/><\/p>\n<p>&#xff08;\u5206\u6790&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"799\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090000-6985ad90651a7.png\" width=\"1829\" \/><\/p>\n<p>(\u6e90\u4ee3\u7801)<\/p>\n<p>[Animal]<\/p>\n<p>package com.itheima.a02abstractdemo2;<\/p>\n<p>public abstract class Animal {<br \/>\n    private String name;<br \/>\n    private int age;<\/p>\n<p>    public Animal() {<br \/>\n    }<\/p>\n<p>    public Animal(String name, int age) {<br \/>\n        this.name &#061; name;<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public String getName() {<br \/>\n        return name;<br \/>\n    }<\/p>\n<p>    public void setName(String name) {<br \/>\n        this.name &#061; name;<br \/>\n    }<\/p>\n<p>    public int getAge() {<br \/>\n        return age;<br \/>\n    }<\/p>\n<p>    public void setAge(int age) {<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public abstract void eat();<\/p>\n<p>    public void drink(){<br \/>\n        System.out.println(&#034;\u52a8\u7269\u5728\u559d\u6c34&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Frog]<\/p>\n<p>package com.itheima.a02abstractdemo2;<\/p>\n<p>public class Frog extends Animal{<\/p>\n<p>    public Frog() {<br \/>\n    }<\/p>\n<p>    public Frog(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u9752\u86d9\u5728\u5403\u866b\u5b50&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Dog]<\/p>\n<p>package com.itheima.a02abstractdemo2;<\/p>\n<p>public class Dog extends Animal{<\/p>\n<p>    public Dog() {<br \/>\n    }<\/p>\n<p>    public Dog(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u72d7\u5728\u5403\u9aa8\u5934&#034;);<br \/>\n    }<br \/>\n}<\/p>\n<p>[Sheep]<\/p>\n<p>package com.itheima.a02abstractdemo2;<\/p>\n<p>public class Sheep extends Animal{<\/p>\n<p>    public Sheep() {<br \/>\n    }<\/p>\n<p>    public Sheep(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u5c71\u7f8a\u5728\u5403\u8349&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a02abstractdemo2;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args){<\/p>\n<p>        \/\/\u521b\u5efa\u5bf9\u8c61<br \/>\n        Dog d &#061; new Dog(&#034;\u5927\u9ec4&#034;,1);<br \/>\n        System.out.println(d.getName() &#043; &#034;, &#034; &#043; d.getAge());<br \/>\n        d.eat();<br \/>\n        d.drink();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"178\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090001-6985ad9140410.png\" width=\"400\" \/><\/p>\n<\/p>\n<h3>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u610f\u4e49<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"134\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090001-6985ad914ed25.png\" width=\"500\" \/><\/p>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0<span style=\"color:#be191c\">\u00a0\u00a0\u00a0\u00a0\u00a0\u5f3a\u5236\u5b50\u7c7b\u5fc5\u987b\u6309\u7167\u8fd9\u79cd\u683c\u5f0f\u8fdb\u884c\u7f16\u5199<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"907\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090001-6985ad917d718.png\" width=\"1869\" \/><\/p>\n<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"829\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090002-6985ad923c2a6.png\" width=\"1741\" \/><\/p>\n<\/p>\n<h2>\u63a5\u53e3<\/h2>\n<h3>\u4e3a\u4ec0\u4e48\u8981\u6709\u63a5\u53e3&#xff1f;<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"911\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090002-6985ad92e42fa.png\" width=\"1881\" \/><\/p>\n<h3>\u63a5\u53e3\u7684\u5e94\u7528<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"662\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090003-6985ad93c3709.png\" width=\"1757\" \/><\/p>\n<h3>\u63a5\u53e3\u548c\u62bd\u8c61\u7c7b\u7684\u5f02\u540c<\/h3>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u63a5\u53e3\u5c31\u662f\u4e00\u79cd\u89c4\u5219&#xff0c;\u662f\u5bf9\u884c\u4e3a\u7684\u62bd\u8c61<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"789\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090004-6985ad9491ef0.png\" width=\"1800\" \/><\/p>\n<h3>\u63a5\u53e3\u7684\u5b9a\u4e49\u548c\u4f7f\u7528<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"320\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090005-6985ad95670a2.png\" width=\"500\" \/><\/p>\n<\/p>\n<h3>\u7ec3\u4e60&#xff1a;\u7f16\u5199\u5e26\u6709\u63a5\u53e3\u548c\u62bd\u8c61\u7c7b\u7684\u6807\u51c6javabean\u7c7b<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"854\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090005-6985ad95e4c3f.png\" width=\"1740\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Animal]<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public abstract class Animal {<br \/>\n    private String name;<br \/>\n    private int age;<\/p>\n<p>    public Animal() {<br \/>\n    }<\/p>\n<p>    public Animal(String name,int age){<br \/>\n        this.name &#061; name;<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public String getName(){<br \/>\n        return name;<br \/>\n    }<\/p>\n<p>    public void setName(String name){<br \/>\n        this.name &#061; name;<br \/>\n    }<\/p>\n<p>    public int getAge(){<br \/>\n        return age;<br \/>\n    }<\/p>\n<p>    public void setAge(int age){<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public abstract void eat();<\/p>\n<p>}<\/p>\n<p>[Swim](\u63a5\u53e3interface)<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public interface Swim {<\/p>\n<p>    public abstract void swim();<\/p>\n<p>}<\/p>\n<p>[Rabbit]<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public class Rabbit extends Animal{<\/p>\n<p>    public Rabbit(){<br \/>\n    }<\/p>\n<p>    public Rabbit(String name,int age){<br \/>\n        super(name,age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u5154\u5b50\u5728\u5403\u8349&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Frog]<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public class Frog extends Animal implements Swim{<\/p>\n<p>    public Frog() {<br \/>\n    }<\/p>\n<p>    public Frog(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u9752\u86d9\u5728\u5403\u866b\u5b50&#034;);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void swim(){<br \/>\n        System.out.println(&#034;\u9752\u86d9\u5728\u86d9\u6cf3&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Dog]<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public class Dog extends Animal implements Swim{<\/p>\n<p>    public Dog() {<br \/>\n    }<\/p>\n<p>    public Dog(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void eat(){<br \/>\n        System.out.println(&#034;\u72d7\u5728\u5403\u9aa8\u5934&#034;);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void swim(){<br \/>\n        System.out.println(&#034;\u72d7\u5728\u72d7\u5228&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a01interfacedemo1;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<br \/>\n        \/\/\u521b\u5efa\u5bf9\u8c61<br \/>\n        Dog d &#061; new Dog(&#034;\u5927\u9ec4&#034;,1);<br \/>\n        System.out.println(d.getName() &#043; &#034;, &#034; &#043; d.getAge());<br \/>\n        d.eat();<br \/>\n        d.swim();<\/p>\n<p>        Rabbit r &#061; new Rabbit(&#034;\u5c0f\u767d&#034;,1);<br \/>\n        System.out.println(r.getName() &#043; &#034;, &#034; &#043; r.getAge());<br \/>\n        r.eat();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"181\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090006-6985ad9686097.png\" width=\"300\" \/><\/p>\n<\/p>\n<h2>\u63a5\u53e3\u7684\u7ec6\u8282&#xff1a;\u6210\u5458\u7279\u70b9\u548c\u63a5\u53e3\u7684\u5404\u79cd\u5173\u7cfb<\/h2>\n<h3>\u63a5\u53e3\u4e2d\u6210\u5458\u7684\u7279\u70b9<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"364\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090006-6985ad9698f41.png\" width=\"400\" \/><\/p>\n<\/p>\n<h3>\u63a5\u53e3\u548c\u7c7b\u4e4b\u95f4\u7684\u5173\u7cfb<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"357\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090006-6985ad96e6864.png\" width=\"1366\" \/><\/p>\n<p><span style=\"color:#be191c\">\u7c7b\u548c\u63a5\u53e3\u7684\u5173\u7cfb\u4e2d\u7684\u5c0f\u7ec6\u8282&#xff1a;<\/span><\/p>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u5982\u679c\u540c\u65f6\u5b9e\u73b0\u591a\u4e2a\u63a5\u53e3&#xff0c;\u5c31\u8981\u91cd\u5199\u91cc\u9762\u6240\u6709\u7684\u62bd\u8c61\u65b9\u6cd5<\/p>\n<p><span style=\"color:#be191c\">\u63a5\u53e3\u548c\u63a5\u53e3\u7684\u5173\u7cfb\u4e2d\u7684\u5c0f\u7ec6\u8282&#xff1a;<\/span><\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u5b9e\u73b0\u7c7b\u662f\u5b9e\u73b0\u7684\u6700\u4e0b\u9762\u7684\u5b50\u63a5\u53e3\u7684\u8bdd&#xff0c;\u9700\u8981\u91cd\u5199\u4f53\u7cfb\u4e2d\u6240\u6709\u7684\u62bd\u8c61\u65b9\u6cd5<\/p>\n<\/p>\n<h3>\u63a5\u53e3\u548c\u62bd\u8c61\u7c7b\u7684\u7efc\u5408\u6848\u4f8b<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"754\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090007-6985ad972a498.png\" width=\"1445\" \/><\/p>\n<p>&#xff08;\u5206\u6790&#xff09;<\/p>\n<p>\u3010\u601d\u8def1\u3011<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"841\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206090007-6985ad9795eeb.png\" width=\"1925\" \/><\/p>\n<p>\u3010\u601d\u8def2\u3011&#xff08;\u66f4\u63a8\u8350\u7684\u65b9\u6848&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"834\" src=\"2026-02-06gvywsfiqswf.png\" width=\"1939\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Person]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class Person {<br \/>\n    private String name;<br \/>\n    private int age;<\/p>\n<p>    public Person() {<br \/>\n    }<\/p>\n<p>    public Person(String name, int age) {<br \/>\n        this.name &#061; name;<br \/>\n        this.age &#061; age;<br \/>\n    }<\/p>\n<p>    public String getName() {<br \/>\n        return name;<br \/>\n    }<\/p>\n<p>    public void setName(String name) {<br \/>\n        this.name &#061; name;<br \/>\n    }<\/p>\n<p>    public int getAge() {<br \/>\n        return age;<br \/>\n    }<\/p>\n<p>    public void setAge(int age) {<br \/>\n        this.age &#061; age;<br \/>\n    }<br \/>\n}<\/p>\n<p>[English](\u63a5\u53e3interface)<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public interface English {<\/p>\n<p>    public abstract void speakEnglish();<\/p>\n<p>}<\/p>\n<p>[Sporter]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public abstract class Sporter extends Person{<\/p>\n<p>    public Sporter() {<br \/>\n    }<\/p>\n<p>    public Sporter(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    public abstract void study();<\/p>\n<p>}<\/p>\n<p>[Coach]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public abstract class Coach extends Person{<\/p>\n<p>    public Coach() {<br \/>\n    }<\/p>\n<p>    public Coach(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    public abstract void teach();<\/p>\n<p>}<\/p>\n<p>[PingPangSporter]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class PingPangSporter extends Sporter implements English{<\/p>\n<p>    public PingPangSporter() {<br \/>\n    }<\/p>\n<p>    public PingPangSporter(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void study(){<br \/>\n        System.out.println(&#034;\u4e52\u4e53\u7403\u8fd0\u52a8\u5458\u5728\u5b66\u6253\u4e52\u4e53\u7403&#034;);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void speakEnglish(){<br \/>\n        System.out.println(&#034;\u4e52\u4e53\u7403\u8fd0\u52a8\u5458\u5728\u8bf4\u82f1\u8bed&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[BasketballSporter]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class BasketballSporter extends Sporter{<\/p>\n<p>    public BasketballSporter() {<br \/>\n    }<\/p>\n<p>    public BasketballSporter(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void study(){<br \/>\n        System.out.println(&#034;\u7bee\u7403\u8fd0\u52a8\u5458\u5728\u5b66\u6253\u7bee\u7403&#034;);<br \/>\n    }<br \/>\n}<\/p>\n<p>[PingPangCoach]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class PingPangCoach extends Coach implements English{<\/p>\n<p>    public PingPangCoach() {<br \/>\n    }<\/p>\n<p>    public PingPangCoach(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void teach(){<br \/>\n        System.out.println(&#034;\u4e52\u4e53\u7403\u6559\u7ec3\u5728\u6559\u6253\u4e52\u4e53\u7403&#034;);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void  speakEnglish(){<br \/>\n        System.out.println(&#034;\u4e52\u4e53\u7403\u6559\u7ec3\u5728\u8bf4\u82f1\u8bed&#034;);<br \/>\n    }<br \/>\n}<\/p>\n<p>[BasketballCoach]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class BasketballCoach extends Coach {<\/p>\n<p>    public BasketballCoach() {<br \/>\n    }<\/p>\n<p>    public BasketballCoach(String name, int age) {<br \/>\n        super(name, age);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void teach(){<br \/>\n        System.out.println(&#034;\u7bee\u7403\u6559\u7ec3\u5728\u6559\u6253\u7bee\u7403&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a05interfacedemo5;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args){<\/p>\n<p>        PingPangSporter pps &#061; new PingPangSporter(&#034;\u5f20\u4e09&#034;,23);<br \/>\n        System.out.println(pps.getName() &#043; &#034;,&#034; &#043; pps.getAge());<br \/>\n        pps.study();<br \/>\n        pps.speakEnglish();<\/p>\n<p>        BasketballCoach bc &#061; new BasketballCoach(&#034;\u674e\u56db&#034;,24);<br \/>\n        System.out.println(bc.getName() &#043; &#034;,&#034; &#043; bc.getAge());<br \/>\n        bc.teach();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>&#xff08;\u8fd0\u884c\u7ed3\u679c\u622a\u56fe&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"188\" src=\"2026-02-06rpm5vwzztcy.png\" width=\"300\" \/><\/p>\n<\/p>\n<h2>\u591a\u5b66\u4e09\u62db&#xff1a;\u63a5\u53e3\u4e2d\u65b0\u589e\u65b9\u6cd5&#xff0c;\u63a5\u53e3\u5e94\u7528\u548c\u9002\u914d\u5668\u8bbe\u8ba1\u6a21\u5f0f<\/h2>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"271\" src=\"2026-02-06laiaguwyrfk.png\" width=\"300\" \/><\/p>\n<\/p>\n<h3>JDK8\u5f00\u59cb\u63a5\u53e3\u4e2d\u65b0\u589e\u7684\u65b9\u6cd5<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"118\" src=\"2026-02-06xyzhdthc1tt.png\" width=\"500\" \/><\/p>\n<\/p>\n<h4>JDK8\u65b0\u589e\u7684\u65b9\u6cd5<\/h4>\n<h5>JDK8\u7684\u65b0\u7279\u6027&#xff1a;\u9ed8\u8ba4\u65b9\u6cd5<\/h5>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"654\" src=\"2026-02-06tfipvswumyh.png\" width=\"1449\" \/><\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Inter]&#xff08;\u63a5\u53e3Interface&#xff09;<\/p>\n<p>package com.itheima.a06interfacedemo6;<\/p>\n<p>public interface Inter {<\/p>\n<p>    public abstract void method();<\/p>\n<p>    public default void show(){<br \/>\n        System.out.println(&#034;\u63a5\u53e3\u4e2d\u7684\u9ed8\u8ba4\u65b9\u6cd5 &#8212; show&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[InterImp]<\/p>\n<p>package com.itheima.a06interfacedemo6;<\/p>\n<p>import java.sql.SQLOutput;<\/p>\n<p>public class InterImp implements Inter{<br \/>\n    &#064;Override<br \/>\n    public void method(){<br \/>\n        System.out.println(&#034;\u5b9e\u73b0\u7c7b\u91cd\u5199\u7684\u62bd\u8c61\u65b9\u6cd5&#034;);<br \/>\n    }<\/p>\n<p>    &#064;Override<br \/>\n    public void show(){<br \/>\n        System.out.println(&#034;\u91cd\u5199\u63a5\u53e3\u4e2d\u7684\u9ed8\u8ba4\u65b9\u6cd5&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a06interfacedemo6;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<br \/>\n        InterImp ii &#061; new InterImp();<br \/>\n        ii.method();<br \/>\n        ii.show();<br \/>\n    }<br \/>\n}<\/p>\n<h5>JDK8\u7684\u65b0\u7279\u6027&#xff1a;\u9759\u6001\u65b9\u6cd5<\/h5>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"295\" src=\"2026-02-06bq5si2evw0o.png\" width=\"500\" \/><\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Inter]<\/p>\n<p>package com.itheima.a07interfacedemo7;<\/p>\n<p>public interface Inter {<br \/>\n    public abstract void method();<\/p>\n<p>    public static void show(){<br \/>\n        System.out.println(&#034;Inter\u63a5\u53e3\u4e2d\u7684\u9759\u6001\u65b9\u6cd5&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[InterImp]<\/p>\n<p>package com.itheima.a07interfacedemo7;<\/p>\n<p>public class InterImp implements Inter{<br \/>\n    &#064;Override<br \/>\n    public void method(){<br \/>\n        System.out.println(&#034;InterImp\u91cd\u5199\u7684\u62bd\u8c61\u65b9\u6cd5&#034;);<br \/>\n    }<\/p>\n<p>    \/\/\u4e0d\u53eb\u91cd\u5199&#xff1a;\u521a\u597d\u5728\u5b9e\u73b0\u7c7b\u4e2d\u8ddf\u63a5\u53e3\u91cc\u9762\u6709\u4e00\u4e2a\u91cd\u540d\u7684\u65b9\u6cd5<br \/>\n    public static void show(){<br \/>\n        System.out.println(&#034;InterImp\u91cd\u5199\u7684\u62bd\u8c61\u65b9\u6cd5&#034;);<br \/>\n    }<br \/>\n}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a07interfacedemo7;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<br \/>\n        \/\/\u8c03\u7528\u63a5\u53e3\u4e2d\u7684\u9759\u6001\u65b9\u6cd5<br \/>\n        Inter.show();<\/p>\n<p>        \/\/\u8c03\u7528\u5b9e\u73b0\u7c7b\u4e2d\u7684\u9759\u6001\u65b9\u6cd5<br \/>\n        InterImp.show();<br \/>\n    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"112\" src=\"2026-02-06aiqd3f55umt.png\" width=\"300\" \/><\/p>\n<\/p>\n<h4>JDK9\u65b0\u589e\u7684\u65b9\u6cd5<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"235\" src=\"2026-02-06w5lli5brdqg.png\" width=\"500\" \/><\/p>\n<\/p>\n<h5>\u3010\u683c\u5f0f1\u3011&#xff1a;\u666e\u901a\u7684\u79c1\u6709\u65b9\u6cd5&#xff08;\u7ed9\u9ed8\u8ba4\u65b9\u6cd5\u670d\u52a1\u7684&#xff09;<\/h5>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>package com.itheima.a08interfacedemo8;<\/p>\n<p>public interface InterA {<\/p>\n<p>    \/\/\u9ed8\u8ba4\u65b9\u6cd5<br \/>\n    public default void show1(){<br \/>\n        System.out.println(&#034;show1\u5f00\u59cb\u6267\u884c\u4e86&#034;);<br \/>\n        show3();<br \/>\n    }<\/p>\n<p>    public default void show2(){<br \/>\n        System.out.println(&#034;show2\u5f00\u59cb\u6267\u884c\u4e86&#034;);<br \/>\n        show3();<br \/>\n    }<\/p>\n<p>    \/\/\u666e\u901a\u7684\u79c1\u6709\u65b9\u6cd5&#xff0c;\u7ed9\u9ed8\u8ba4\u65b9\u6cd5\u670d\u52a1\u7684<br \/>\n    private void show3(){<br \/>\n        System.out.println(&#034;\u8bb0\u5f55\u7a0b\u5e8f\u5728\u8fd0\u884c\u4e2d\u7684\u5404\u79cd\u7ec6\u8282&#xff0c;\u8fd9\u91cc\u6709100\u884c\u4ee3\u7801&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<h5>\u3010\u683c\u5f0f2\u3011&#xff1a;\u9759\u6001\u7684\u79c1\u6709\u65b9\u6cd5&#xff08;\u7ed9\u9759\u6001\u65b9\u6cd5\u670d\u52a1\u7684&#xff09;<\/h5>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>package com.itheima.a08interfacedemo8;<\/p>\n<p>public interface InterB {<br \/>\n    \/\/\u9759\u6001\u65b9\u6cd5<br \/>\n    public static void show1(){<br \/>\n        System.out.println(&#034;show1\u5f00\u59cb\u6267\u884c\u4e86&#034;);<br \/>\n        show4();<br \/>\n    }<\/p>\n<p>    public static void show2(){<br \/>\n        System.out.println(&#034;show2\u5f00\u59cb\u6267\u884c\u4e86&#034;);<br \/>\n        show4();<br \/>\n    }<\/p>\n<p>    \/\/\u9759\u6001\u7684\u79c1\u6709\u65b9\u6cd5&#xff0c;\u7ed9\u9759\u6001\u65b9\u6cd5\u670d\u52a1\u7684<br \/>\n    private static void show4(){<br \/>\n        System.out.println(&#034;\u8bb0\u5f55\u7a0b\u5e8f\u5728\u8fd0\u884c\u4e2d\u7684\u5404\u79cd\u7ec6\u8282&#xff0c;\u8fd9\u91cc\u6709100\u884c\u4ee3\u7801&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"583\" src=\"2026-02-06dzs5pltlry0.png\" width=\"1697\" \/><\/p>\n<\/p>\n<h3>\u63a5\u53e3\u7684\u5e94\u7528<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"645\" src=\"2026-02-0600s4vl0x1rl.png\" width=\"1799\" \/><\/p>\n<\/p>\n<h5>\u603b\u7ed3<\/h5>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"630\" src=\"2026-02-06lqzhgwdfugw.png\" width=\"1737\" \/><\/p>\n<\/p>\n<h3>\u9002\u914d\u5668\u8bbe\u8ba1\u6a21\u5f0f<\/h3>\n<h4>\u8bbe\u8ba1\u6a21\u5f0f\u548c\u9002\u914d\u5668\u8bbe\u8ba1\u6a21\u5f0f\u7684\u6982\u5ff5<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"397\" src=\"2026-02-06dbiz4fs3nks.png\" width=\"1622\" \/><\/p>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u5728\u5b9e\u73b0\u7c7b\u548c\u63a5\u53e3\u4e2d\u6dfb\u52a0\u4e86\u7b2c\u4e09\u8005<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Inter]<\/p>\n<p>package com.itheima.a09interfacedemo9;<\/p>\n<p>public interface Inter {<br \/>\n    public abstract void method1();<br \/>\n    public abstract void method2();<br \/>\n    public abstract void method3();<br \/>\n    public abstract void method4();<br \/>\n    public abstract void method5();<br \/>\n    public abstract void method6();<br \/>\n    public abstract void method7();<br \/>\n    public abstract void method8();<br \/>\n    public abstract void method9();<br \/>\n    public abstract void method10();<br \/>\n}<\/p>\n<p>[InterAdapter]<\/p>\n<p>package com.itheima.a09interfacedemo9;<\/p>\n<p>public abstract class InterAdapter implements Inter{<\/p>\n<p>    &#064;Override<br \/>\n    public void method1() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method2() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method3() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method4() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method5() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method6() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method7() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method8() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method9() {<\/p>\n<p>    }<\/p>\n<p>    &#064;Override<br \/>\n    public void method10() {<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>[InterImp]<\/p>\n<p>package com.itheima.a09interfacedemo9;<\/p>\n<p>public class InterImp extends InterAdapter{<\/p>\n<p>    \/\/\u9700\u8981\u7528\u5230\u54ea\u4e2a\u65b9\u6cd5&#xff0c;\u5c31\u91cd\u5199\u54ea\u4e2a\u65b9\u6cd5<br \/>\n    &#064;Override<br \/>\n    public void method5(){<br \/>\n        System.out.println(&#034;\u53ea\u8981\u7528method5&#034;);<br \/>\n    }<\/p>\n<p>}<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"614\" src=\"2026-02-063tdieuce4nn.png\" width=\"1736\" \/><\/p>\n<\/p>\n<h2>\u521d\u8bc6\u5185\u90e8\u7c7b<\/h2>\n<h3>\u4ec0\u4e48\u662f\u5185\u90e8\u7c7b&#xff1f;<\/h3>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"508\" src=\"2026-02-06uom2nfyitzf.png\" width=\"1727\" \/><\/p>\n<\/p>\n<h3>\u4e3a\u4ec0\u4e48\u8981\u5b66\u4e60\u5185\u90e8\u7c7b&#xff1f;<\/h3>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"811\" src=\"2026-02-06bwykoan4tla.png\" width=\"1763\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"992\" src=\"2026-02-06pf1hxz0xfor.png\" width=\"1656\" \/><\/p>\n<p>[Car]<\/p>\n<p>package com.itheima.a01interclass1;<\/p>\n<p>public class Car {<br \/>\n    String carName;<br \/>\n    int carAge;<br \/>\n    String carColor;<\/p>\n<p>    public void show(Car this){<br \/>\n        \/\/\u662f\u6253\u5370\u8c03\u7528\u8005\u8f66\u7684\u540d\u5b57<br \/>\n        System.out.println(this.carName);<br \/>\n        Engine e &#061; new Engine();<br \/>\n        System.out.println(e.engineName);<br \/>\n    }<\/p>\n<p>    class Engine{<br \/>\n        String engineName;<br \/>\n        int engineAge;<\/p>\n<p>        public void show(){<br \/>\n            System.out.println(engineName);<br \/>\n            System.out.println(carName);<br \/>\n        }<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a01interclass1;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        Car c &#061; new Car();<br \/>\n        c.carName &#061; &#034;\u51ef\u8fea\u62c9\u514b&#034;;<br \/>\n        c.carAge &#061; 1;<br \/>\n        c.carColor &#061; &#034;\u9ed1&#034;;<\/p>\n<p>        c.show();<br \/>\n    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"121\" src=\"2026-02-06g5oqrbr2bm5.png\" width=\"300\" \/><\/p>\n<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"512\" src=\"2026-02-06nxiut0jbajk.png\" width=\"1768\" \/><\/p>\n<\/p>\n<h2>\u5185\u90e8\u7c7b\u7684\u5206\u7c7b<\/h2>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"153\" src=\"2026-02-06gijqerjr3d0.png\" width=\"300\" \/><\/p>\n<\/p>\n<h3>\u6210\u5458\u5185\u90e8\u7c7b<\/h3>\n<h4>\u6210\u5458\u5185\u90e8\u7c7b\u7684\u4ee3\u7801\u5982\u4f55\u4e66\u5199<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"787\" src=\"2026-02-06jjep5kermm2.png\" width=\"1607\" \/><\/p>\n<\/p>\n<h4>\u5982\u4f55\u521b\u5efa\u6210\u5458\u5185\u90e8\u7c7b\u7684\u5bf9\u8c61<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"192\" src=\"2026-02-06touthn3d453.png\" width=\"500\" \/><\/p>\n<h5>\u65b9\u5f0f\u4e00&#xff1a;<\/h5>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 \u5728\u5916\u90e8\u7c7b\u4e2d\u7f16\u5199\u65b9\u6cd5&#xff0c;\u5bf9\u5916\u63d0\u4f9b\u5185\u90e8\u7c7b\u7684\u5bf9\u8c61&#xff08;private&#xff09;<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"534\" src=\"2026-02-06sxhzd4jh5w4.png\" width=\"1452\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Outer]<\/p>\n<p>package com.itheima.a02interclassdemo2;<\/p>\n<p>public class Outer {<br \/>\n    String name;<\/p>\n<p>    private class Inner{<\/p>\n<p>    }<\/p>\n<p>    public Inner getInstance(){<br \/>\n        return new Inner();<br \/>\n    }<br \/>\n}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a02interclassdemo2;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        Outer o &#061; new Outer();<br \/>\n        System.out.println(o.getInstance());<\/p>\n<p>    }<br \/>\n}<\/p>\n<h5>\u65b9\u5f0f\u4e8c&#xff1a;<\/h5>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u76f4\u63a5\u521b\u5efa\u683c\u5f0f&#xff1a;\u5916\u90e8\u7c7b\u540d.\u5185\u90e8\u7c7b\u540d \u5bf9\u8c61\u540d &#061; \u5916\u90e8\u7c7b\u5bf9\u8c61.\u5185\u90e8\u7c7b\u5bf9\u8c61;<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 Outer.Inner oi &#061; new Outer().new Inner();<\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"402\" src=\"2026-02-06m312apgxkd5.png\" width=\"1799\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Outer]<\/p>\n<p>package com.itheima.a03interclassdemo3;<\/p>\n<p>public class Outer {<br \/>\n    String name;<\/p>\n<p>    public class Inner{<\/p>\n<p>    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a03interclassdemo3;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        Outer.Inner oi &#061; new Outer().new Inner();<\/p>\n<p>    }<br \/>\n}<\/p>\n<h4>\u6210\u5458\u5185\u90e8\u7c7b\u5982\u4f55\u83b7\u53d6\u6210\u5458\u5916\u90e8\u7c7b\u7684\u6210\u5458\u53d8\u91cf<\/h4>\n<p>\u7ec3\u4e60&#xff1a;\u6210\u5458\u5185\u90e8\u7c7b-\u9762\u8bd5\u9898<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"327\" src=\"2026-02-06d1jq54umknn.png\" width=\"500\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"697\" src=\"2026-02-06ul4hoptzdqk.png\" width=\"1737\" \/><\/p>\n<p>[Outer]<\/p>\n<p>package com.itheima.a04interclassdemo4;<\/p>\n<p>public class Outer {<br \/>\n    private int a &#061; 10;<\/p>\n<p>    class Inner{<br \/>\n        private int a &#061; 20;<\/p>\n<p>        public void show(){<br \/>\n            int a &#061; 30;<br \/>\n            System.out.println(Outer.this.a);\/\/10<br \/>\n            System.out.println(this.a);\/\/20<br \/>\n            System.out.println(a);\/\/30<\/p>\n<p>        }<\/p>\n<p>    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a04interclassdemo4;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<br \/>\n        \/\/\u521b\u5efa\u5185\u90e8\u7c7b\u7684\u5bf9\u8c61&#xff0c;\u5e76\u8c03\u7528show()\u65b9\u6cd5<br \/>\n        Outer.Inner oi &#061; new Outer().new Inner();<br \/>\n        oi.show();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"143\" src=\"2026-02-06lp31fb2gfg0.png\" width=\"300\" \/><\/p>\n<\/p>\n<h4>\u5185\u90e8\u7c7b\u7684\u5185\u5b58\u56fe<\/h4>\n<p>&#xff08;\u7b2c\u4e00\u6b65&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"858\" src=\"2026-02-06tplwzv4cv4r.png\" width=\"1956\" \/><\/p>\n<p>&#xff08;\u7b2c\u4e8c\u6b65&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"839\" src=\"2026-02-06uxpidz4h2aa.png\" width=\"1963\" \/><\/p>\n<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"754\" src=\"2026-02-065ulerutzonj.png\" width=\"1851\" \/><\/p>\n<\/p>\n<h3>\u9759\u6001\u5185\u90e8\u7c7b<\/h3>\n<h4>\u4ec0\u4e48\u662f\u9759\u6001\u5185\u90e8\u7c7b&#xff1f;<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"834\" src=\"2026-02-061b5wotj2yhs.png\" width=\"1597\" \/><\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"593\" src=\"2026-02-06a2l4ientwsr.png\" width=\"1643\" \/><\/p>\n<p>[Outer]<\/p>\n<p>package com.itheima.a05interclassdemo5;<\/p>\n<p>public class Outer {<\/p>\n<p>    \/\/\u9759\u6001\u5185\u90e8\u7c7b<br \/>\n    static class Inner{<br \/>\n       public void show1(){<br \/>\n           System.out.println(&#034;\u975e\u9759\u6001\u65b9\u6cd5\u88ab\u8c03\u7528\u4e86&#034;);<br \/>\n       }<br \/>\n       public static void show2(){<br \/>\n           System.out.println(&#034;\u9759\u6001\u65b9\u6cd5\u88ab\u8c03\u7528\u4e86&#034;);<br \/>\n       }<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a05interclassdemo5;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        Outer.Inner oi &#061; new Outer.Inner();<br \/>\n        oi.show1();<\/p>\n<p>        Outer.Inner.show2();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"173\" src=\"2026-02-06iy1aowojhft.png\" width=\"431\" \/><\/p>\n<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"578\" src=\"2026-02-061dv1o0ezbk4.png\" width=\"1475\" \/><\/p>\n<\/p>\n<h3>\u5c40\u90e8\u5185\u90e8\u7c7b<\/h3>\n<h4>\u4ec0\u4e48\u662f\u5c40\u90e8\u5185\u90e8\u7c7b&#xff1f;<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"235\" src=\"2026-02-06pwhnkeboayl.png\" width=\"1308\" \/><\/p>\n<p>\u4f8b\u5982&#xff1a;<\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"1058\" src=\"2026-02-0643w5jubfehk.png\" width=\"1669\" \/><\/p>\n<p>[Outer]<\/p>\n<p>package com.itheima.a06interclassdemo6;<\/p>\n<p>public class Outer {<br \/>\n    int b &#061; 20;<br \/>\n    public void show(){<br \/>\n        int a &#061; 10;<br \/>\n        \/\/\u5c40\u90e8\u5185\u90e8\u7c7b<br \/>\n        class Inner{<br \/>\n            String name;<br \/>\n            int age;<\/p>\n<p>            public void method1(){<br \/>\n                System.out.println(a);<br \/>\n                System.out.println(b);<br \/>\n                System.out.println(&#034;\u5c40\u90e8\u5185\u90e8\u7c7b\u4e2d\u7684method1\u65b9\u6cd5&#034;);<br \/>\n            }<\/p>\n<p>            public static void method2(){<br \/>\n                System.out.println(&#034;\u5c40\u90e8\u5185\u90e8\u7c7b\u4e2d\u7684method2\u65b9\u6cd5&#034;);<br \/>\n            }<\/p>\n<p>        }<br \/>\n        Inner i &#061; new Inner();<br \/>\n        System.out.println(i.name);<br \/>\n        System.out.println(i.age);<br \/>\n        i.method1();<br \/>\n        Inner.method2();<br \/>\n    }<\/p>\n<p>}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a06interclassdemo6;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        Outer o &#061; new Outer();<br \/>\n        o.show();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"240\" src=\"2026-02-06lmtqxnqr2ij.png\" width=\"400\" \/><\/p>\n<\/p>\n<h3>\u533f\u540d\u5185\u90e8\u7c7b<\/h3>\n<h4>\u4ec0\u4e48\u662f\u533f\u540d\u5185\u90e8\u7c7b&#xff1f;<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"403\" src=\"2026-02-06x50u4cydkrt.png\" width=\"500\" \/><\/p>\n<p><span style=\"color:#be191c\">\u6ce8&#xff1a;<\/span>\u4e0a\u9762\u56fe\u7247\u4e2d\u7ea2\u6846\u5185\u7684\u4ee3\u7801\u6700\u540e\u7f3a\u5c11\u4e00\u4e2a ;<\/p>\n<\/p>\n<h4>\u4f8b1:&#xff08;\u63a5\u53e3-\u5b9e\u73b0\u5173\u7cfb&#xff09;<\/h4>\n<p>&#xff08;\u5206\u6790&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"816\" src=\"2026-02-06rroarpwmwh4.png\" width=\"1946\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"713\" src=\"2026-02-06kxih4v5bmi4.png\" width=\"1907\" \/><\/p>\n<p>(\u6e90\u4ee3\u7801)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"558\" src=\"2026-02-06qqnsn51yycu.png\" width=\"1785\" \/><\/p>\n<p>[Swim](\u63a5\u53e3interface)<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public interface Swim {<br \/>\n    public abstract void swim();<br \/>\n}<\/p>\n<p>[Test]<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public class Test {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        \/\/\u7f16\u5199\u533f\u540d\u5185\u90e8\u7c7b\u7684\u65b9\u6cd5<br \/>\n        new Swim(){<br \/>\n            &#064;Override<br \/>\n            public void swim() {<br \/>\n                System.out.println(&#034;\u91cd\u5199swim\u65b9\u6cd5&#034;);<br \/>\n            }<br \/>\n        };<\/p>\n<p>    }<br \/>\n}<\/p>\n<h4>\u4f8b2&#xff1a;&#xff08;\u7c7b-\u7ee7\u627f\u5173\u7cfb&#xff09;<\/h4>\n<p>&#xff08;\u5206\u6790&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"688\" src=\"2026-02-06f5hziexnxrw.png\" width=\"1831\" \/><\/p>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"524\" src=\"2026-02-060xkr4wwyi13.png\" width=\"1767\" \/><\/p>\n<p>[Animal]<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public abstract class  Animal {<br \/>\n    public abstract void eat();<br \/>\n}<\/p>\n<p>[Test2]<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public class Test2 {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        new Animal(){<br \/>\n            &#064;Override<br \/>\n            public void eat() {<br \/>\n                System.out.println(&#034;\u91cd\u5199eat\u65b9\u6cd5&#034;);<br \/>\n            }<br \/>\n        };<\/p>\n<p>    }<br \/>\n}<\/p>\n<h4>\u4f8b\u5982&#xff1a;&#xff08;\u5176\u4ed6&#xff09;<\/h4>\n<p>&#xff08;\u6e90\u4ee3\u7801&#xff09;<\/p>\n<p>[Swim]<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public interface Swim {<br \/>\n    public abstract void swim();<br \/>\n}<\/p>\n<p>[Test3]<\/p>\n<p>package com.itheima.a07interclassdemo7;<\/p>\n<p>public class Test3 {<br \/>\n    public static void main(String[] args) {<\/p>\n<p>        \/\/\u6574\u4f53\u6211\u4eec\u53ef\u4ee5\u7406\u89e3\u4e3aSwim\u63a5\u53e3\u7684\u5b9e\u73b0\u7c7b\u5bf9\u8c61<br \/>\n        \/\/\u63a5\u53e3\u591a\u6001<br \/>\n        Swim s  &#061; new Swim() {<\/p>\n<p>            &#064;Override<br \/>\n            public void swim() {<br \/>\n                System.out.println(&#034;\u91cd\u5199swim\u65b9\u6cd5&#034;);<br \/>\n            }<\/p>\n<p>        };<br \/>\n        \/\/\u7f16\u8bd1\u770b\u5de6\u8fb9&#xff0c;\u8fd0\u884c\u770b\u53f3\u8fb9<br \/>\n        s.swim();<\/p>\n<p>        new Swim() {<\/p>\n<p>            &#064;Override<br \/>\n            public void swim() {<br \/>\n                System.out.println(&#034;\u91cd\u5199swim\u65b9\u6cd5&#034;);<br \/>\n            }<\/p>\n<p>        }.swim();<\/p>\n<p>    }<br \/>\n}<\/p>\n<p>(\u8fd0\u884c\u7ed3\u679c\u622a\u56fe)<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"119\" src=\"2026-02-060vpwxzdviqx.png\" width=\"300\" \/><\/p>\n<\/p>\n<h4>\u603b\u7ed3<\/h4>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"848\" src=\"2026-02-06eq3gftrbwax.png\" width=\"1826\" \/><\/p>\n<\/p>\n<\/p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6982\u5ff5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u5b9a\u4e49\u683c\u5f0f\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6ce8\u610f\u4e8b\u9879\u4f8b\u5982&#xff1a;&#xff08;\u6e90\u4ee3\u7801&#xff09;[Person]package com.itheima.a01abstractdemo1;public abstract class Person {private String name;private int age;\/\/\u5f53\u521b\u5efa\u5b50\u7c7b\u5bf9\u8c61\u65f6&#xff0c;\u7ed9\u5c5e\u6027\u8d4b\u503c\u7684public Person() {}public Person<\/p>\n","protected":false},"author":2,"featured_media":72812,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[99,190],"topic":[],"class_list":["post-72832","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-java","tag-190"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/72832.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6982\u5ff5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u5b9a\u4e49\u683c\u5f0f\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6ce8\u610f\u4e8b\u9879\u4f8b\u5982&#xff1a;&#xff08;\u6e90\u4ee3\u7801&#xff09;[Person]package com.itheima.a01abstractdemo1;public abstract class Person {private String name;private int age;\/\/\u5f53\u521b\u5efa\u5b50\u7c7b\u5bf9\u8c61\u65f6&#xff0c;\u7ed9\u5c5e\u6027\u8d4b\u503c\u7684public Person() {}public Person\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/72832.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-02-06T09:00:09+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206085959-6985ad8f62128.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/72832.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/72832.html\",\"name\":\"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-02-06T09:00:09+00:00\",\"dateModified\":\"2026-02-06T09:00:09+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/72832.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/72832.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/72832.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/72832.html","og_locale":"zh_CN","og_type":"article","og_title":"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6982\u5ff5\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u5b9a\u4e49\u683c\u5f0f\u62bd\u8c61\u7c7b\u548c\u62bd\u8c61\u65b9\u6cd5\u7684\u6ce8\u610f\u4e8b\u9879\u4f8b\u5982&#xff1a;&#xff08;\u6e90\u4ee3\u7801&#xff09;[Person]package com.itheima.a01abstractdemo1;public abstract class Person {private String name;private int age;\/\/\u5f53\u521b\u5efa\u5b50\u7c7b\u5bf9\u8c61\u65f6&#xff0c;\u7ed9\u5c5e\u6027\u8d4b\u503c\u7684public Person() {}public Person","og_url":"https:\/\/www.wsisp.com\/helps\/72832.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-02-06T09:00:09+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/02\/20260206085959-6985ad8f62128.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"9 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/72832.html","url":"https:\/\/www.wsisp.com\/helps\/72832.html","name":"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-02-06T09:00:09+00:00","dateModified":"2026-02-06T09:00:09+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/72832.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/72832.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/72832.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"[\u4ece0\u5f00\u59cb\u5b66Java|\u7b2c\u5341\u4e94\u5929]\u9762\u5411\u5bf9\u8c61\u8fdb\u9636\uff08\u62bd\u8c61\u7c7b&amp;\u63a5\u53e3&amp;\u5185\u90e8\u7c7b\uff09"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/72832","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=72832"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/72832\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/72812"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=72832"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=72832"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=72832"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=72832"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}