• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

共通モジュールとかとか


Commit MetaInfo

Revisión9496554aba82c617477ab2ad27d9cca9058376b2 (tree)
Tiempo2018-01-05 10:00:30
Autorshupeluter@hotmail.com <shupeluter@hotm...>
Commitershupeluter@hotmail.com

Log Message

整理

Cambiar Resumen

  • delete: stux.common/src/main/java/org/stux/common/Exception/StuxBasicException.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/EnumCellType.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewFileScanner.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfo.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfoCounter.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfoWriter.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewPoint.java
  • delete: stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviwInfoParser.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/CoverChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/DocumentChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/FileNameChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/HeaderChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/OutLineChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/RevChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/TestKoumokuChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/XLSXResultWriter.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecCommon.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecCover.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecDetails.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecDetailsEntry.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecEntry.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecFactor.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecHistory.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecHistoryEntry.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecModel.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecScanner.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/parser/TestSpecFileParser.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/pr/MainScreenController.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/util/TestSpecChecker.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecanalizer/util/TestSpecFileScanner.java
  • delete: stux.common/src/main/java/org/stux/worktool/testspecrewiter/XlsxReWriter.java

Diferencia incremental

--- a/stux.common/src/main/java/org/stux/common/Exception/StuxBasicException.java
+++ /dev/null
@@ -1,23 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.common.Exception;
7-
8-
9-/**
10- *
11- * @author YoshihiroSaitoh
12- */
13-public class StuxBasicException extends Exception{
14-
15- public StuxBasicException(String msg) {
16- super(msg);
17- }
18-
19- public StuxBasicException(Exception ex, String msg){
20- super(msg,ex);
21- }
22-
23-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/EnumCellType.java
+++ /dev/null
@@ -1,14 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-/**
9- *
10- * @author YoshihiroSaitoh
11- */
12-public enum EnumCellType {
13- STRING,DATE,NUMBER,FORMULA
14-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewFileScanner.java
+++ /dev/null
@@ -1,52 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-import java.io.File;
9-import java.io.FileFilter;
10-import java.io.FileInputStream;
11-import java.util.Properties;
12-import org.stux.common.Exception.StuxBasicException;
13-import org.stux.common.util.file.BasicFileObjectScanner;
14-
15-/**
16- *
17- * @author YoshihiroSaitoh
18- */
19-public class ReviewFileScanner extends BasicFileObjectScanner{
20- private final String KEY_OMMIT_OLD="ommit.old";
21- private final String KEY_SYS_PROP="path.prop";
22- Properties prop;
23- boolean ommit=false;
24- public ReviewFileScanner(File file) throws StuxBasicException {
25- super(file);
26- prop = new Properties();
27- String propFilepath;
28- propFilepath = System.getProperty(KEY_SYS_PROP);
29- File propFile = new File(propFilepath);
30-
31- try {
32- prop.load(new FileInputStream(new File(propFilepath)));
33- ommit = Boolean.parseBoolean(prop.getProperty(KEY_OMMIT_OLD));
34- } catch (Exception ex) {
35- throw new StuxBasicException(ex,"プロパティファイルの読み込みに失敗しました。");
36- }
37- }
38-
39- @Override
40- public FileFilter getFileFileter() {
41-
42- FileFilter filter = (f) -> {
43- return ((f.getName().lastIndexOf(".xlsx") > 0
44- || f.getName().lastIndexOf(".xls") > 0
45- || f.isDirectory()) && (!f.getPath().contains("old") || !ommit)
46- );
47- };
48-
49- return filter;
50- }
51-
52-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfo.java
+++ /dev/null
@@ -1,81 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-import java.util.List;
9-import org.stux.common.util.excel.IParseResult;
10-
11-/**
12- *
13- * @author YoshihiroSaitoh
14- */
15-public class ReviewInfo implements IParseResult{
16-
17- private String targetResource;
18- private String fileName;
19- private String filePath;
20- private String numberOfPages;
21- private String resourceType;
22- private String numberOfTimes;
23- private List<ReviewPoint> points;
24-
25- public String getTargetResource() {
26- return targetResource;
27- }
28-
29- public void setTargetResource(String targetResource) {
30- this.targetResource = targetResource;
31- }
32-
33- public String getNumberOfPages() {
34- return numberOfPages;
35- }
36-
37- public void setNumberOfPages(String numberOfPages) {
38- this.numberOfPages = numberOfPages;
39- }
40-
41- public String getResourceType() {
42- return resourceType;
43- }
44-
45- public void setResourceType(String resourceType) {
46- this.resourceType = resourceType;
47- }
48-
49- public String getNumberOfTimes() {
50- return numberOfTimes;
51- }
52-
53- public void setNumberOfTimes(String numberOfTimes) {
54- this.numberOfTimes = numberOfTimes;
55- }
56-
57- public List<ReviewPoint> getPoints() {
58- return points;
59- }
60-
61- public void setPoints(List<ReviewPoint> points) {
62- this.points = points;
63- }
64-
65- public String getFileName() {
66- return fileName;
67- }
68-
69- public void setFileName(String fileName) {
70- this.fileName = fileName;
71- }
72-
73- public String getFilePath() {
74- return filePath;
75- }
76-
77- public void setFilePath(String filePath) {
78- this.filePath = filePath;
79- }
80-
81-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfoCounter.java
+++ /dev/null
@@ -1,41 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-import java.io.File;
9-import java.util.List;
10-import java.util.logging.Logger;
11-import org.stux.common.Exception.StuxBasicException;
12-
13-/**
14- *
15- * @author 0000011141935
16- */
17-public class ReviewInfoCounter {
18- public static void main(String[] args) throws StuxBasicException{
19-
20- File file = new File(args[0]);
21- ReviewFileScanner rfs = new ReviewFileScanner(file);
22- ReviewInfoWriter riw = new ReviewInfoWriter();
23-
24- List<File> files=rfs.getFiles();
25-
26- ReviwInfoParser rip = new ReviwInfoParser();
27- riw.writeHeader();
28- for(File cfile:files){
29- try{
30- rip.parse(cfile);
31- ReviewInfo revinfo = rip.getRevInfo();
32- riw.write(revinfo);
33- } catch (Exception ex){
34- Logger.getLogger(ReviewInfoCounter.class.getName()).info("ファイル"+cfile.getName()+"の読み取りに失敗しました");
35- System.err.println(ex.toString());
36- }
37- }
38-
39- }
40-
41-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewInfoWriter.java
+++ /dev/null
@@ -1,66 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-import java.util.ArrayList;
9-import java.util.List;
10-import org.stux.common.util.excel.BasicResultWriter;
11-import org.stux.common.util.excel.IParseResult;
12-
13-/**
14- *
15- * @author 0000011141935
16- */
17-public class ReviewInfoWriter extends BasicResultWriter{
18- public void writeHeader(){
19- System.out.println("格納フォルダ,ファイル名,レビュー資料名,ページ数,レビュー回数,内容区分,指摘番号,指摘事項,指摘者,指摘頁,指摘箇所,指摘内容,原因,影響レベル,影響範囲,検討結果,要否,担当,期限,完了日");
20- }
21- @Override
22- public void write(IParseResult target) {
23- ReviewInfo ri = (ReviewInfo) target;
24- List<String> result = new ArrayList();
25-
26- for(ReviewPoint rp:ri.getPoints()){
27- result.add(this.createWriteMsg(ri, rp));
28- }
29- this.write(result);
30- }
31-
32- protected String createWriteMsg(ReviewInfo info,ReviewPoint point){
33- StringBuffer sb = new StringBuffer();
34-
35- sb.append(info.getFilePath()).append(",");
36- sb.append(info.getFileName()).append(",");
37- sb.append(info.getTargetResource()).append(",");
38- sb.append(info.getNumberOfPages()).append(",");
39- sb.append(info.getNumberOfTimes()).append(",");
40- sb.append(info.getResourceType()).append(",");
41- sb.append(point.getNumber()).append(",");
42- sb.append(point.getPointedContents()).append(",");
43- sb.append(point.getPointer()).append(",");
44- sb.append(point.getPointedPlace()).append(",");
45- sb.append(point.getPointedPlaceType()).append(",");;
46- sb.append(point.getPointedContentType()).append(",");;
47- sb.append(point.getOccasionType()).append(",");
48- sb.append(point.getImpactedLevel()).append(",");
49- sb.append(point.getImpactedPoints()).append(",");
50- sb.append(point.getResultsOfInvestigation()).append(",");
51- sb.append(point.getNecessaryOption()).append(",");
52- sb.append(point.getFixer()).append(",");;
53- sb.append(point.getLimitedDate()).append(",");;
54- sb.append(point.getFixedDate());
55-
56- return String.valueOf(sb);
57-
58- }
59-
60- protected void write(List<String> contents){
61- for(String content:contents){
62- System.out.println(content);
63- }
64- }
65-
66-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviewPoint.java
+++ /dev/null
@@ -1,158 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-/**
9- *
10- * @author YoshihiroSaitoh
11- */
12-public class ReviewPoint {
13-
14- //指摘番号
15-
16- private String number;
17- //指摘事項
18- private String pointedContents;
19- //指摘者
20- private String pointer;
21- //指摘箇所
22- private String pointedPlace;
23- //指摘箇所分類
24- private String pointedPlaceType;
25- //指摘内容分類
26- private String pointedContentType;
27- //原因分類
28- private String occasionType;
29- //影響レベル
30- private String impactedLevel;
31- //影響範囲
32- private String impactedPoints;
33- //検討結果
34- private String resultsOfInvestigation;
35- //対応要否
36- private String necessaryOption;
37- //対応担当
38- private String fixer;
39- //対応期限
40- private String limitedDate;
41- //対応日
42- private String fixedDate;
43-
44- public String getNumber() {
45- return number;
46- }
47-
48- public void setNumber(String number) {
49- this.number = number;
50- }
51-
52- public String getPointedContents() {
53- return pointedContents;
54- }
55-
56- public void setPointedContents(String pointedContents) {
57- this.pointedContents = pointedContents;
58- }
59-
60- public String getPointer() {
61- return pointer;
62- }
63-
64- public void setPointer(String pointer) {
65- this.pointer = pointer;
66- }
67-
68- public String getPointedPlace() {
69- return pointedPlace;
70- }
71-
72- public void setPointedPlace(String pointedPlace) {
73- this.pointedPlace = pointedPlace;
74- }
75-
76- public String getPointedPlaceType() {
77- return pointedPlaceType;
78- }
79-
80- public void setPointedPlaceType(String pointedPlaceType) {
81- this.pointedPlaceType = pointedPlaceType;
82- }
83-
84- public String getPointedContentType() {
85- return pointedContentType;
86- }
87-
88- public void setPointedContentType(String pointedContentType) {
89- this.pointedContentType = pointedContentType;
90- }
91-
92- public String getOccasionType() {
93- return occasionType;
94- }
95-
96- public void setOccasionType(String occasionType) {
97- this.occasionType = occasionType;
98- }
99-
100- public String getImpactedLevel() {
101- return impactedLevel;
102- }
103-
104- public void setImpactedLevel(String impactedLevel) {
105- this.impactedLevel = impactedLevel;
106- }
107-
108- public String getImpactedPoints() {
109- return impactedPoints;
110- }
111-
112- public void setImpactedPoints(String impactedPoints) {
113- this.impactedPoints = impactedPoints;
114- }
115-
116- public String getResultsOfInvestigation() {
117- return resultsOfInvestigation;
118- }
119-
120- public void setResultsOfInvestigation(String resultsOfInvestigation) {
121- this.resultsOfInvestigation = resultsOfInvestigation;
122- }
123-
124- public String getNecessaryOption() {
125- return necessaryOption;
126- }
127-
128- public void setNecessaryOption(String necessaryOption) {
129- this.necessaryOption = necessaryOption;
130- }
131-
132- public String getFixer() {
133- return fixer;
134- }
135-
136- public void setFixer(String fixer) {
137- this.fixer = fixer;
138- }
139-
140- public String getLimitedDate() {
141- return limitedDate;
142- }
143-
144- public void setLimitedDate(String LimitedDate) {
145- this.limitedDate = LimitedDate;
146- }
147-
148- public String getFixedDate() {
149- return fixedDate;
150- }
151-
152- public void setFixedDate(String fixedDate) {
153- this.fixedDate = fixedDate;
154- }
155-
156-
157-
158-}
--- a/stux.common/src/main/java/org/stux/worktool/reviewinfocounter/ReviwInfoParser.java
+++ /dev/null
@@ -1,157 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.reviewinfocounter;
7-
8-import org.stux.common.util.excel.IndexInfo;
9-import java.io.File;
10-import java.io.FileInputStream;
11-import java.util.ArrayList;
12-import java.util.HashMap;
13-import java.util.List;
14-import java.util.Map;
15-import java.util.Properties;
16-import org.apache.poi.ss.usermodel.Sheet;
17-import org.stux.common.Exception.StuxBasicException;
18-import org.stux.common.util.excel.BaseExcelParser;
19-
20-/**
21- *
22- * @author YoshihiroSaitoh
23- */
24-public class ReviwInfoParser extends BaseExcelParser {
25-
26- public final String KEY_PROP_PATH = "path.prop";
27- public final String KEY_BASIC_INFO_SHEET = "basicInfoIndex";
28- public final String KEY_DETAILS_INFO_SHEET = "detailsIndex";
29- public final String KEY_TARGET_RESOURCE = "targetResoruce";
30- public final String KEY_NUMBER_OF_PAGESE = "numberOfPages";
31- public final String KEY_RESOURCETYPE = "resourceType";
32- public final String KEY_NUMBEROFTIMES = "numberOfTimes";
33-
34- public final String KEY_NUMBER = "number";
35- public final String KEY_POINTER = "pointer";
36- public final String KEY_POITEDPLACE = "pointedPlace";
37- public final String KEY_POINTEDPLACETYPE = "pointedPlaceType";
38- public final String KYE_POINTED_CONTENT="pointedContent";
39- public final String KEY_POINTED_CONTENT_TYPE = "pointedContentType";
40- public final String KEY_OCCASION_TYPE = "occasionType";
41- public final String KEY_IMPACT_LEVEL = "impactedLevel";
42- public final String KEY_IMPACT_POINTS="impactPoints";
43- public final String KEY_RESULTS_OF_INVESTIGATION = "resultsOfInvestigation";
44- public final String KEY_NECESSARYOPTION = "necessaryOption";
45- public final String KEY_FIXER = "fixer";
46- public final String KEY_LIMITED_DATE = "limitedDate";
47- public final String KEY_FIXED_DATE = "fixedDate";
48-
49- protected String propFilepath = "test.properties";
50- private int basicInfoIndex;
51- private int detailsIndex;
52-
53- private Map<String, IndexInfo> sheetInfo;
54-
55- private ReviewInfo revInfo;
56-
57- public ReviwInfoParser() throws StuxBasicException {
58- try {
59- Properties prop = new Properties();
60- propFilepath = System.getProperty(KEY_PROP_PATH);
61- File propFile = new File(propFilepath);
62- prop.load(new FileInputStream(new File(propFilepath)));
63-
64- //シート情報取り込み
65- sheetInfo = new HashMap<>();
66- basicInfoIndex = Integer.parseInt(prop.getProperty(KEY_BASIC_INFO_SHEET));
67- detailsIndex = Integer.parseInt(prop.getProperty(KEY_DETAILS_INFO_SHEET));
68-
69- sheetInfo.put(KEY_TARGET_RESOURCE, new IndexInfo(prop.getProperty(KEY_TARGET_RESOURCE)));
70- sheetInfo.put(KEY_NUMBER_OF_PAGESE, new IndexInfo(prop.getProperty(KEY_NUMBER_OF_PAGESE)));
71- sheetInfo.put(KEY_RESOURCETYPE, new IndexInfo(prop.getProperty(KEY_RESOURCETYPE)));
72- sheetInfo.put(KEY_NUMBEROFTIMES, new IndexInfo(prop.getProperty(KEY_NUMBEROFTIMES)));
73-
74- sheetInfo.put(KEY_NUMBER, new IndexInfo(prop.getProperty(KEY_NUMBER)));
75- sheetInfo.put(KEY_POINTER, new IndexInfo(prop.getProperty(KEY_POINTER)));
76- sheetInfo.put(KEY_POITEDPLACE, new IndexInfo(prop.getProperty(KEY_POITEDPLACE)));
77- sheetInfo.put(KEY_POINTEDPLACETYPE, new IndexInfo(prop.getProperty(KEY_POINTEDPLACETYPE)));
78- sheetInfo.put(KEY_POINTED_CONTENT_TYPE, new IndexInfo(prop.getProperty(KEY_POINTED_CONTENT_TYPE)));
79- sheetInfo.put(KEY_OCCASION_TYPE, new IndexInfo(prop.getProperty(KEY_OCCASION_TYPE)));
80- sheetInfo.put(KEY_IMPACT_LEVEL, new IndexInfo(prop.getProperty(KEY_IMPACT_LEVEL)));
81- sheetInfo.put(KEY_IMPACT_POINTS, new IndexInfo(prop.getProperty(KEY_IMPACT_POINTS)));
82- sheetInfo.put(KEY_RESULTS_OF_INVESTIGATION, new IndexInfo(prop.getProperty(KEY_RESULTS_OF_INVESTIGATION)));
83- sheetInfo.put(KEY_NECESSARYOPTION, new IndexInfo(prop.getProperty(KEY_NECESSARYOPTION)));
84- sheetInfo.put(KEY_FIXER, new IndexInfo(prop.getProperty(KEY_FIXER)));
85- sheetInfo.put(KEY_LIMITED_DATE, new IndexInfo(prop.getProperty(KEY_LIMITED_DATE)));
86- sheetInfo.put(KEY_FIXED_DATE, new IndexInfo(prop.getProperty(KEY_FIXED_DATE)));
87- sheetInfo.put(KYE_POINTED_CONTENT,new IndexInfo(prop.getProperty(KYE_POINTED_CONTENT)));
88- revInfo = new ReviewInfo();
89- } catch (Exception ex) {
90- throw new StuxBasicException(ex, "プロパティファイルの読み込みに失敗しました。");
91- }
92-
93- }
94-
95- @Override
96- public void parse(Map<Integer, Sheet> sheets) throws StuxBasicException {
97-
98- IndexInfo tempInfo;
99- //レビュー情報取得
100- Sheet sheet = sheets.get(basicInfoIndex);
101-
102- revInfo.setFileName(super.fileName);
103- revInfo.setFilePath(super.filePath);
104- //TODO シート名の取得
105- revInfo.setNumberOfPages(getStringValue(sheet, sheetInfo.get(KEY_NUMBER_OF_PAGESE)));
106- revInfo.setNumberOfTimes(getStringValue(sheet, sheetInfo.get(KEY_NUMBEROFTIMES)));
107- revInfo.setTargetResource(getStringValue(sheet, sheetInfo.get(KEY_TARGET_RESOURCE)));
108- revInfo.setResourceType(getStringValue(sheet, sheetInfo.get(KEY_RESOURCETYPE)));
109-
110- revInfo.setPoints(this.createDetailList(sheets.get(detailsIndex)));
111-
112- }
113-
114-
115-
116- private List<ReviewPoint> createDetailList(Sheet sheet) {
117- List<ReviewPoint> list = new ArrayList<>();
118-
119- IndexInfo id = sheetInfo.get(KEY_NUMBER);
120- int beginRow = id.getRow();
121- int dr = beginRow;
122-
123- while (!"".equals(this.getStringValue(sheet, dr, id))
124- && null != this.getStringValue(sheet, dr, id)) {
125-
126- ReviewPoint point = new ReviewPoint();
127-
128- point.setFixedDate(this.getStringValue(sheet, dr, sheetInfo.get(KEY_FIXED_DATE)));
129- point.setFixer(this.getStringValue(sheet, dr,sheetInfo.get(KEY_FIXER)));
130- point.setImpactedLevel(this.getStringValue(sheet, dr,sheetInfo.get(KEY_IMPACT_LEVEL)));
131-
132- point.setImpactedPoints(this.getStringValue(sheet, dr,sheetInfo.get(KEY_IMPACT_POINTS)));
133- point.setLimitedDate(this.getStringValue(sheet, dr,sheetInfo.get(KEY_LIMITED_DATE)));
134- point.setNecessaryOption(this.getStringValue(sheet, dr,sheetInfo.get(KEY_NECESSARYOPTION)));
135- point.setNumber(this.getStringValue(sheet, dr,sheetInfo.get(KEY_NUMBER)));
136- point.setOccasionType(this.getStringValue(sheet, dr,sheetInfo.get(KEY_OCCASION_TYPE)));
137- point.setPointedContentType(this.getStringValue(sheet, dr,sheetInfo.get(KEY_POINTED_CONTENT_TYPE)));
138- point.setPointedContents(this.getStringValue(sheet, dr,sheetInfo.get(KYE_POINTED_CONTENT)));
139- point.setPointedPlace(this.getStringValue(sheet, dr,sheetInfo.get(KEY_POITEDPLACE)));
140- point.setPointedPlaceType(this.getStringValue(sheet, dr,sheetInfo.get(KEY_POINTEDPLACETYPE)));
141- point.setPointer(this.getStringValue(sheet, dr,sheetInfo.get(KEY_POINTER)));
142- point.setResultsOfInvestigation(this.getStringValue(sheet, dr,sheetInfo.get(KEY_RESULTS_OF_INVESTIGATION)));
143-
144- list.add(point);
145-
146- dr++;
147-
148- }
149-
150- return list;
151- }
152-
153- public ReviewInfo getRevInfo() {
154- return revInfo;
155- }
156-
157-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/CoverChecker.java
+++ /dev/null
@@ -1,26 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
9-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
10-
11-/**
12- *
13- * @author YoshihiroSaitoh
14- */
15-class CoverChecker implements TestSpecChecker {
16-
17- public CoverChecker() {
18- }
19-
20- @Override
21- public boolean check(TestSpecFactor tsf, StringBuffer msg) {
22- //TODO 実装
23- return true;
24- }
25-
26-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/DocumentChecker.java
+++ /dev/null
@@ -1,31 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import org.stux.common.Exception.StuxBasicException;
9-import org.stux.worktool.testspecanalizer.model.TestSpecCommon;
10-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
11-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
12-
13-/**
14- *
15- * @author 0000011141935
16- */
17-public class DocumentChecker implements TestSpecChecker{
18-
19- @Override
20- public boolean check(TestSpecFactor tsf, StringBuffer msg) throws StuxBasicException {
21- TestSpecCommon tsc = (TestSpecCommon)tsf;
22- boolean res = true;
23- if(tsc.getDocumentName() != null || "".equals(tsc.getDocumentName())){
24-
25- } else {
26- res = false;
27- }
28- return res;
29- }
30-
31-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/FileNameChecker.java
+++ /dev/null
@@ -1,92 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import java.io.File;
9-import java.io.IOException;
10-import java.util.ArrayList;
11-import java.util.List;
12-import java.util.logging.Level;
13-import java.util.logging.Logger;
14-import java.util.regex.Matcher;
15-import java.util.regex.Pattern;
16-import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
17-import org.apache.poi.ss.usermodel.Cell;
18-import org.apache.poi.ss.usermodel.Row;
19-import org.apache.poi.ss.usermodel.Sheet;
20-import org.apache.poi.ss.usermodel.Workbook;
21-import org.apache.poi.ss.usermodel.WorkbookFactory;
22-import org.stux.common.Exception.StuxBasicException;
23-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
24-import org.stux.worktool.testspecanalizer.model.TestSpecModel;
25-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
26-
27-/**
28- *
29- * @author 0000011141935
30- */
31-public class FileNameChecker implements TestSpecChecker{
32- private final String STR_FILE_NAME_PATTERN="【NEON】テスト仕様書兼報告書_.+\\.xlsx";
33- private final String MSG_ILEGAL_FILE_NAME="ファイル名hogeは、想定されるファイル名fooに該当しません。\n";
34- private final String MSG_FILE_NOT_FOUND="ファイル名hogeは納品ファイル一覧に存在しません。";
35- private final String NAME_FILE="NEC納品物一覧.xlsx";
36-
37- private final int ROW_NUM_START=3;
38- private final int COL_FILE_NAME=3;
39-
40- private List<String> currectFiles;
41-
42- public FileNameChecker() throws StuxBasicException{
43- currectFiles = new ArrayList<>();
44- try {
45- Workbook wb = WorkbookFactory.create(new File(NAME_FILE));
46- Sheet sheet = wb.getSheetAt(0);
47-
48- for(int i = ROW_NUM_START; i <= sheet.getLastRowNum();i++){
49- Row row = sheet.getRow(i);
50- if(row != null){
51- Cell cell = row.getCell(COL_FILE_NAME);
52- if(cell != null){
53- currectFiles.add(cell.getStringCellValue());
54- }
55- }
56- }
57-
58-
59- } catch (Exception ex) {
60- throw new StuxBasicException(ex,"納品物一覧を開くのに失敗しました。");
61- }
62- }
63-
64- @Override
65- public boolean check(TestSpecFactor tsf, StringBuffer msg) throws StuxBasicException{
66- boolean res = false;
67- if(tsf instanceof TestSpecModel){
68- TestSpecModel tsm = (TestSpecModel) tsf;
69- Pattern p = Pattern.compile(STR_FILE_NAME_PATTERN);
70- Matcher m = p.matcher(tsm.getFileName());
71-
72- if(m.find()){
73- res = true;
74- } else {
75- res = false;
76- msg.append(MSG_ILEGAL_FILE_NAME.replaceAll("hoge",tsm.getFileName()).replaceAll("foo", STR_FILE_NAME_PATTERN));
77- }
78-
79- if(currectFiles.contains(tsm.getFileName())){
80-
81- } else {
82- res = false;
83- msg.append(MSG_FILE_NOT_FOUND.replaceAll("hoge",tsm.getFileName()));
84- }
85-
86- } else {
87- throw new StuxBasicException("異なる型のオブジェクトを入力しました。");
88- }
89- return res;
90- }
91-
92-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/HeaderChecker.java
+++ /dev/null
@@ -1,238 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import java.util.regex.Matcher;
9-import java.util.regex.Pattern;
10-import org.stux.worktool.testspecanalizer.model.TestSpecCommon;
11-import org.stux.worktool.testspecanalizer.model.TestSpecCover;
12-import org.stux.worktool.testspecanalizer.model.TestSpecDetails;
13-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
14-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
15-
16-/**
17- *
18- * @author 0000011141935
19- */
20-public class HeaderChecker implements TestSpecChecker {
21-
22- private final String REF_PATTERN = "=.*表紙.*";
23- private final String MSG_DOCUMENT_NAME_NOT_FOUND = "ドキュメント名に記載がありません。";
24- private final String MSG_CREATED_DATE_NOT_WRITE = "作成日の記載がありません。\n";
25- private final String MSG_UPDATE_DATE_NOT_WRITE = "更新日の記載がありません。\n";
26- private final String MSG_AUTHOR_NOT_WRITE = "作成者の記載がありません。\n";
27- private final String MSG_UPDATEOR_NOT_WRITE = "更新者の記載がありません。\n";
28- private final String MSG_CHECKER_NOT_WRITE = "検証者の記載がありません。\n";
29- private final String MSG_CHECKED_DATE_NOT_WRITE = "検証日の記載がありません。\n";
30-
31- private final String MSG_CREATED_DATE_NOT_REF = "作成日が表紙の参照ではありません。\n";
32- private final String MSG_UPDATE_DATE_NOT_REF = "更新日が表紙の参照ではありません。\n";
33- private final String MSG_AUTHOR_NOT_REF = "作成者が表紙の参照ではありません。\n";
34- private final String MSG_UPDATEOR_NOT_REF = "更新者が表紙の参照ではありません。\n";
35- private final String MSG_CHECKER_NOT_REF = "検証者が表紙の参照ではありません。\n";
36- private final String MSG_DOCUMENT_NOT_REF = "ドキュメント名が表紙の参照ではありません。\n";
37- private final String MSG_CHECKED_DATE_NOT_REF = "検証日が表紙の参照ではありません。\n";
38- private final String MSG_NUM_INCONSISTENCY = "「テスト項目数」「実施消化件数」「検証消化件数」の値が等しくなっていません。\n";
39- private final String MSG_ILEAGAL_CHECKED_FORMURA = "検証消化件数に設定されている数式が異なります。\n";
40- private final String REG_FORMULA_CHECKE = "COUNTIF\\(BS11:BS[0-9]{1,3},\\\"○\\\"\\) \\+ COUNTIFS\\(BS11:BS[0-9]{1,3},\\\"×\\\",CC11:CC[0-9]{1,3},\\\"○\\\"\\)";
41-
42- @Override
43- public boolean check(TestSpecFactor tsf, StringBuffer msg) {
44-
45- boolean res = true;
46- if (tsf instanceof TestSpecCover) {
47- TestSpecCommon tsc = (TestSpecCommon) tsf;
48- //ドキュメント名を確認
49- if (tsc.getDocumentName() != null | !"".equals(tsc.getDocumentName())) {
50-
51- } else {
52- msg.append(MSG_DOCUMENT_NAME_NOT_FOUND);
53- }
54- //作成日を確認
55- if (tsc.getCreatedDate() != null | !"".equals(tsc.getCreatedDate())) {
56-
57- } else {
58- msg.append(MSG_CREATED_DATE_NOT_WRITE);
59- res = false;
60- }
61-
62- //更新日を確認
63- if (tsc.getUpdateDate() != null | !"".equals(tsc.getUpdateDate())) {
64-
65- } else {
66- msg.append(MSG_UPDATE_DATE_NOT_WRITE);
67- res = false;
68-
69- }
70-
71- //検証日を確認
72- if (tsc.getCheckedDate() != null | !"".equals(tsc.getCheckedDate())) {
73-
74- } else {
75- msg.append(MSG_CHECKED_DATE_NOT_WRITE);
76- res = false;
77- }
78-
79- //作成者を確認
80- if (tsc.getFirstAuthor() != null | !"".equals(tsc.getFirstAuthor())) {
81-
82- } else {
83- msg.append(MSG_AUTHOR_NOT_WRITE);
84- res = false;
85- }
86-
87- //更新者を確認
88- if (tsc.getLastAuthor() != null | !"".equals(tsc.getLastAuthor())) {
89-
90- } else {
91- msg.append(MSG_UPDATEOR_NOT_WRITE);
92- res = false;
93- }
94-
95- //検証者を確認
96- if (tsc.getChecker() != null | !"".equals(tsc.getChecker())) {
97-
98- } else {
99- msg.append(MSG_CHECKER_NOT_WRITE);
100- res = false;
101- }
102-
103- } else {
104-
105- TestSpecCommon tsc = (TestSpecCommon) tsf;
106- Pattern p = Pattern.compile(REF_PATTERN);
107- Matcher match;
108- //作成日を確認
109- if (tsc.getCreatedDate() != null | !"".equals(tsc.getCreatedDate())) {
110-
111- match = p.matcher(tsc.getCreatedDate());
112- if (match.find()) {
113-
114- } else {
115- msg.append(MSG_CREATED_DATE_NOT_REF);
116- res = false;
117- }
118-
119- } else {
120- msg.append(MSG_CREATED_DATE_NOT_WRITE);
121- res = false;
122- }
123-
124- //更新日を確認
125- if (tsc.getUpdateDate() != null | !"".equals(tsc.getUpdateDate())) {
126- match = p.matcher(tsc.getUpdateDate());
127- if (match.find()) {
128-
129- } else {
130- msg.append(MSG_UPDATE_DATE_NOT_REF);
131- res = false;
132- }
133-
134- } else {
135- msg.append(MSG_UPDATE_DATE_NOT_WRITE);
136- res = false;
137- }
138-
139- //検証日を確認
140- if (tsc.getCheckedDate() != null | !"".equals(tsc.getCheckedDate())) {
141-
142- match = p.matcher(tsc.getCheckedDate());
143- if (match.find()) {
144-
145- } else {
146- msg.append(MSG_CHECKED_DATE_NOT_REF);
147- res = false;
148- }
149-
150- } else {
151- msg.append(MSG_CHECKED_DATE_NOT_WRITE);
152- res = false;
153- }
154-
155- //作成者を確認
156- if (tsc.getFirstAuthor() != null | !"".equals(tsc.getFirstAuthor())) {
157- match = p.matcher(tsc.getFirstAuthor());
158- if (match.find()) {
159-
160- } else {
161- msg.append(MSG_AUTHOR_NOT_REF);
162- res = false;
163- }
164- } else {
165- msg.append(MSG_AUTHOR_NOT_WRITE);
166- res = false;
167- }
168-
169- //更新者を確認
170- if (tsc.getLastAuthor() != null | !"".equals(tsc.getLastAuthor())) {
171- match = p.matcher(tsc.getLastAuthor());
172- if (match.find()) {
173-
174- } else {
175- msg.append(MSG_UPDATEOR_NOT_REF);
176- res = false;
177- }
178- } else {
179- msg.append(MSG_UPDATEOR_NOT_WRITE);
180- res = false;
181- }
182-
183- //検証者を確認
184- if (tsc.getChecker() != null | !"".equals(tsc.getChecker())) {
185- match = p.matcher(tsc.getChecker());
186- if (match.find()) {
187-
188- } else {
189- msg.append(MSG_CHECKER_NOT_REF);
190- res = false;
191- }
192- } else {
193- res = false;
194- msg.append(MSG_CHECKER_NOT_WRITE);
195- }
196-
197- //ドキュメント名を確認
198- if (tsc.getDocumentName() != null | !"".equals(tsc.getDocumentName())) {
199- match = p.matcher(tsc.getDocumentName());
200- if (match.find()) {
201-
202- } else {
203- res = false;
204- msg.append(MSG_DOCUMENT_NOT_REF);
205- }
206- } else {
207- msg.append(MSG_DOCUMENT_NAME_NOT_FOUND);
208- res = false;
209- }
210-
211- }
212-
213- if (tsf instanceof TestSpecDetails) {
214- TestSpecDetails tsd = (TestSpecDetails) tsf;
215- Pattern p = Pattern.compile(REG_FORMULA_CHECKE);
216- String formula = tsd.getNumOfCheckFormula();
217- Matcher match = p.matcher(formula);
218-
219- if (tsd.getNumOfCheck().equals(tsd.getNumOfExcuted()) && tsd.getNumOfExcuted().equals(tsd.getNumOfTests())) {
220-
221- } else {
222- msg.append(MSG_NUM_INCONSISTENCY);
223- res = false;
224- }
225-
226- if (match.find()) {
227-
228- } else {
229- msg.append(MSG_ILEAGAL_CHECKED_FORMURA);
230- res = false;
231- }
232-
233- }
234-
235- return res;
236- }
237-
238-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/OutLineChecker.java
+++ /dev/null
@@ -1,42 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import org.stux.worktool.testspecanalizer.model.TestSpecCover;
9-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
10-import org.stux.worktool.testspecanalizer.model.TestSpecHistory;
11-import org.stux.worktool.testspecanalizer.model.TestSpecModel;
12-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
13-
14-/**
15- *
16- * @author YoshihiroSaitoh
17- */
18-public class OutLineChecker implements TestSpecChecker{
19- private final String MSG_COVER_NOT_FOUND="表紙シートが存在しません。";
20- private final String MSG_HISTORY_NOT_FOUND="改訂履歴シートが存在しません。";
21-
22- @Override
23- public boolean check(TestSpecFactor tsf,StringBuffer msg) {
24- boolean res = true;
25- TestSpecModel tm = (TestSpecModel) tsf;
26- TestSpecCover cover=tm.getCover();
27- TestSpecHistory hist = tm.getHistory();
28-
29- if(cover == null||!cover.getSheetName().equals("表紙")){
30- res = false;
31- if(msg != null) msg.append(MSG_COVER_NOT_FOUND);
32- }
33-
34- if(hist == null || !hist.getSheetName().equals("改訂履歴")){
35- res = false;
36- if(msg != null) msg.append(MSG_HISTORY_NOT_FOUND);
37- }
38-
39- return res;
40- }
41-
42-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/RevChecker.java
+++ /dev/null
@@ -1,56 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import java.io.FileInputStream;
9-import java.io.IOException;
10-import java.util.Properties;
11-import org.stux.common.Exception.StuxBasicException;
12-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
13-import org.stux.worktool.testspecanalizer.model.TestSpecHistory;
14-import org.stux.worktool.testspecanalizer.model.TestSpecHistoryEntry;
15-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
16-
17-/**
18- *
19- * @author 0000011141935
20- */
21-public class RevChecker implements TestSpecChecker{
22- public final String KEY_PROP_PATH = "path.prop";
23- private static final String KEY_CORRECT_REV = "correct.rev";
24-
25- @Override
26- public boolean check(TestSpecFactor tsf, StringBuffer msg) throws StuxBasicException {
27- try {
28- String propFilepath = System.getProperty(KEY_PROP_PATH);
29- Properties prop = new Properties();
30- TestSpecHistory tsh = (TestSpecHistory)tsf;
31- TestSpecHistoryEntry tshe = tsh.getLastUpdateInfo();
32- boolean res = true;
33- String correctRev;
34-
35- prop.load(new FileInputStream(propFilepath));
36- correctRev = prop.getProperty(KEY_CORRECT_REV);
37-
38- if(tshe != null && correctRev.equals(tshe.getRev())){
39-
40- } else {
41- msg.append(tshe.getRev()+"は想定しているリビジョン"+correctRev+"と異なります。\n");
42- res =false;
43- }
44-
45- prop = null;
46-
47- return res;
48-
49- } catch (IOException ex) {
50- throw new StuxBasicException(ex,"プロパティファイルの読み込みに失敗しました。");
51- //Logger.getLogger(RevChecker.class.getName()).log(Level.SEVERE, null, ex);
52- }
53- }
54-
55-
56-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/TestKoumokuChecker.java
+++ /dev/null
@@ -1,219 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import java.util.ArrayList;
9-import java.util.HashMap;
10-import java.util.List;
11-import java.util.Map;
12-import java.util.regex.Matcher;
13-import java.util.regex.Pattern;
14-import org.stux.worktool.testspecanalizer.model.TestSpecDetailsEntry;
15-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
16-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
17-
18-/**
19- *
20- * @author 0000011141935
21- */
22-public class TestKoumokuChecker implements TestSpecChecker {
23-
24- private final String REGEXP_TESTCASEID_PATTERN = "(KK|UK|HP|IK|Z9)-(K|H|U)[0-9]{2}-[0-9]{2}-[0-9]{2}-[0-9]{3}-{0,1}[0-9]{0,2}";
25- private final String MSG_TESTCASE_ID_FAIL = "テストケースIDが不正です\n";
26- private final String MSG_TEST_DETAILS_FAIL = "テスト項目・内容に「項目」「手順」「前提」の記載がありません。¥n";
27- private final String MSG_TEST_EXPRECTS_FAIL = "確認資料・予想結果についての記載がありません。\n";
28- private final String MSG_TEST_NOT_FINISHED = "テストが完了していません。";
29- private final String MSG_CHEC_NOT_FINISHED = "検証が完了していません。";
30-
31- private final String MSG_EXECUTE_FAIL = "実行結果に矛盾があります。\n";
32- private final String MSG_CHECK_FAIL = "検証結果に矛盾があります。\n";
33- private final String MSG_DOUBLE_TESTID = "重複するテストケースIDが存在します。";
34- private final String MSG_CHECK_EVIDENCE_FAIL = "エビデンスに記載がありません。";
35-
36- private static Map<String, String> testCaseIdMap = new HashMap();
37-
38- @Override
39- public boolean check(TestSpecFactor tsf, StringBuffer msg) {
40- boolean res = true;
41-
42- if (tsf instanceof TestSpecDetailsEntry) {
43-
44- TestSpecDetailsEntry tsde = (TestSpecDetailsEntry) tsf;
45-
46- //テストケースIDチェック
47- if (this.checkTestCaseId(tsde.getTescaseId())) {
48-
49- } else {
50- msg.append(MSG_TESTCASE_ID_FAIL);
51- res = false;
52- }
53-
54- if (tsde.getTescaseId() != null
55- && TestKoumokuChecker.testCaseIdMap.get(tsde.getTescaseId()) == null) {
56- TestKoumokuChecker.testCaseIdMap.put(tsde.getTescaseId(), "");
57- } else {
58- msg.append(MSG_DOUBLE_TESTID);
59- res = false;
60- }
61-
62- if (tsde.getTestDetails().contains("前提")
63- && tsde.getTestDetails().contains("手順")
64- && tsde.getTestDetails().contains("項目")) {
65-
66- } else {
67- msg.append(MSG_TEST_DETAILS_FAIL);
68- res = false;
69- }
70-
71- if (tsde.getExecuteDates() != null || !"".equals(tsde.getTestExpectes())) {
72-
73- } else {
74- msg.append(MSG_TEST_EXPRECTS_FAIL);
75- res = false;
76- }
77-
78- if ((tsde.getEvidences()[0] != null || !"".equals(tsde.getEvidences()[0]))) {
79-
80- } else {
81- res = false;
82- msg.append(MSG_CHECK_EVIDENCE_FAIL);
83- }
84-
85- if ("○".equals(tsde.getEvidences()[1])) {
86- if ((tsde.getEvidences()[1] != null || !"".equals(tsde.getEvidences()[1]))) {
87-
88- } else {
89- res = false;
90- msg.append(MSG_CHECK_EVIDENCE_FAIL);
91- }
92- }
93-
94- if (this.checkExecute(tsde, msg)) {
95-
96- } else {
97- msg.append(MSG_EXECUTE_FAIL);
98- res = false;
99- }
100-
101- if (this.checkCheck(tsde, msg)) {
102-
103- } else {
104- msg.append(MSG_CHECK_FAIL);
105- res = false;
106- }
107-
108- }
109- return res;
110- }
111-
112- private boolean checkTestCaseId(String tescaseId) {
113- boolean res = true;
114- Pattern p = Pattern.compile(REGEXP_TESTCASEID_PATTERN);
115- Matcher match = p.matcher(tescaseId);
116-
117- if (tescaseId == null || "".equals(tescaseId) || !match.find()) {
118- res = false;
119- } else {
120-
121- }
122-
123- return res;
124- }
125-
126- private boolean checkExecute(TestSpecDetailsEntry tsde, StringBuffer buf) {
127- boolean res = true;
128-
129- if ("○".equals(tsde.getExcecuteResult()[0])) {
130-
131- if (tsde.getExeuters()[0] != null || !"".equals(tsde.getExeuters()[0])) {
132-
133- } else {
134- buf.append("実施1の担当者の記載がありません。");
135- res = false;
136- }
137-
138- if (tsde.getExecuteDates()[0] != null || !"".equals(tsde.getExecuteDates()[0])) {
139-
140- } else {
141- buf.append("実施1の実施日の記載がありません。");
142- res = false;
143- }
144-
145- } else {
146- if ("○".equals(tsde.getExcecuteResult()[1])) {
147-
148- if (tsde.getExeuters()[1] != null || !"".equals(tsde.getExeuters()[1])) {
149-
150- } else {
151- res = false;
152- buf.append("実施2の担当者の記載がありません。");
153- }
154-
155- if (tsde.getExecuteDates()[1] != null || !"".equals(tsde.getExecuteDates()[1])) {
156-
157- } else {
158- res = false;
159- buf.append("実施2の実施日の記載がありません。");
160- }
161-
162- } else {
163- buf.append(MSG_TEST_NOT_FINISHED);
164- res = false;
165- }
166- }
167- return res;
168- }
169-
170- private boolean checkCheck(TestSpecDetailsEntry tsde, StringBuffer buf) {
171- boolean res = true;
172-
173- //対象外の場合は早々にreturnする。
174- if(tsde.getCheckedDetails()[1] != null && tsde.getCheckedDetails()[1].contains("対象外")){
175- buf.append("本テストは実施対象外");
176- return true;
177- }
178-
179- if ("○".equals(tsde.getCheckedResults()[0])) {
180-
181- if (tsde.getCheckedDates()[0] != null && !"".equals(tsde.getCheckedDates()[0])) {
182-
183- } else {
184- buf.append("検証1の検証日の記載がありません。");
185- res = false;
186- }
187-
188- if (tsde.getCheckers()[0] != null && !"".equals(tsde.getCheckers()[0])) {
189-
190- } else {
191- buf.append("検証1の検証者の記載がありません。");
192- res = false;
193- }
194-
195- } else {
196- if ("○".equals(tsde.getCheckedResults()[1])) {
197-
198- if (tsde.getCheckedDates()[1] != null && !"".equals(tsde.getCheckedDates()[1])) {
199-
200- } else {
201- buf.append("検証2の検証日の記載がありません。\n");
202- res = false;
203- }
204-
205- if (tsde.getCheckers()[1] != null && !"".equals(tsde.getCheckers()[1])) {
206- buf.append("検証2の検証者の記載がありません。\n");
207- } else {
208- res = false;
209- }
210-
211- } else {
212- buf.append(MSG_CHEC_NOT_FINISHED);
213- res = false;
214- }
215- }
216- return res;
217- }
218-
219-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/XLSXResultWriter.java
+++ /dev/null
@@ -1,307 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer;
7-
8-import java.io.File;
9-import java.io.FileOutputStream;
10-import java.io.IOException;
11-
12-import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
13-import org.apache.poi.ss.usermodel.Cell;
14-
15-import org.apache.poi.ss.usermodel.IndexedColors;
16-import org.apache.poi.ss.usermodel.Row;
17-import org.apache.poi.ss.usermodel.Sheet;
18-import org.apache.poi.ss.usermodel.Workbook;
19-import org.apache.poi.ss.usermodel.WorkbookFactory;
20-import org.stux.common.Exception.StuxBasicException;
21-import org.stux.worktool.testspecanalizer.model.TestSpecCommon;
22-import org.stux.worktool.testspecanalizer.model.TestSpecCover;
23-import org.stux.worktool.testspecanalizer.model.TestSpecDetails;
24-import org.stux.worktool.testspecanalizer.model.TestSpecDetailsEntry;
25-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
26-import org.stux.worktool.testspecanalizer.model.TestSpecHistory;
27-import org.stux.worktool.testspecanalizer.model.TestSpecModel;
28-import org.stux.worktool.testspecanalizer.util.TestSpecChecker;
29-
30-/**
31- *
32- * @author YoshihiroSaitoh
33- */
34-public class XLSXResultWriter {
35-
36- private static final int COL_SHEET_NAME = 1;
37- private static final int COL_BUNRUI = 2;
38- private static final int COL_CHECK_DOCUMENT_NAME=3;
39- private static final int COL_CHECK_HISOTRY = 4;
40- private static final int COL_CHECK_HEADER = 5;
41- private static final int COL_CHECK_TEST_SUMMARY = 6;
42- private static final int COL_CHECK_TEST_RESULT = 7;
43- private static final int COL_CHECK_SEQ = 8;
44- private static final int COL_CREATE_DATE = 9;
45- private static final int COL_UPDATE_DATE = 10;
46- private static final int COL_CHECK_DDATE = 11;
47- private static final int COL_AUTHOR = 12;
48- private static final int COL_UPDATOR = 13;
49- private static final int COL_CHECKER = 14;
50- private static final int COL_NUMOFTESTS = 15;
51- private static final int COL_NUMOFEXECUTE = 16;
52- private static final int COL_NUMOFCHECKED = 17;
53- private static final int COL_TESTID = 18;
54- private static final int COL_TESTEVIDENCE = 19;
55- private static final int COL_BIKOU = 20;
56-
57- private static final int COL_FILE_NAME = 3;
58- private static final int COL_FILE_TEISAI = 3;
59- private static final int COL_FILE_NAME_CHECK = 3;
60- private static final int ROW_NUM_START = 6;
61-
62- private static final IndexedColors FAIL_BG_COLOR = IndexedColors.RED;
63- private static final IndexedColors NOMAL_BG_COLER = IndexedColors.WHITE;
64-
65- private static final String NAME_MASTERSHEET="masterシート";
66-
67- Workbook wb;
68- File resFile;
69-
70- int rowNum = 1;
71-
72- XLSXResultWriter(String mockFileName, String resultFileName) throws StuxBasicException {
73- try {
74-
75- resFile = new File(resultFileName);
76- if (resFile.exists()) {
77- resFile.delete();
78- }
79- wb = WorkbookFactory.create(new File(mockFileName));
80-
81- } catch (IOException ex) {
82- throw new StuxBasicException(ex, "雛形ファイルのオープン時にエラーが発生しました。");
83- } catch (InvalidFormatException ex) {
84- throw new StuxBasicException(ex, "ワークブックのオープンに失敗しました。");
85- }
86- }
87-
88- public void write(TestSpecModel model) throws StuxBasicException {
89-
90- //ワークシートをコピー
91- Sheet targetSheet = wb.cloneSheet(wb.getSheetIndex(wb.getSheet(NAME_MASTERSHEET)));
92- int ind = wb.getSheetIndex(targetSheet);
93- String sheetName = model.getFileName().replaceAll("(【NEON】テスト仕様書兼報告書_)(.*)(.xlsx)","$2");
94-
95- wb.setSheetName(
96- wb.getSheetIndex(targetSheet),
97- sheetName);
98-
99- targetSheet = wb.getSheetAt(ind);
100-
101- this.write(model, targetSheet);
102- }
103-
104- public void close() throws StuxBasicException {
105- try {
106- wb.removeSheetAt(wb.getSheetIndex(wb.getSheet(NAME_MASTERSHEET)));
107- wb.write(new FileOutputStream(resFile));
108- } catch (IOException ex) {
109- throw new StuxBasicException(ex, "ワークブックの保存に失敗しました");
110- }
111-
112- }
113-
114- private void write(TestSpecModel model, Sheet targetSheet) {
115- //記載開始位置(行)
116- rowNum =1;
117- Row row = targetSheet.getRow(rowNum);
118- StringBuffer buf = new StringBuffer();
119-
120- Cell targetCell;
121-
122- targetCell = row.getCell(COL_FILE_NAME);
123- targetCell.setCellValue(model.getFileName());
124-
125- //改行
126- row = targetSheet.getRow(++rowNum);
127-
128- try {
129- if (check(model, new OutLineChecker(), buf)) {
130- row.getCell(COL_FILE_TEISAI).setCellValue("○");
131- } else {
132- row.getCell(COL_FILE_TEISAI).setCellValue("×");
133- }
134- } catch (StuxBasicException ex) {
135- buf.append(ex.getMessage());
136- } finally {
137- row.getCell(COL_FILE_TEISAI + 1).setCellValue(String.valueOf(buf));
138- row.getCell(COL_FILE_TEISAI + 1).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
139- }
140-
141- //ファイル名確認
142- row = targetSheet.getRow(++rowNum);
143- buf = new StringBuffer();
144- try {
145- if (check(model, new FileNameChecker(), buf)) {
146- row.getCell(COL_FILE_NAME_CHECK).setCellValue("○");
147- } else {
148- row.getCell(COL_FILE_NAME_CHECK).setCellValue("×");
149- row.getCell(COL_FILE_NAME_CHECK + 1).setCellValue(String.valueOf(buf));
150- }
151- } catch (StuxBasicException ex) {
152- row.getCell(COL_FILE_NAME_CHECK + 1).setCellValue(ex.getMessage());
153- }
154-
155- rowNum = ROW_NUM_START;
156- row = targetSheet.getRow(rowNum);
157- try {
158- writeCover(row, model.getCover());
159- } catch (StuxBasicException ex) {
160- String temp = row.getCell(COL_BIKOU).getStringCellValue();
161- row.getCell(COL_BIKOU).setCellValue(temp + ex.getMessage());
162- //row.getCell(COL_BIKOU).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
163- }
164-
165- rowNum++;
166- row = targetSheet.getRow(rowNum);
167- try {
168- writeHisotry(row, model.getHistory());
169- } catch (StuxBasicException ex) {
170- String temp = row.getCell(COL_BIKOU).getStringCellValue();
171- row.getCell(COL_BIKOU).setCellValue(temp + ex.getMessage());
172- //row.getCell(COL_BIKOU).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
173- }
174- rowNum++;
175- for (TestSpecDetails detail : model.getSheets()) {
176- writeSpecSheets(targetSheet, detail);
177- }
178-
179- }
180-
181- private void writeCover(Row row, TestSpecCover cover) throws StuxBasicException {
182- StringBuffer buf = new StringBuffer();
183- writeCommon(row, cover, buf);
184- row.getCell(COL_BIKOU).setCellValue(String.valueOf(buf));
185- row.getCell(COL_BUNRUI).setCellValue("表紙");
186- }
187-
188- private void writeHisotry(Row row, TestSpecHistory history) throws StuxBasicException {
189- StringBuffer buf = new StringBuffer();
190- writeCommon(row, history, buf);
191- row.getCell(COL_BIKOU).setCellValue(String.valueOf(buf));
192- row.getCell(COL_BUNRUI).setCellValue("履歴");
193-
194- if (this.check(history, new RevChecker(), buf)) {
195- row.getCell(COL_CHECK_HISOTRY).setCellValue("○");
196- } else {
197- row.getCell(COL_CHECK_HISOTRY).setCellValue("×");
198-
199- }
200- row.getCell(COL_BIKOU).setCellValue(String.valueOf(buf));
201- }
202-
203- private void writeSpecSheets(Sheet sheet, TestSpecDetails details) {
204-
205- boolean formula = true;
206- for (TestSpecDetailsEntry entry : details.getDetails()) {
207- if (entry.isWritable()){
208- StringBuffer buf = new StringBuffer();
209- Row row = sheet.getRow(rowNum);
210-
211- try {
212- writeCommon(row, details, buf);
213-
214- if (check(entry, new TestKoumokuChecker(), buf)) {
215- row.getCell(COL_CHECK_TEST_SUMMARY).setCellValue("○");
216- row.getCell(COL_CHECK_TEST_RESULT).setCellValue("○");
217- } else {
218- row.getCell(COL_CHECK_TEST_SUMMARY).setCellValue("×");
219- //row.getCell(COL_CHECK_TEST_SUMMARY).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
220- row.getCell(COL_CHECK_TEST_RESULT).setCellValue("×");
221- //row.getCell(COL_CHECK_TEST_RESULT).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
222- }
223-
224- row.getCell(COL_BIKOU).setCellValue(String.valueOf(buf));
225- } catch (StuxBasicException ex) {
226- row.getCell(COL_BIKOU).setCellValue(String.valueOf(buf) + ex.getMessage());
227- //row.getCell(COL_BIKOU).getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
228- }
229-
230- row.getCell(COL_CHECK_SEQ).setCellValue(entry.getTestSequence());
231- row.getCell(COL_TESTID).setCellValue(entry.getTescaseId());
232-
233- if ("○".equals(entry.getExcecuteResult()[1])) {
234- row.getCell(COL_TESTEVIDENCE).setCellValue(entry.getEvidences()[1]);
235- } else {
236- row.getCell(COL_TESTEVIDENCE).setCellValue(entry.getEvidences()[0]);
237- }
238-
239- if (!formula) {
240- row.getCell(COL_NUMOFCHECKED).setCellValue(details.getNumOfCheck());
241- row.getCell(COL_NUMOFEXECUTE).setCellValue(details.getNumOfExcuted());
242- row.getCell(COL_NUMOFTESTS).setCellValue(details.getNumOfTests());
243- } else {
244- row.getCell(COL_NUMOFCHECKED).setCellValue(details.getNumOfCheckFormula());
245- row.getCell(COL_NUMOFEXECUTE).setCellValue(details.getNumOfExcutedFormula());
246- row.getCell(COL_NUMOFTESTS).setCellValue(details.getNumOfTestFormula());
247- formula = false;
248- }
249- rowNum++;
250- }
251- }
252- }
253-
254- private boolean check(TestSpecFactor model, TestSpecChecker checker, StringBuffer buf) throws StuxBasicException {
255- return checker.check(model, buf);
256- }
257-
258- private void writeCommon(Row row, TestSpecCommon target, StringBuffer buf) throws StuxBasicException {
259- Cell targetCell;
260-
261- targetCell = row.getCell(COL_SHEET_NAME);
262- targetCell.setCellValue(target.getSheetName());
263-
264- if (check(target,new DocumentChecker(),buf)){
265- targetCell = row.getCell(COL_CHECK_DOCUMENT_NAME);
266- targetCell.setCellValue("○");
267- } else {
268- targetCell = row.getCell(COL_CHECK_DOCUMENT_NAME);
269- targetCell.setCellValue("×");
270- }
271-
272- if (check(target, new HeaderChecker(), buf)) {
273- targetCell = row.getCell(COL_CHECK_HEADER);
274- targetCell.setCellValue("○");
275-
276- if (target instanceof TestSpecDetails) {
277- targetCell = row.getCell(COL_CHECK_TEST_SUMMARY);
278- targetCell.setCellValue("○");
279- }
280-
281- } else {
282- targetCell = row.getCell(COL_CHECK_HEADER);
283- targetCell.setCellValue("×");
284- //targetCell.getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
285-
286- if (target instanceof TestSpecDetails) {
287- targetCell = row.getCell(COL_CHECK_TEST_SUMMARY);
288- targetCell.setCellValue("×");
289- //targetCell.getCellStyle().setFillForegroundColor(FAIL_BG_COLOR.getIndex());
290- }
291- }
292- targetCell = row.getCell(COL_CREATE_DATE);
293- targetCell.setCellValue(target.getCreatedDate());
294- targetCell = row.getCell(COL_UPDATE_DATE);
295- targetCell.setCellValue(target.getUpdateDate());
296- targetCell = row.getCell(COL_CHECK_DDATE);
297- targetCell.setCellValue(target.getCheckedDate());
298- targetCell = row.getCell(COL_AUTHOR);
299- targetCell.setCellValue(target.getFirstAuthor());
300- targetCell = row.getCell(COL_UPDATOR);
301- targetCell.setCellValue(target.getLastAuthor());
302- targetCell = row.getCell(COL_CHECKER);
303- targetCell.setCellValue(target.getChecker());
304-
305- }
306-
307-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecCommon.java
+++ /dev/null
@@ -1,86 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-/**
9- *
10- * @author 0000011141935
11- */
12-public class TestSpecCommon implements TestSpecFactor{
13- private String documentName;
14- private String createdDate;
15- private String updateDate;
16- private String firstAuthor;
17- private String lastAuthor;
18- private String checker;
19- private String checkedDate;
20- private String sheetName;
21-
22- public String getSheetName() {
23- return sheetName;
24- }
25-
26- public void setSheetName(String sheetName) {
27- this.sheetName = sheetName;
28- }
29-
30- public void setDocumentName(String documentName) {
31- this.documentName = documentName;
32- }
33-
34- public void setCreatedDate(String createdDate) {
35- this.createdDate = createdDate;
36- }
37-
38- public void setUpdateDate(String updateDate) {
39- this.updateDate = updateDate;
40- }
41-
42- public void setFirstAuthor(String firstAuthor) {
43- this.firstAuthor = firstAuthor;
44- }
45-
46- public void setLastAuthor(String lastAuthor) {
47- this.lastAuthor = lastAuthor;
48- }
49-
50- public void setChecker(String checker) {
51- this.checker = checker;
52- }
53-
54- public String getDocumentName() {
55- return documentName;
56- }
57-
58- public String getCreatedDate() {
59- return createdDate;
60- }
61-
62- public String getUpdateDate() {
63- return updateDate;
64- }
65-
66- public String getFirstAuthor() {
67- return firstAuthor;
68- }
69-
70- public String getLastAuthor() {
71- return lastAuthor;
72- }
73-
74- public String getChecker() {
75- return checker;
76- }
77-
78- public String getCheckedDate() {
79- return checkedDate;
80- }
81-
82- public void setCheckedDate(String checkedDate) {
83- this.checkedDate = checkedDate;
84- }
85-
86-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecCover.java
+++ /dev/null
@@ -1,15 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import org.apache.poi.ss.usermodel.Sheet;
9-
10-/**
11- *
12- * @author 0000011141935
13- */
14-public class TestSpecCover extends TestSpecCommon {
15-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecDetails.java
+++ /dev/null
@@ -1,140 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import java.util.ArrayList;
9-import java.util.List;
10-import org.stux.common.Exception.StuxBasicException;
11-
12-/**
13- *
14- * @author YoshihiroSaitoh
15- */
16-public class TestSpecDetails extends TestSpecCommon {
17-
18- private List<TestSpecDetailsEntry> details;
19- //テスト項目数式
20- private String numOfTestFormula;
21- private String numOfTests;
22-
23- //実施消化件数式
24- private String numOfExcutedFormula;
25- private String numOfExcuted;
26-
27- //検証消化件数式
28- private String numOfCheckFormula;
29- private String numOfCheck;
30-
31- //テスト残件数式
32- private String numOfrestFormula;
33- //テスト消化率式
34- private String rateOfExcutedFormula;
35- //障害発生件数
36- private String numOfTroublesFormula;
37- //障害発生率式
38- private String rateOfTroublesFormula;
39-
40- public TestSpecDetails() {
41- details = new ArrayList<>();
42- }
43-
44- public void add(TestSpecDetailsEntry detail) throws StuxBasicException {
45- if (detail == null) {
46- throw new StuxBasicException("テストエントリが設定されていません。");
47- } else {
48- this.details.add(detail);
49- }
50- }
51-
52- public List<TestSpecDetailsEntry> getDetails() {
53- return details;
54- }
55-
56- public void setDetails(List<TestSpecDetailsEntry> details) {
57- this.details = details;
58- }
59-
60- public String getNumOfTestFormula() {
61- return numOfTestFormula;
62- }
63-
64- public void setNumOfTestFormula(String numOfTestFormula) {
65- this.numOfTestFormula = numOfTestFormula;
66- }
67-
68- public String getNumOfExcutedFormula() {
69- return numOfExcutedFormula;
70- }
71-
72- public void setNumOfExcutedFormula(String numOfExcutedFormula) {
73- this.numOfExcutedFormula = numOfExcutedFormula;
74- }
75-
76- public String getNumOfCheckFormula() {
77- return numOfCheckFormula;
78- }
79-
80- public void setNumOfCheckFormula(String numOfCheckFormula) {
81- this.numOfCheckFormula = numOfCheckFormula;
82- }
83-
84- public String getNumOfrestFormula() {
85- return numOfrestFormula;
86- }
87-
88- public void setNumOfrestFormula(String numOfrestFormula) {
89- this.numOfrestFormula = numOfrestFormula;
90- }
91-
92- public String getRateOfExcutedFormula() {
93- return rateOfExcutedFormula;
94- }
95-
96- public void setRateOfExcutedFormula(String rateOfExcutedFormula) {
97- this.rateOfExcutedFormula = rateOfExcutedFormula;
98- }
99-
100- public String getNumOfTroublesFormula() {
101- return numOfTroublesFormula;
102- }
103-
104- public void setNumOfTroublesFormula(String numOfTroublesFormula) {
105- this.numOfTroublesFormula = numOfTroublesFormula;
106- }
107-
108- public String getRateOfTroublesFormula() {
109- return rateOfTroublesFormula;
110- }
111-
112- public void setRateOfTroublesFormula(String rateOfTroublesFormula) {
113- this.rateOfTroublesFormula = rateOfTroublesFormula;
114- }
115-
116- public String getNumOfTests() {
117- return numOfTests;
118- }
119-
120- public void setNumOfTests(String numOfTests) {
121- this.numOfTests = numOfTests;
122- }
123-
124- public String getNumOfExcuted() {
125- return numOfExcuted;
126- }
127-
128- public void setNumOfExcuted(String numOfExcuted) {
129- this.numOfExcuted = numOfExcuted;
130- }
131-
132- public String getNumOfCheck() {
133- return numOfCheck;
134- }
135-
136- public void setNumOfCheck(String numOfCheck) {
137- this.numOfCheck = numOfCheck;
138- }
139-
140-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecDetailsEntry.java
+++ /dev/null
@@ -1,152 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import org.apache.poi.ss.usermodel.Sheet;
9-
10-/**
11- *
12- * @author 0000011141935
13- */
14-public class TestSpecDetailsEntry implements TestSpecEntry {
15-
16- private final int SIZE_OF_EXECUTES = 2;
17- private String tescaseId;
18- private String testSequence;
19- private String testDetails;
20- private String testExpectes;
21-
22- private String[] exeuters;
23- private String[] executeDates;
24- private String[] evidences;
25- private String[] excecuteResult;
26-
27- private String[] checkers;
28- private String[] checkedDates;
29- private String[] checkedResults;
30- private String[] checkedDetails;
31-
32- public TestSpecDetailsEntry() {
33- //配列を初期化
34- exeuters = new String[SIZE_OF_EXECUTES];
35- executeDates = new String[SIZE_OF_EXECUTES];
36- evidences = new String[SIZE_OF_EXECUTES];
37- excecuteResult = new String[SIZE_OF_EXECUTES];
38- checkers = new String[SIZE_OF_EXECUTES];
39- checkedDates = new String[SIZE_OF_EXECUTES];
40- checkedResults = new String[SIZE_OF_EXECUTES];
41- checkedDetails = new String[SIZE_OF_EXECUTES];
42-
43- }
44-
45- public String[] getExcecuteResult() {
46- return excecuteResult;
47- }
48-
49- public void setExcecuteResult(String[] excecuteResult) {
50- this.excecuteResult = excecuteResult;
51- }
52-
53- public String getTescaseId() {
54- return tescaseId;
55- }
56-
57- public void setTescaseId(String tescaseId) {
58- this.tescaseId = tescaseId;
59- }
60-
61- public String getTestSequence() {
62- return testSequence;
63- }
64-
65- public void setTestSequence(String testSequence) {
66- this.testSequence = testSequence;
67- }
68-
69- public String getTestDetails() {
70- return testDetails;
71- }
72-
73- public void setTestDetails(String testDetails) {
74- this.testDetails = testDetails;
75- }
76-
77- public String[] getExeuters() {
78- return exeuters;
79- }
80-
81- public void setExeuters(String[] exeuters) {
82- this.exeuters = exeuters;
83- }
84-
85- public String[] getExecuteDates() {
86- return executeDates;
87- }
88-
89- public void setExecuteDates(String[] executeDates) {
90- this.executeDates = executeDates;
91- }
92-
93- public String[] getEvidences() {
94- return evidences;
95- }
96-
97- public void setEvidences(String[] evidences) {
98- this.evidences = evidences;
99- }
100-
101- public String[] getCheckers() {
102- return checkers;
103- }
104-
105- public void setCheckers(String[] checkers) {
106- this.checkers = checkers;
107- }
108-
109- public String[] getCheckedDates() {
110- return checkedDates;
111- }
112-
113- public void setCheckedDates(String[] checkedDates) {
114- this.checkedDates = checkedDates;
115- }
116-
117- public String[] getCheckedResults() {
118- return checkedResults;
119- }
120-
121- public void setCheckedResults(String[] checkedResults) {
122- this.checkedResults = checkedResults;
123- }
124-
125- public String[] getCheckedDetails() {
126- return checkedDetails;
127- }
128-
129- public void setCheckedDetails(String[] checkedDetails) {
130- this.checkedDetails = checkedDetails;
131- }
132-
133- public String getTestExpectes() {
134- return testExpectes;
135- }
136-
137- public void setTestExpectes(String testExpectes) {
138- this.testExpectes = testExpectes;
139- }
140-
141- public boolean isWritable() {
142- boolean res = true;
143- res = res & (tescaseId == null || "".equals(tescaseId));
144- res = res & (testSequence == null || "".equals(testSequence));
145- res = res & (testDetails == null || "".equals(testDetails));
146- res = res & (testExpectes == null || "".equals(testExpectes));
147-
148- return !res;
149-
150- }
151-
152-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecEntry.java
+++ /dev/null
@@ -1,14 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-/**
9- *
10- * @author YoshihiroSaitoh
11- */
12-public interface TestSpecEntry extends TestSpecFactor{
13-
14-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecFactor.java
+++ /dev/null
@@ -1,14 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-/**
9- *
10- * @author YoshihiroSaitoh
11- */
12-public interface TestSpecFactor {
13-
14-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecHistory.java
+++ /dev/null
@@ -1,46 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import java.util.ArrayList;
9-import java.util.List;
10-import org.stux.common.Exception.StuxBasicException;
11-
12-/**
13- *
14- * @author YoshihiroSaitoh
15- */
16-public class TestSpecHistory extends TestSpecCommon{
17- private List<TestSpecHistoryEntry> histories;
18-
19- public TestSpecHistory(){
20- histories = new ArrayList<>();
21- }
22-
23- public void add(TestSpecHistoryEntry entry) throws StuxBasicException{
24- if(histories == null){
25- histories = new ArrayList<>();
26- }
27-
28- if(entry == null){
29- throw new StuxBasicException("履歴情報がNullオブジェクトです");
30- } else {
31- histories.add(entry);
32- }
33- }
34-
35- public TestSpecHistoryEntry getLastUpdateInfo(){
36- //TODO 最後の情報が本当に取得できるかのテスト必須
37- TestSpecHistoryEntry hist=new TestSpecHistoryEntry();
38- for(TestSpecHistoryEntry currentHist:histories){
39- if(currentHist.getRev()!=null && !"".equals(currentHist.getRev())){
40- hist = currentHist;
41- }
42- }
43- return hist;
44- }
45-
46-}
\ No newline at end of file
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecHistoryEntry.java
+++ /dev/null
@@ -1,81 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-/**
9- *
10- * @author 0000011141935
11- */
12-public class TestSpecHistoryEntry implements TestSpecEntry{
13- private String no;
14- private String rev;
15- private String anken;
16- private String changedDate;
17- private String Sheet;
18- private String changedCont;
19- private String changer;
20-
21- public String getNo() {
22- return no;
23- }
24-
25- public void setNo(String no) {
26- this.no = no;
27- }
28-
29- public String getRev() {
30- return rev;
31- }
32-
33- public void setRev(String rev) {
34- this.rev = rev;
35- }
36-
37- public String getAnken() {
38- return anken;
39- }
40-
41- public void setAnken(String ankenNo) {
42- this.anken = ankenNo;
43- }
44-
45- public String getChangedDate() {
46- return changedDate;
47- }
48-
49- public void setChangedDate(String changedDate) {
50- this.changedDate = changedDate;
51- }
52-
53- public String getSheet() {
54- return Sheet;
55- }
56-
57- public void setSheet(String Sheet) {
58- this.Sheet = Sheet;
59- }
60-
61- public String getChangedCont() {
62- return changedCont;
63- }
64-
65- public void setChangedCont(String changedCont) {
66- this.changedCont = changedCont;
67- }
68-
69- public String getChanger() {
70- return changer;
71- }
72-
73- public void setChanger(String changer) {
74- this.changer = changer;
75- }
76-
77-
78-
79-
80-
81-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecModel.java
+++ /dev/null
@@ -1,94 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import java.util.ArrayList;
9-import java.util.List;
10-import org.stux.common.Exception.StuxBasicException;
11-
12-/**
13- *
14- * @author 0000011141935
15- */
16-public class TestSpecModel implements TestSpecFactor{
17-
18- private String fileName;
19- private TestSpecCover cover;
20- private TestSpecHistory history;
21- private List<TestSpecDetails> sheets;
22-
23- private boolean hasAcover;
24- private boolean hasAhistory;
25-
26- public TestSpecModel() {
27- this.sheets = new ArrayList();
28- }
29-
30- public void setDetails(TestSpecDetails entry) throws StuxBasicException {
31- if (entry == null) {
32- throw new StuxBasicException("エントリ情報が設定されいません。");
33- } else {
34- this.sheets.add(entry);
35- }
36- }
37-
38- public void setSpecCover(TestSpecCover entry) throws StuxBasicException {
39- if (entry == null) {
40- throw new StuxBasicException("エントリ情報が設定されいません。");
41- } else {
42- this.cover=entry;
43- }
44- }
45-
46- public void setSpecHistory(TestSpecHistory entry) throws StuxBasicException {
47- if (entry == null) {
48- throw new StuxBasicException("エントリ情報が設定されいません。");
49- } else {
50- this.history=entry;
51- }
52- }
53-
54- public TestSpecCover getCover() {
55- return cover;
56- }
57-
58- public List<TestSpecDetails> getSheets() {
59- return sheets;
60- }
61-
62- public String getFileName() {
63- return fileName;
64- }
65-
66- public void setFileName(String fileName) {
67- this.fileName = fileName;
68- }
69-
70- public TestSpecHistory getHistory() {
71- return history;
72- }
73-
74- public void setHistory(TestSpecHistory history) {
75- this.history = history;
76- }
77-
78- public boolean isHasAcover() {
79- return hasAcover;
80- }
81-
82- public void setHasAcover(boolean hasAcover) {
83- this.hasAcover = hasAcover;
84- }
85-
86- public boolean isHasAhistory() {
87- return hasAhistory;
88- }
89-
90- public void setHasAhistory(boolean hasAhistory) {
91- this.hasAhistory = hasAhistory;
92- }
93-
94-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/model/TestSpecScanner.java
+++ /dev/null
@@ -1,22 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.model;
7-
8-import java.io.File;
9-import org.stux.common.Exception.StuxBasicException;
10-import org.stux.worktool.reviewinfocounter.ReviewFileScanner;
11-
12-/**
13- *
14- * @author 0000011141935
15- */
16-public class TestSpecScanner extends ReviewFileScanner{
17-
18- public TestSpecScanner(File file) throws StuxBasicException {
19- super(file);
20- }
21-
22-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/parser/TestSpecFileParser.java
+++ /dev/null
@@ -1,320 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.parser;
7-
8-import java.io.File;
9-import java.io.FileInputStream;
10-import java.io.IOException;
11-import java.util.HashMap;
12-import java.util.Map;
13-import java.util.Properties;
14-import org.apache.poi.ss.usermodel.Sheet;
15-import org.stux.common.Exception.StuxBasicException;
16-import org.stux.common.util.excel.BaseExcelParser;
17-import org.stux.common.util.excel.IndexInfo;
18-import org.stux.worktool.testspecanalizer.model.TestSpecCommon;
19-import org.stux.worktool.testspecanalizer.model.TestSpecCover;
20-import org.stux.worktool.testspecanalizer.model.TestSpecDetails;
21-import org.stux.worktool.testspecanalizer.model.TestSpecDetailsEntry;
22-import org.stux.worktool.testspecanalizer.model.TestSpecHistory;
23-import org.stux.worktool.testspecanalizer.model.TestSpecHistoryEntry;
24-import org.stux.worktool.testspecanalizer.model.TestSpecModel;
25-
26-/**
27- *
28- * @author 0000011141935
29- */
30-public class TestSpecFileParser extends BaseExcelParser {
31-
32- private final String KEY_NAME_COVER_SHEET = "name.cover.sheet";
33- private final String KEY_IND_DOCUMENT_NAME = "ind.document.name";
34- private final String KEY_IND_CREATED_DATE = "ind.created.date";
35- private final String KEY_IND_AUTHOR = "ind.author";
36- private final String KEY_IND_LAST_UPDATE_DATE = "ind.last.update.date";
37- private final String KEY_IND_LAST_UPDATER = "ind.last.updater";
38- private final String KEY_IND_CHECKED_DATE = "ind.checked.date";
39- private final String KEY_IND_CHECKER = "ind.checker";
40-
41- private final String KEY_NAME_HISTORY_SHEET = "name.hisotry.sheet";
42- private final String KEY_IND_DECISION_CELL = "ind.decision.cell";
43- private final String KEY_IND_DECISION_VALUE = "ind.decision.value";
44- private final String KEY_IND_HIST_NO = "ind.hist.no";
45- private final String KEY_IND_ANKEN = "ind.anken";
46- private final String KEY_IND_CHANGED_DATE = "ind.changed.date";
47- private final String KEY_IND_REV = "ind.rev";
48- private final String KEY_IND_SHEET = "ind.sheet";
49- private final String KEY_IND_HIST_CHANGED = "ind.hist.changed";
50- private final String KEY_IND_HIST_TANTO = "ind.hist.tanto";
51-
52- //テストシート関連
53- private final String KEY_IND_NUMOFTESTS = "ind.numoftests";
54- private final String KEY_IND_NUMOFEXECUTEDTESTS = "ind.numofexecutedtests";
55- private final String KEY_IND_NUMOFCHECKEDTESTS = "ind.numofcheckedtests";
56- private final String KEY_IND_NUMOFLEFT = "ind.numofleft";
57- private final String KEY_IND_RATEOFENDED = "ind.rateofended";
58- private final String KEY_IND_NUMOFTROUBLES = "ind.numoftroulbes";
59- private final String KEY_IND_RATEOFTROBLES = "ind.rateoftroubles";
60-
61- private final String KEY_IND_TESTCASE_ID = "ind.testcaseid";
62- private final String KEY_IND_SEQUENCE = "ind.sequence";
63- private final String KEY_IND_TEST_DETAILS = "ind.details";
64- private final String KEY_IND_EXCPECTED_RESULTS = "ind.expected.results";
65-
66- private final String KEY_IND_NO1_EXECUTER = "ind.no1.executer";
67- private final String KEY_IND_NO1_DATE = "ind.no1.date";
68- private final String KEY_IND_NO1_RESULT = "ind.no1.result";
69- private final String KEY_IND_NO1_EVIDENCE = "ind.no1.evidence";
70-
71- private final String KEY_IND_NO2_EXECUTER = "ind.no2.executer";
72- private final String KEY_IND_NO2_DATE = "ind.no2.date";
73- private final String KEY_IND_NO2_RESULT = "ind.no2.result";
74- private final String KEY_IND_NO2_EVIDENCE = "ind.no2.evidence";
75-
76- private final String KEY_IND_NO1_CHECKER = "ind.no1.checker";
77- private final String KEY_IND_NO1_CHECKED_DATE = "ind.no1.checked.date";
78- private final String KEY_IND_NO1_CHECKED_RESULT = "ind.no1.checked.result";
79- private final String KEY_IND_NO1_DETAILS = "ind.no1.detais";
80-
81- private final String KEY_IND_NO2_CHECKER = "ind.no2.checker";
82- private final String KEY_IND_NO2_CHECKED_DATE = "ind.no2.checked.date";
83- private final String KEY_IND_NO2_CHECKED_RESULT = "ind.no2.checked.result";
84- private final String KEY_IND_NO2_DETAILS = "ind.no2.detais";
85-
86- private final String STR_COVERNAME = "表紙";
87- private final String STR_HISOTRY = "改訂履歴";
88-
89- private TestSpecModel testSpecModel;
90- private Map<String, IndexInfo> sheetInfo;
91- private String decisionVal;
92-
93- public TestSpecFileParser() throws StuxBasicException {
94- super();
95- decisionVal = "";
96- try {
97- Properties prop = new Properties();
98- propFilepath = System.getProperty(KEY_PROP_PATH);
99- File propFile = new File(propFilepath);
100-
101- testSpecModel = new TestSpecModel();
102- testSpecModel.setFileName(fileName);
103- prop.load(new FileInputStream(propFile));
104-
105- decisionVal = prop.getProperty(KEY_IND_DECISION_VALUE);
106- this.loadSheetInfo(prop);
107-
108- } catch (IOException ex) {
109- throw new StuxBasicException(ex, "プロパティファイルの読み込みに失敗しました。");
110- }
111- }
112-
113- @Override
114- public void parse(Map<Integer, Sheet> sheets) throws StuxBasicException {
115- testSpecModel = new TestSpecModel();
116- for (Integer key : sheets.keySet()) {
117- Sheet currentSheet = sheets.get(key);
118- String sheetName = currentSheet.getSheetName();
119- if (testSpecModel == null) {
120- testSpecModel = new TestSpecModel();
121-
122- }
123- testSpecModel.setFileName(fileName);
124- switch (sheetName) {
125- case STR_COVERNAME:
126- testSpecModel.setSpecCover(this.createCoverInfo(currentSheet));
127-
128- break;
129- case STR_HISOTRY:
130- testSpecModel.setHistory(this.createHisotry(currentSheet));
131- break;
132- default:
133- if (isDetailSheet(currentSheet)) {
134- testSpecModel.setDetails(this.createSpecInfo(currentSheet));
135- }
136- }
137-
138- }
139- }
140-
141- public TestSpecModel getTestSpecModel() {
142- return testSpecModel;
143- }
144-
145- private void loadSheetInfo(Properties prop) throws StuxBasicException {
146- sheetInfo = new HashMap<>();
147-
148- //sheetInfo.put(KEY_NAME_COVER_SHEET, new IndexInfo(prop.getProperty(KEY_NAME_COVER_SHEET)));
149- sheetInfo.put(KEY_IND_DOCUMENT_NAME, new IndexInfo(prop.getProperty(KEY_IND_DOCUMENT_NAME)));
150- sheetInfo.put(KEY_IND_CREATED_DATE, new IndexInfo(prop.getProperty(KEY_IND_CREATED_DATE)));
151- sheetInfo.put(KEY_IND_AUTHOR, new IndexInfo(prop.getProperty(KEY_IND_AUTHOR)));
152- sheetInfo.put(KEY_IND_LAST_UPDATE_DATE, new IndexInfo(prop.getProperty(KEY_IND_LAST_UPDATE_DATE)));
153- sheetInfo.put(KEY_IND_LAST_UPDATER, new IndexInfo(prop.getProperty(KEY_IND_LAST_UPDATER)));
154- sheetInfo.put(KEY_IND_CHECKED_DATE, new IndexInfo(prop.getProperty(KEY_IND_CHECKED_DATE)));
155- sheetInfo.put(KEY_IND_CHECKER, new IndexInfo(prop.getProperty(KEY_IND_CHECKER)));
156-
157- //sheetInfo.put(KEY_NAME_HISTORY_SHEET, new IndexInfo(prop.getProperty(KEY_NAME_HISTORY_SHEET)));
158- sheetInfo.put(KEY_IND_DECISION_CELL, new IndexInfo(prop.getProperty(KEY_IND_DECISION_CELL)));
159-
160- sheetInfo.put(KEY_IND_NUMOFTESTS, new IndexInfo(prop.getProperty(KEY_IND_NUMOFTESTS)));
161- sheetInfo.put(KEY_IND_NUMOFEXECUTEDTESTS, new IndexInfo(prop.getProperty(KEY_IND_NUMOFEXECUTEDTESTS)));
162- sheetInfo.put(KEY_IND_NUMOFCHECKEDTESTS, new IndexInfo(prop.getProperty(KEY_IND_NUMOFCHECKEDTESTS)));
163- sheetInfo.put(KEY_IND_NUMOFLEFT, new IndexInfo(prop.getProperty(KEY_IND_NUMOFLEFT)));
164- sheetInfo.put(KEY_IND_RATEOFENDED, new IndexInfo(prop.getProperty(KEY_IND_RATEOFENDED)));
165- sheetInfo.put(KEY_IND_NUMOFTROUBLES, new IndexInfo(prop.getProperty(KEY_IND_NUMOFTROUBLES)));
166- sheetInfo.put(KEY_IND_RATEOFTROBLES, new IndexInfo(prop.getProperty(KEY_IND_RATEOFTROBLES)));
167-
168- sheetInfo.put(KEY_IND_TESTCASE_ID, new IndexInfo(prop.getProperty(KEY_IND_TESTCASE_ID)));
169- sheetInfo.put(KEY_IND_SEQUENCE, new IndexInfo(prop.getProperty(KEY_IND_SEQUENCE)));
170- sheetInfo.put(KEY_IND_TEST_DETAILS, new IndexInfo(prop.getProperty(KEY_IND_TEST_DETAILS)));
171- sheetInfo.put(KEY_IND_EXCPECTED_RESULTS, new IndexInfo(prop.getProperty(KEY_IND_EXCPECTED_RESULTS)));
172-
173- sheetInfo.put(KEY_IND_NO1_EXECUTER, new IndexInfo(prop.getProperty(KEY_IND_NO1_EXECUTER)));
174- sheetInfo.put(KEY_IND_NO1_DATE, new IndexInfo(prop.getProperty(KEY_IND_NO1_DATE)));
175- sheetInfo.put(KEY_IND_NO1_RESULT, new IndexInfo(prop.getProperty(KEY_IND_NO1_RESULT)));
176- sheetInfo.put(KEY_IND_NO1_EVIDENCE, new IndexInfo(prop.getProperty(KEY_IND_NO1_EVIDENCE)));
177-
178- sheetInfo.put(KEY_IND_NO2_EXECUTER, new IndexInfo(prop.getProperty(KEY_IND_NO2_EXECUTER)));
179- sheetInfo.put(KEY_IND_NO2_DATE, new IndexInfo(prop.getProperty(KEY_IND_NO2_DATE)));
180- sheetInfo.put(KEY_IND_NO2_RESULT, new IndexInfo(prop.getProperty(KEY_IND_NO2_RESULT)));
181- sheetInfo.put(KEY_IND_NO2_EVIDENCE, new IndexInfo(prop.getProperty(KEY_IND_NO2_EVIDENCE)));
182-
183- sheetInfo.put(KEY_IND_NO1_CHECKER, new IndexInfo(prop.getProperty(KEY_IND_NO1_CHECKER)));
184- sheetInfo.put(KEY_IND_NO1_CHECKED_DATE, new IndexInfo(prop.getProperty(KEY_IND_NO1_CHECKED_DATE)));
185- sheetInfo.put(KEY_IND_NO1_CHECKED_RESULT, new IndexInfo(prop.getProperty(KEY_IND_NO1_CHECKED_RESULT)));
186- sheetInfo.put(KEY_IND_NO1_DETAILS, new IndexInfo(prop.getProperty(KEY_IND_NO1_DETAILS)));
187-
188- sheetInfo.put(KEY_IND_NO2_CHECKER, new IndexInfo(prop.getProperty(KEY_IND_NO2_CHECKER)));
189- sheetInfo.put(KEY_IND_NO2_CHECKED_DATE, new IndexInfo(prop.getProperty(KEY_IND_NO2_CHECKED_DATE)));
190- sheetInfo.put(KEY_IND_NO2_CHECKED_RESULT, new IndexInfo(prop.getProperty(KEY_IND_NO2_CHECKED_RESULT)));
191- sheetInfo.put(KEY_IND_NO2_DETAILS, new IndexInfo(prop.getProperty(KEY_IND_NO2_DETAILS)));
192-
193- //sheetInfo.put(KEY_NAME_HISTORY_SHEET, new IndexInfo(prop.getProperty(KEY_NAME_HISTORY_SHEET)));
194- sheetInfo.put(KEY_IND_DECISION_CELL, new IndexInfo(prop.getProperty(KEY_IND_DECISION_CELL)));
195- sheetInfo.put(KEY_IND_ANKEN, new IndexInfo(prop.getProperty(KEY_IND_ANKEN)));
196- sheetInfo.put(KEY_IND_CHANGED_DATE, new IndexInfo(prop.getProperty(KEY_IND_CHANGED_DATE)));
197- sheetInfo.put(KEY_IND_REV, new IndexInfo(prop.getProperty(KEY_IND_REV)));
198- sheetInfo.put(KEY_IND_SHEET, new IndexInfo(prop.getProperty(KEY_IND_SHEET)));
199- sheetInfo.put(KEY_IND_HIST_CHANGED, new IndexInfo(prop.getProperty(KEY_IND_HIST_CHANGED)));
200- sheetInfo.put(KEY_IND_HIST_TANTO, new IndexInfo(prop.getProperty(KEY_IND_HIST_TANTO)));
201- sheetInfo.put(KEY_IND_HIST_NO, new IndexInfo(prop.getProperty(KEY_IND_HIST_NO)));
202-
203- }
204-
205- private TestSpecCover createCoverInfo(Sheet currentSheet) {
206- TestSpecCover tsc = new TestSpecCover();
207- createCommonInfo(currentSheet, tsc);
208- return tsc;
209- }
210-
211- private TestSpecHistory createHisotry(Sheet currentSheet) throws StuxBasicException {
212- TestSpecHistory history = new TestSpecHistory();
213- createCommonInfo(currentSheet, history);
214-
215- for (int i = sheetInfo.get(KEY_IND_HIST_NO).getRow() + 1; i < currentSheet.getLastRowNum(); i++) {
216- TestSpecHistoryEntry tsrh = new TestSpecHistoryEntry();
217- tsrh.setAnken(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_ANKEN)));
218- tsrh.setChangedCont(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_HIST_CHANGED)));
219- tsrh.setChangedDate(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_CHANGED_DATE)));
220- tsrh.setChanger(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_HIST_TANTO)));
221- tsrh.setNo(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_HIST_NO)));
222- tsrh.setRev(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_REV)));
223- tsrh.setSheet(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_SHEET)));
224- history.add(tsrh);
225- }
226-
227- return history;
228-
229- }
230-
231- private TestSpecDetails createSpecInfo(Sheet currentSheet) throws StuxBasicException {
232- TestSpecDetails tsd = new TestSpecDetails();
233- this.createCommonInfo(currentSheet, tsd);
234-
235- tsd.setNumOfCheckFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFCHECKEDTESTS)));
236- tsd.setNumOfExcutedFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFEXECUTEDTESTS)));
237- tsd.setNumOfTestFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFTESTS)));
238- tsd.setNumOfTroublesFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFTROUBLES)));
239- tsd.setNumOfrestFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFLEFT)));
240- tsd.setRateOfExcutedFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_RATEOFENDED)));
241- tsd.setRateOfTroublesFormula(getStringValue(currentSheet, sheetInfo.get(KEY_IND_RATEOFTROBLES)));
242-
243- tsd.setNumOfCheck(getFormulaValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFCHECKEDTESTS)));
244- tsd.setNumOfExcuted(getFormulaValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFEXECUTEDTESTS)));
245- tsd.setNumOfTests(getFormulaValue(currentSheet, sheetInfo.get(KEY_IND_NUMOFTESTS)));
246-
247- for (int i = sheetInfo.get(KEY_IND_TESTCASE_ID).getRow() + 1; i <=currentSheet.getLastRowNum(); i++) {
248-
249- String[] exeuters;
250- String[] executeDates;
251- String[] evidences;
252- String[] executeResults;
253-
254- String[] checkers;
255- String[] checkedDates;
256- String[] checkedResults;
257- String[] checkedDetails;
258-
259- TestSpecDetailsEntry tsde = new TestSpecDetailsEntry();
260-
261- tsde.setTescaseId(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_TESTCASE_ID)));
262-
263- tsde.setTestDetails(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_TEST_DETAILS)));
264-
265- tsde.setTestSequence(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_SEQUENCE)));
266-
267- tsde.setTestExpectes(getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_EXCPECTED_RESULTS)));
268- exeuters = tsde.getExeuters();
269- executeDates = tsde.getExecuteDates();
270-
271- evidences = tsde.getEvidences();
272- checkers = tsde.getCheckers();
273- checkedDates = tsde.getCheckedDates();
274- checkedResults = tsde.getCheckedResults();
275- checkedDetails = tsde.getCheckedDetails();
276- executeResults = tsde.getExcecuteResult();
277-
278- exeuters[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_EXECUTER));
279- executeDates[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_DATE));
280- evidences[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_EVIDENCE));
281- executeResults[0] = getStringValue(currentSheet,i,sheetInfo.get(KEY_IND_NO1_RESULT));
282-
283- checkers[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_CHECKER));
284- checkedDates[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_CHECKED_DATE));
285- checkedResults[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_CHECKED_RESULT));
286- checkedDetails[0] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO1_DETAILS));
287-
288- exeuters[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_EXECUTER));
289- executeDates[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_DATE));
290- evidences[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_EVIDENCE));
291- executeResults[1] = getStringValue(currentSheet,i,sheetInfo.get(KEY_IND_NO2_RESULT));
292-
293- checkers[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_CHECKER));
294- checkedDates[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_CHECKED_DATE));
295- checkedResults[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_CHECKED_RESULT));
296- checkedDetails[1] = getStringValue(currentSheet, i, sheetInfo.get(KEY_IND_NO2_DETAILS));
297-
298- tsd.add(tsde);
299-
300- }
301- return tsd;
302- }
303-
304- private void createCommonInfo(Sheet currentSheet, TestSpecCommon tsc) {
305- tsc.setDocumentName(getStringValue(currentSheet, sheetInfo.get(KEY_IND_DOCUMENT_NAME)));
306- tsc.setChecker(getStringValue(currentSheet, sheetInfo.get(KEY_IND_CHECKER)));
307- tsc.setCreatedDate(getStringValue(currentSheet, sheetInfo.get(KEY_IND_CREATED_DATE)));
308- tsc.setCheckedDate(getStringValue(currentSheet, sheetInfo.get(KEY_IND_CHECKED_DATE)));
309- tsc.setFirstAuthor(getStringValue(currentSheet, sheetInfo.get(KEY_IND_AUTHOR)));
310- tsc.setLastAuthor(getStringValue(currentSheet, sheetInfo.get(KEY_IND_LAST_UPDATER)));
311- tsc.setUpdateDate(getStringValue(currentSheet, sheetInfo.get(KEY_IND_LAST_UPDATE_DATE)));
312- tsc.setSheetName(currentSheet.getSheetName());
313- }
314-
315- private boolean isDetailSheet(Sheet currentSheet) {
316- String celValDecision = this.getStringValue(currentSheet, sheetInfo.get(KEY_IND_DECISION_CELL));
317- return decisionVal.equals(celValDecision);
318- }
319-
320-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/pr/MainScreenController.java
+++ /dev/null
@@ -1,27 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.pr;
7-
8-import java.net.URL;
9-import java.util.ResourceBundle;
10-import javafx.fxml.Initializable;
11-
12-/**
13- * FXML Controller class
14- *
15- * @author YoshihiroSaitoh
16- */
17-public class MainScreenController implements Initializable {
18-
19- /**
20- * Initializes the controller class.
21- */
22- @Override
23- public void initialize(URL url, ResourceBundle rb) {
24- // TODO
25- }
26-
27-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/util/TestSpecChecker.java
+++ /dev/null
@@ -1,17 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.util;
7-
8-import org.stux.common.Exception.StuxBasicException;
9-import org.stux.worktool.testspecanalizer.model.TestSpecFactor;
10-
11-/**
12- *
13- * @author YoshihiroSaitoh
14- */
15-public interface TestSpecChecker {
16- public boolean check(TestSpecFactor tsf,StringBuffer msg)throws StuxBasicException;
17-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecanalizer/util/TestSpecFileScanner.java
+++ /dev/null
@@ -1,33 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecanalizer.util;
7-
8-import java.io.File;
9-import java.io.FileFilter;
10-import org.stux.common.Exception.StuxBasicException;
11-import org.stux.common.util.file.BasicFileObjectScanner;
12-
13-/**
14- *
15- * @author 0000011141935
16- */
17-public class TestSpecFileScanner extends BasicFileObjectScanner{
18-
19- public TestSpecFileScanner(File file) throws StuxBasicException {
20- super(file);
21- }
22-
23- @Override
24- public FileFilter getFileFileter() {
25- FileFilter filter = (f) -> {
26- return (f.getName().lastIndexOf(".xlsx") > 0
27- || f.getName().lastIndexOf(".xls") > 0
28- );
29- };
30-
31- return filter; }
32-
33-}
--- a/stux.common/src/main/java/org/stux/worktool/testspecrewiter/XlsxReWriter.java
+++ /dev/null
@@ -1,16 +0,0 @@
1-/*
2- * To change this license header, choose License Headers in Project Properties.
3- * To change this template file, choose Tools | Templates
4- * and open the template in the editor.
5- */
6-package org.stux.worktool.testspecrewiter;
7-
8-import java.io.File;
9-
10-/**
11- *
12- * @author 0000011141935
13- */
14-public interface XlsxReWriter {
15- public void rewrite(File target);
16-}