码迷,mamicode.com
首页 > 其他好文 > 详细

1.自定义图书类

时间:2016-01-18 09:11:01      阅读:150      评论:0      收藏:0      [点我收藏+]

标签:

package lianxiti;

public class Book {

    private String title;
    private String author;
    private double price;
    
    public Book(String title,String author,double price){
        
        this.title=title;
        
        this.author=author;
        
        this.price=price;
    }
    public String getTitle(){
        return title;
    }
    public String getAuthor(){
        return author;
    }
    public double getPrice(){
        return price;
        
    }
}

 

1.自定义图书类

标签:

原文地址:http://www.cnblogs.com/as1234as/p/5138279.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!