登录
首页 » Java » Exe4_3

Exe4_3

于 2015-06-14 发布 文件大小:1KB
0 212
下载积分: 1 下载次数: 5

代码说明:

  3.已知车辆(Vehicle)包括机动车(MotoVehicle)和非机动车(NonMotorVehicle)2种。小汽车(Car)、公交车(Bus)等属于机动车,自行车(Bicycle)等属于非机动车。随着能源技术的发展,出现了电动自行车(ElectricBicycle)、电动小汽车(ElectricCar)、天然气公交车(NaturalGasBus)等新型车辆。车辆的共同特征是都能够运行(run),并且有唯一的5位车牌号(LicenseNumber)。机动车的共同特征是采用燃油发动机(FuelEngine),且能够驾驶(drive)。自行车的共同特征是能够骑行(ride)。电动车辆的共同特征是由电池(Battery)驱动。天然气车辆的共同特征是采用天然气(NaturalGas)作为动力。 要求: (1)设计一个类体系描述上述车辆,写出它们的属性和方法。 (2)一家公司(Company)拥有10辆普通小汽车、5辆公交车、2辆电动小汽车和1辆天然气公交车,要求写一个方法listVehicles()显示所有车辆的信息(车牌号以及采用的动力)。 程序文件命名为Exe4_3.java。(3. Known vehicle (Vehicle) including motor vehicle (MotoVehicle) and non-motorized (NonMotorVehicle) 2 species. Cars (Car), bus (Bus), etc. to motor vehicles, bicycles (Bicycle), etc. are non-motor vehicles. With the development of energy technologies, the emergence of electric bicycles (ElectricBicycle), electric cars (ElectricCar), natural gas buses (NaturalGasBus) and other new vehicles. A common feature of the vehicle is able to run (run), and there are only five license plate number (LicenseNumber). Common feature is the use of a motor vehicle fuel engine (FuelEngine), and is capable of driving (drive). Common feature is the ability to ride a bike (ride). Common characteristics of the electric vehicle is driven by a battery (Battery). A common feature is the use of natural gas vehicles (NaturalGas) as the driving force. Claim: (1) describe the design of a class system of the vehicle, write their properties and methods. (2) a company (Company) owns 10 ordinary cars, five buses, )

文件列表:

Exe4_3.java,3496,2014-11-21

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • device-manage
    一个JAVA做的设备管理系统,基本输入,输出操作(a JAVA device manage)
    2011-12-26 22:56:00下载
    积分:1
  • DirectByteBuffer
    DirectByteBuffer extends BaseByteBuffer implements DirectBuffer.
    2014-02-18 12:46:44下载
    积分:1
  • talking
    java版的聊天软件,用于学习java的socket网络编程(java Chat Software)
    2013-12-05 15:06:58下载
    积分:1
  • java-calculator.txt
    实现计算器的功能M+:是计算结果并加上已经储存的数 中断数字输入.M-:从存储器内容中减去当前显示值 中断数字输入.MRC:第一次按下此键将调用存储器内容,第二次按下时清除存储器内容.MR:调用存储器内容.MC:清除存储器内容.(Calculator function)
    2012-12-30 13:00:46下载
    积分:1
  • AccountProject
    一个简单的银行账户管理程序,给新手用来熟悉java与练习java。(A simple bank account management procedures, to the novice to be familiar with Java and Java practice. A simple bank account management procedures, to the novice to be familiar with Java and Java practice. )
    2014-07-16 15:31:44下载
    积分:1
  • TomcatPOracle-connection-pool
    java 连接oracle的连接池示例,对初学者很有用哦(document for java connect oracle:connect pool case)
    2013-12-12 11:13:04下载
    积分:1
  • ee
    it is a very important source of loof study material
    2009-01-04 11:54:26下载
    积分:1
  • 剑指 Offer 题解
    说明:  Sword refers to the Java implementation, a total of 65 to the topic, you can view the topic in the cattle network
    2019-04-26 14:20:34下载
    积分:1
  • Java
    很漂亮的一款列表式显示数据的JAVA源码实例,运行效果图如上所示,JAVA爱好者一定会喜欢哦(Very beautiful a list of data show that the JAVA source code examples, operating results as shown above, JAVA lovers will love Oh)
    2016-12-22 15:10:44下载
    积分:1
  • SwingTest
    此代码实现ping的功能。并且使用图形界面进行实现,使用方便简单。(This code implements the ping function. Implementation and use graphical interface, simple and easy.)
    2010-07-12 16:50:24下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载