登录
首页 » Java » HardWork

HardWork

于 2010-04-27 发布 文件大小:3KB
0 228
下载积分: 1 下载次数: 0

代码说明:

说明:  上转型对象 1.实验目的 掌握上转型对象的使用。 2. 实验要求 要求有一个abstract类,类名为Employee,Employee的子类有YearWorker、MonthWorker和WeekWorker。YearWorker对象按年领取薪水,MonthWorker按月领取薪水,WeekWorker按周领取薪水。Employee有一个abstract方法: public abstract earnings() 子类必须重写父类的earnings()方法,给出各自领取薪水的具体方式。 有一个Company类,该类用Employee数组作为成员,Employee数组的单元可以是YearWorker对象、MonthWorker对象或WeekWorker对象的上转型对象。程序能输出Company对象一年需支付的薪水总额。 (The transformation of the object 1. Purpose of the experiment used to grasp the transformation of the object. 2. Experiment requires a abstract class requirements, class named Employee, Employee of the child class has YearWorker, MonthWorker and WeekWorker. YearWorker object to receive annual salary, MonthWorker receive a monthly salary, WeekWorker receive weekly salary. Employee one abstract method: public abstract earnings () sub-class must override the parent class of earnings () method, given their own specific way of receiving pay. A Company class, such as members with an array of Employee, Employee of the array elements can be YearWorker object, MonthWorker object or objects on the transformation of objects WeekWorker. Company object program can output a year' s salary to be paid the total amount.)

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

发表评论

0 个回复

  • MAT
    如何从CSV、文本文件中读取记录波形 并返回波形数据 逐行读取文件内容 (How CSV, text file read and returns the waveform data recorded waveforms to read file contents line by line)
    2011-08-17 10:11:16下载
    积分:1
  • solar-cell
    solar,光伏发电单元,自动生成输出特性曲线(solar, photovoltaic cells, automatically generate output characteristic curve)
    2015-01-14 10:27:45下载
    积分:1
  • matabgui
    上传的源代码为《精通matlab GUI设计》的源代码(From the source code as " proficient in matlab GUI design" of the source code)
    2010-08-24 13:13:23下载
    积分:1
  • matlab
    双线性iir数字滤波器的设计。。。。。。。(Bilinear design of iir digital filter)
    2009-04-23 18:17:02下载
    积分:1
  • web
    一个接地电网simulink模型,可以直接运行(A grounding grid simulink model can be run directly)
    2014-02-24 23:04:33下载
    积分:1
  • ForResUnd
    single degree of freedom vibration unbalance
    2010-09-17 16:49:01下载
    积分:1
  • ovrlpsav
    %realize overlapped-save method %y:output sequence %x:input seqence %h:filter impulse response sequence %N:length of each segment %重叠保留法实现分段卷积 ( Realize overlapped-save method y: output sequence x: input seqence h: filter impulse response sequence N: length of each segment overlap to retain sub-convolution method)
    2006-11-05 10:41:28下载
    积分:1
  • mfsug
    this code is one fuzzy inference system with 9 rulle that applied in the control system
    2013-03-11 16:29:40下载
    积分:1
  • Sattellite4
    code for sattelite calculaton
    2013-09-14 17:33:51下载
    积分:1
  • 21382
    PPG data, photoplethysmographic data containing PPG of subjects doing various exercises
    2015-03-14 02:47:24下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载