登陆注册
27082000000033

第33章 Software Engineering(3)

A fundamental concept in software engineering is the software life cycle. Software, like many other products, goes through a cycle of repeating phases (Figure 5-1).

Software is first developed by a group of developers/programmers. Usually, it is in use for a while before modifications are necessary. Modification is often needed due to errors found in the software, changes in the roles or laws, or changes in the company itself. The software should be modified before further use. These two steps use and modify, continue until the software becomes obsolete. By "obsolete," we mean the software loses its validity because of inefficiency, obsolescence of the language, major changes in the company, or other factors. Some examples of software developments that normally go through this cycle are student registration systems, billing systems, and accounting systems.

The development process in the software life cycle involves four phases:analysis, design, implementation, and testing. Figure 5-2 shows these phases as part of the development process.

The development process starts with the analysis phase, which shows what the package should do. In this phase, the systems analyst defines requirements that specify what the proposed system is to accomplish. The requirements are usually stated in terms that the user understands. There are four steps in the analysis phase:define the user, define the needs, define the requirements, and define the methods.

A software package may be designed for a generic user or a specific user. For example, an accounting package may be created for use by any firm. On the other hand, a customized banking package may be created for a specific bank. The user of the package must be clearly defined.

After the user has been identified, the analysts clearly define the needs. In this step, the best answer comes from the user. The user, or the representative of the user, clearly defines his/her expectations of the package.

Based on the needs of the user, the analyst can exactly define the requirements for the system. For example, if a package is to print checks at the end of the month for each employee, what level of security and accuracy should be implemented?

Finally, after the requirements are defined in clear terms, the analyst can choose the appropriate methods to meet those requirements.

The design phase defines how the system will accomplish what was defined in the analysis phase. In the design phase, the systems are determined, and the design of the files and the databases is completed.

There are two types of testing: black box and white box. Black box testing is done by the system test engineer and the user. White box testing is the responsibility of the programmer.

Black box testing gets its name from the concept of testing a program without knowing what is inside it and without knowing how it works. In other words, the program is like a black box that you can't see into.

Simply stated, black box test plans are developed by looking only at the requirements statement. This is why it is so important to have a good set of requirements. The test engineer uses these requirements and his or her knowledge of systems development and the user working environment to cream a test plan. This plan will then be used when the system is tested as a whole. You should ask to see these test plans before you write your program.

Whereas black box testing assumes that nothing is known about the program, white box testing assumes that you know everything about the program. In this case, the program is like a glass house in which everything is visible.

White box testing is the responsibility of the programmer, who knows exactly what is going on inside the program. You must make sure that every instruction and every possible situation have been tested. That is not a ****** task!

Experience will help a programmer design good test data, but one thing that she can do from the start is to get in the habit of writing test plans. She should start her test plan when she is in the design stage. As she builds her structure chart, she should ask herself what situations, especially unusual situations, she needs to test for and make a note of them immediately. She may not remember an hour later.

When she is writing her flowcharts, she should review them with an eye toward test cases and make notes of the cases she needs.

When it comes time to construct her test cases, she should review her notes and organize them into logical sets. Except for very ****** student programs, one set of test data will not completely validate a program. For large-scale development projects: 20, 30, or more test cases may need to be run to validate a program.

Finally, while she is testing, she will think of more test cases. Again, she should write them down and incorporate them into her test plan. After her program is finished and in production, she will need the test plans again when she modifies the program.

【New Words】

life cycle

生命周期

test case

测试用例

validate

确认,证实,验证

algorithmic

算法的

modularity 模块性,模块化

structure chart

结构图

generic

通用的,一般的,类的 package

程序包

validity

有效性

obsolescence

过时,淘汰

5.2 The Methods of Modern Software Design

We shall briefly discuss some topics in modern software designs such as top-down design/programming, bottom-up design/programming, and structured design/programming.

Top-down design is basically a decomposition process, which focuses on the flow of control or on the control structure of the program. The first step is to study the overall aspects of the task at hand and to break it down into a number of modules (perhaps 3 to 10). The second step is to break down each one of these modules further into independent sub modules. The process repeats until you can obtain modules that are small enough to grasp mentally and to code at one sitting in a straightforward, uncomplicated way. A multi-level logic/control structure is thus formed. Clearly, some modules may extend through several levels.

同类推荐
  • 英语PARTY——幽默加油站

    英语PARTY——幽默加油站

    本套书籍带你领略英语世界风景,感悟英语学习氛围,有助于英语学习。
  • Stories by English Authors in London

    Stories by English Authors in London

    Frequently I have to ask myself in the street for the name of the man I bowed to just now, and then, before I can answer, the wind of the first corner blows him from my memory.
  • 谜语绕口令英语

    谜语绕口令英语

    谜语和绕口令是英语文学中两种比较独特的语言艺术形式。前者既饶有情趣,又可以启发心智,增进思考和想像能力;后者结构巧妙,诙谐风趣,富有音乐性,最适合口头背诵,深受广大英语读者的喜爱。
  • 日常286词玩转英语口语

    日常286词玩转英语口语

    作者在本书中收录了英美人日常生活交流中使用最高频的数近300个英语单词,再由单词引申到常用短语、俚语,进而由每个短语,俚语引出句子,然后是实用场景对话范例。这样把我们记忆中的两三个单词系统有效地转换成句子和情景对话,从而达到与老外交流的目的。学一次就要学透彻! 本书的中文引导句表现了每个词要表达的基本意思,只要从引导词出发,就能轻易地延伸出具体的表达方式,从而进行交流对话。完成单词、句子和对话的三重记忆。作者希望本书可以提升读者英语会话沟通技巧,在各位开口说英语、与人交流的时候,能联想到本书中的场景单词直接索引, 让您的英语口语表达跟英美人一样的地道。
  • 高考英语词汇考点手册

    高考英语词汇考点手册

    词汇是语言学习的重要组成部分。听、说、读、写、译诸项技能的培养与提高,都离不开扎实的词汇基础。《高考英语词汇考点手册》堪称一本多功能的英语工具书。相信《高考英语词汇考点手册》给你提供的是一条学习和记忆单词的有效算途径,能让你收入到意想不到的效果。
