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

📄 ticketdo.java

📁 This book shows you how to use JBoss to develop EJB projects.
💻 JAVA
字号:
package com.titan.travelagent;
     
import com.titan.domain.Cruise;
import com.titan.domain.Cabin;
import com.titan.domain.Customer;
     
public class TicketDO implements java.io.Serializable {
    public int customerID;
    public int cruiseID;
    public int cabinID;
    public double price;
    public String description;
    
    public TicketDO(Customer customer, Cruise cruise, 
        Cabin cabin, double price) {        
            description = customer.getFirstName( )+
                " " + customer.getLastName( ) + 
                " has been booked for the "
                + cruise.getName( ) + 
                " cruise on ship " + 
                  cruise.getShip( ).getName( ) + ".\n" +  
                " Your accommodations include " + 
                  cabin.getName( ) + 
                " a " + cabin.getBedCount( ) + 
                " bed cabin on deck level " + cabin.getDeckLevel( ) + 
                ".\n Total charge = " + price;
            customerID = customer.getId();
            cruiseID = cruise.getId();
            cabinID = cabin.getId();
            this.price = price;
        }
        
    public String toString( ) {
        return description;
    }
}

⌨️ 快捷键说明

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