项目 | 内容 |
这个做业属于哪一个课程 | http://www.cnblogs.com/nwnu-daizh/ |
这个做业的要求在哪里 | http://www.javashuo.com/article/p-bjcswxqf-ma.html |
课程学习目标 | 熟悉软件开发总体流程,提高自身能力。 |
本次做业在哪一个具体方面帮助咱们实现目标 | 第一次体验一个完整的工程 |
博文结构比较规范,博文内容比较紧凑,博文结构与PSP中“任务内容”列的关系比较一致,经过PSP中“计划共完成须要的时间”与“实际完成须要的时间”两列数据的比较能够看出在开发和编码的过程当中所需的时间差别较大。代码中软件结构不是很严谨、代码规范作的不是很好、柱状图和高频词功能没有实现、人机交互功能不是很完善。但在总结中也看出了本身的不足,平时要多提升本身的编程能力。html
经过看张琼同窗的博客,我发现她对博客的总体结构作的很清晰,同时也意识到编程能力的重要性,若编程能力不足,博文写的再好也没用,因此后期要努力提升本身的编程能力。前端
a.需求分析java
(1)实验2要求的功能;git
(2)单词频数可视化柱状图github
(3)统计该文本行数及字符数;web
(4)各类统计功能均提供计时功能,显示程序统计所消耗时间(单位:ms);编程
(5)可处理任意用户导入的任意英文文本;jsp
(6)人机交互界面要求GUI界面(WEB页面、APP页面均可);函数
(7)附加分功能:统计文本中除冠词、代词、介词以外的高频词;学习
(8)附加分功能:统计前10个两个单词组成的词组频率。
b.软件设计:
//开始时间 long startTime=System.currentTimeMillis(); TreeMap<String,Integer> map1 = new TreeMap<String, Integer>(); WordCount wordCount = new WordCount(); map1= wordCount.bijiao(map, words); //结束时间 long endTime=System.currentTimeMillis(); float excTime=(float)((endTime-startTime)/1000)*1000; //向jsp页面传参数 request.setAttribute("map1", map1); request.setAttribute("excTime", excTime); System.out.println("执行时间:"+excTime+"ms"); request.getRequestDispatcher("index.jsp").forward(request, response);//重定向 }else if(id.equals("2")){ //高频词的统计 //开始时间 long startTime=System.currentTimeMillis(); WordCount wordCount = new WordCount(); int k=Integer.parseInt(wordnum); ArrayList gaopin=wordCount.gaopin(map, k); //结束时间 long endTime=System.currentTimeMillis(); float excTime2=(float)((endTime-startTime)/1000)*1000; request.setAttribute("gaopin", gaopin); request.setAttribute("excTime2", excTime2); request.getRequestDispatcher("html/WordCount.jsp").forward(request, response); }else if(id.equals("3")){ //行数统计 //开始时间 long startTime=System.currentTimeMillis(); WordCount wordCount = new WordCount(); List list=wordCount.statistics(fileName); //结束时间 long endTime=System.currentTimeMillis(); float excTime3=(float)((endTime-startTime)/1000)*1000; request.setAttribute("excTime3", excTime3); request.setAttribute("list", list); request.getRequestDispatcher("html/index.jsp").forward(request, response); } }
/* 获取文件名的函数 */ function one() { var fileName = document.getElementById("file").value; location.href = "../WordCountServlet?fileName=" + fileName + "&id=0"; } function two() { var word = document.getElementById("word").value; location.href = "../WordCountServlet?word=" + word + "&id=1"; } function three() { var wordnum = document.getElementById("wordnum").value; location.href = "../WordCountServlet?wordnum=" + wordnum + "&id=2"; } function four() { var wordlines = document.getElementById("wordlines").value; location.href = "../WordCountServlet?wordlines=" + wordlines + "&id=3"; } function five() { var result = document.getElementById("result").value; location.href = "../WordCountServlet?result=" + result + "&id=4"; }
张琼 | 对实验二的java代码进行适当的修改 |
孙苗坤 | 进行前端页面设计 |
合做完成 | 一块儿完成先后台的交互 |
PSP2.1 | 任务内容 | 计划共完成须要的时间(min) | 实际完成须要的时间(min) |
Planning | 计划 | 15 | 15 |
· Estimate | · 估计这个任务须要多少时间,并规划大体工做步骤 | 15 | 15 |
Development | 开发 | 146 | 218 |
·· Analysis | 需求分析 (包括学习新技术) | 160 | 200 |
· Design Spec | · 生成设计文档 | 25 | 35 |
· Design Review | · 设计复审 | 10 | 15 |
· Coding Standard | 代码规范 | 20 | 20 |
· Design | 具体设计 | 30 | 50 |
· Coding | 具体编码 | 200 | 300 |
· Code Review | · 代码复审 | 15 | 20 |
· Test | · 测试(自我测试,修改代码,提交修改) | 30 | 50 |
Reporting | 报告 | 25 | 30 |
·· Test Report | · 测试报告 | 30 | 40 |
· Size Measurement | 计算工做量 | 10 | 10 |
· Postmortem & Process Improvement Plan | · 过后总结 ,并提出过程改进计划 | 30 | 35 |