热门推荐
  • 快穿之系统是个小怂包

    快穿之系统是个小怂包

    女强文,全文架空,没有cp,系统白狼一直知道自己宿主不简单……所以他遇到自己中意的便开始预谋“跳槽”不过幸运的是它拥有纯净灵魂导致没有什么大代价……——【宿主,任务万千任你选……】你就做一个任务让我有点业绩吧。“不选”【……】【宿主,原主虽然厌世,但其愿望没有灭了世界……】万千小任务也没有一个是灭世“我乐意”【……】这竟然叫我无法反驳【宿主,原主愿望是成为皇帝的女人,你这……】系统一言难尽的看着身穿龙袍的女人。“我难道不是成为皇帝了嘛?有意见……”潜台词不言而喻。【没有没有。】系统连忙否认。【宿主,你手上的是什么?】“魔法球啊”【宿主,这个界面是没有魔法元素的科技界面……】“知道啊”【……】……本文没有cp,没有cp,没有cp,重要的事情说三遍,阡陌喜欢干净的事物,对干净的事物会比较宽容……
  • 七界传说外传之太阴重现

    七界传说外传之太阴重现

    川大才子陆杨鼎力打造!天龙灵脉之处。陆家祖先神灵重现。诡异石棺秘图忽放光华,竞预言天灾将至,毁天灭地。就在此时,天降异相,天地失色,无数妖物冲破封印,流落人间,为患无穷。原本风平浪静的修真界,顷刻间狼籍一片。生灵涂炭。傲雪,云枫等人更是不见踪影,唯重伤在地的李宏飞有一息尚存。原来是一群异常神秘的黑衣人所为,他们道法诡异。虽然闻所未闻,却出奇的高强。陆云此时焦急的寻找着张傲雪等人,可是此时天象大变,太阴重现,天上显示出几行血淋淋的大字:“太阴重现,祸患又起,是敌是友。皆为定数。”
  • 大魔王追了我两世

    大魔王追了我两世

    姜乔是个桃花妖是个美得张扬的桃花妖偏偏是由个清心寡欲的和尚养着,可有没有让人就得不对,好像本应如此可尽管是由和尚养着,那根子里的妖性却是却是愈发的厉害人间的小书生个个对她心生好感,妖界的那些个妖艳的大妖对她爱护得紧,就连天界耍刀舞剑的将军也对她高看一等原本过着安逸生活的小桃花妖发现养着她的小和尚越来越不像个正经和尚了
  • 快穿系统宿主你悠着点儿

    快穿系统宿主你悠着点儿

    简汐:“地下格局该变了。”477:“快去做任务!!!”简汐:“他们为什么总是追我呢?唉,都怪我过分美丽”477:“快去做任务!!!”简汐:“好想把他们拆开呀!”477:“快去做任务!!!”477:“诶?你这神器哪儿来的?!”简汐:嘘,要保密哦!477:这是古代!!!天上飞的是什么?简汐:飞船呀!477:“啊啊啊!!!必须申请能量限制!!!”
  • 开错外挂怎么办

    开错外挂怎么办

    穿越到了电影的世界。想做一个好人,却开错了反派挂。
  • 贪恋红尘三千尺

    贪恋红尘三千尺

    本是青灯不归客,却因浊酒恋红尘。人有生老三千疾,唯有相思不可医。佛曰:缘来缘去,皆是天意;缘深缘浅,皆是宿命。她本是出家女,一心只想着远离凡尘逍遥自在。不曾想有朝一日唯一的一次下山随手救下一人竟是改变自己的一生。而她与他的相识,不过是为了印证,相识只是孽缘一场。
  • 玩命的教书先生

    玩命的教书先生

    每一个向命运挣扎过的人都值得尊敬,象牙塔里的高校教师也不例外。
  • 灵魂交易站

    灵魂交易站

    被骗了身心,遭男票抛弃,怎么办?被未婚夫欺骗卖去他国,怎么办?...........你想报仇吗?...呐,恶魔在你最绝望的时候出现,你会伸出双手拉住恶魔给的交易吗?欢迎进入绅士的恶魔世界在绝望中出现的恶魔究竟是救赎还是地狱新人新作,求收藏,求评论,求呵护~
  • 网游之高玩

    网游之高玩

    少数人的名字承载传奇,注定被多数人仰望。
  • 天行

    天行

    号称“北辰骑神”的天才玩家以自创的“牧马冲锋流”战术击败了国服第一弓手北冥雪,被誉为天纵战榜第一骑士的他,却受到小人排挤,最终离开了效力已久的银狐俱乐部。是沉沦,还是再次崛起?恰逢其时,月恒集团第四款游戏“天行”正式上线,虚拟世界再起风云!