Energy,Resolution,Efficiency功能的call增加判断

This commit is contained in:
qiaoqinzheng 2023-09-20 16:29:31 +08:00
parent 59d063d415
commit 5e5474eb2f

View File

@ -1356,13 +1356,14 @@ public class GammaServiceImpl implements IGammaService {
if (line.contains("#g_Energy") || line.contains("#Energy")) {
for (int j=i+1; j<readLines.size(); j++) {
String content = readLines.get(j);
if (content.contains("#")) {
break;
if (!content.contains("#")) {
List<String> values = Arrays.asList(content.split("\t\t"));
if (Double.valueOf(values.get(1))>0) {
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurCentroid.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
}
}
List<String> values = Arrays.asList(content.split("\t\t"));
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurCentroid.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
}
}
}
@ -1589,13 +1590,14 @@ public class GammaServiceImpl implements IGammaService {
if (line.contains("#g_Resolution") || line.contains("#Resolution")) {
for (int j=i+1; j<readLines.size(); j++) {
String content = readLines.get(j);
if (content.contains("#")) {
break;
if (!content.contains("#")) {
List<String> values = Arrays.asList(content.split("\t\t"));
if (Double.valueOf(values.get(0))>0) {
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurReso.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
}
}
List<String> values = Arrays.asList(content.split("\t\t"));
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurReso.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
}
}
}
@ -1835,14 +1837,16 @@ public class GammaServiceImpl implements IGammaService {
String content = readLines.get(j);
if (!content.contains("#") && !content.contains("FitType")) {
List<String> values = Arrays.asList(content.split("\t\t"));
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurEffi.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
if (Double.valueOf(values.get(0))>0) {
m_vCurEnergy.add(Double.valueOf(values.get(0)));
m_vCurEffi.add(Double.valueOf(values.get(1)));
m_vCurUncert.add(Double.valueOf(values.get(2)));
}
}
if (content.contains("FitType")) {
List<String> values = Arrays.asList(content.split("="));
if (values.size() == 2) {
m_nFunId = Double.valueOf(values.get(1));
m_nFunId = Double.valueOf(values.get(1).trim());
}
}
}