1 | package de.uka.ipd.sdq.dsexplore.analysis.lqn; |
2 | |
3 | import org.eclipse.core.runtime.CoreException; |
4 | import org.opt4j.core.Criterion; |
5 | |
6 | import LqnCore.LqnModelType; |
7 | import de.uka.ipd.sdq.dsexplore.analysis.AnalysisFailedException; |
8 | import de.uka.ipd.sdq.dsexplore.analysis.IAnalysisResult; |
9 | import de.uka.ipd.sdq.pcmsolver.models.PCMInstance; |
10 | import de.uka.ipd.sdq.pcmsolver.runconfig.MessageStrings; |
11 | |
12 | /** |
13 | * Starts a LQN simulation analysis for the design space exploration. |
14 | * |
15 | * @author pmerkle, martens |
16 | * |
17 | */ |
18 | public class LQSimAnalysis extends AbstractLQNAnalysis { |
19 | |
20 | |
21 | @Override |
22 | protected String getSolverMessageString() { |
23 | return MessageStrings.LQSIM_SOLVER; |
24 | } |
25 | |
26 | @Override |
27 | protected LQNResult retrieveResult(PCMInstance pcm, |
28 | LqnModelType model, Criterion criterion) throws AnalysisFailedException { |
29 | LQSimAnalysisResult result = new LQSimAnalysisResult(model, pcm, criterion, this.criterionToAspect, this.lQNQualityAttribute); |
30 | return result; |
31 | } |
32 | |
33 | |
34 | @Override |
35 | public boolean hasStatisticResults() throws CoreException { |
36 | return false; |
37 | } |
38 | |
39 | @Override |
40 | protected IAnalysisResult handleException(RuntimeException e, PCMInstance pcm) { |
41 | throw e; |
42 | } |
43 | |
44 | @Override |
45 | public boolean hasObjectivePerUsageScenario() throws CoreException { |
46 | return true; |
47 | } |
48 | |
49 | } |