⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 bookentry.java

📁 网络聊天程序
💻 JAVA
字号:
package Java.ICQ;// BookEntry.java// A simple aggregate class to store a book's title and icon.//import javax.swing.ImageIcon;public class BookEntry {    private final String title;    private final String imagePath;    private ImageIcon image;    public BookEntry(String title, String imagePath)     {        this.title = title;        this.imagePath = imagePath;            }    public String getTitle()     {    	 return title;     }        public ImageIcon getImage()     {        if (image == null)         {            image = new ImageIcon(imagePath);        }        return image;             }    // Override standard toString method to give a useful result    public String toString()     {    	 return title;     }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -