登录
首页 » Java » Exe4_3

Exe4_3

于 2015-06-14 发布 文件大小:1KB
0 185
下载积分: 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 个回复

  • 0610qizhi
    个人求职管理系统(personal job management system)
    2005-01-07 15:45:37下载
    积分:1
  • video-edit-process
    视频剪辑处理,简易的操作界面,友好的帮助提示,让你轻轻松松对视频文件进行剪辑处理.(video clips, simple interface, with the help of friendly tips Let your light-hearted video clips document processing.)
    2007-04-24 13:25:31下载
    积分:1
  • test
    part1 (1)可以在“请输入文件路径和名称:”后面的文本框中输入文件名和路径。 (2)可以在文本区中写文本。 (3)可以在“请输入需要追加的内容:”后面的文本域中输入内容,按回车键之后,其中的内容会添加到文本区中(添加的内容另起一行)。 (4)单击“将文本区的内容写入文件”按钮,文本区中的内容就会被写到指定的文件中。 part2 (1)窗体的标题是“猜数字小游戏”。 (2)单击“得到一个随机数”按钮,系统会产生一个1~10之间的随机整数(使用Math类的方法random( ))。 (3)在“输入您的猜测:”后面的文本框中输入你要猜测的整数,之后单击“确定”按钮。 (4)对你猜测的整数,图形用户界面的最下面会有提示信息,没有猜的时候,显示“无反馈信息”,如果猜大了,显示“猜大了”,如果猜小了,显示“猜小了”,如果猜对了,显示“猜对了”。(其中,蓝色字体是JLabel类的对象调用方法setForeground(Color.blue)实现的。)(Java Simple Graphic Interface)
    2020-12-11 15:59:18下载
    积分:1
  • Utile
    根据值来取ID,或者根据ID来取值,便于两者之间的转换(Exchange from ID and values, we can tanslate between ID and values easily. )
    2005-07-12 15:19:32下载
    积分:1
  • KeyStoreSpi
    Key Store Spi is the Service Provider Interface ( SPI) definition for Key Store.
    2013-11-04 09:31:24下载
    积分:1
  • android-samples-master
    说明:  谷歌地图的官方demo,支持各种移动设备开发,以及穿戴设备地图(The official demo of Google Maps supports mobile device development and wearing device maps)
    2020-06-20 10:40:01下载
    积分:1
  • student
    学生成绩管理,java编的,适合初学者做课程设计。(Student performance management, java series, suitable for beginners to do the curriculum design.)
    2008-12-24 19:56:10下载
    积分:1
  • esp8266
    说明:  hye all i very need power jack dc supply
    2019-03-18 23:03:32下载
    积分:1
  • 15612172ems_ui
    模拟EMS—UI的操作,十分不错,请学习(Simulate the operation of EMS-UI, very good, please study)
    2011-08-31 17:36:14下载
    积分:1
  • TryTest42
    人工蜂群代码,用于算法的基础学习,仅供参考。 也可以用来进行java代码的学习(Artificial bee colony code, for the basic learning algorithm. It can also be used to learn java codes)
    2018-06-04 16:05:13下载
    积分:1
  • 696518资源总数
  • 106161会员总数
  • 5今日下载