Showing 30 of 30 files from the diff.

@@ -62,9 +62,9 @@
Loading
62 62
63 63
    @Override
64 64
    public List<Parameter> getParameters() {
65 -
        List<Parameter> parameters = new ArrayList<Parameter>();
66 -
        parameters.add(new GenericParameter<String>("sequence", this.getSequence()));
67 -
        parameters.add(new GenericParameter<String>("table", this.table));
65 +
        List<Parameter> parameters = new ArrayList<>();
66 +
        parameters.add(new GenericParameter<>("sequence", this.getSequence()));
67 +
        parameters.add(new GenericParameter<>("table", this.table));
68 68
        return parameters;
69 69
    }
70 70

@@ -50,8 +50,8 @@
Loading
50 50
51 51
    @Override
52 52
    public List<Parameter> getParameters() {
53 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
54 -
        parameters.add(new GenericParameter<String>("file", filePath, true));
53 +
        ArrayList<Parameter> parameters = new ArrayList<>();
54 +
        parameters.add(new GenericParameter<>("file", filePath, true));
55 55
        return parameters;
56 56
    }
57 57
}

@@ -55,10 +55,10 @@
Loading
55 55
56 56
    @Override
57 57
    public List<Parameter> getParameters() {
58 -
        List<Parameter> parameters = new ArrayList<Parameter>();
58 +
        List<Parameter> parameters = new ArrayList<>();
59 59
        for (String attribute : this.element.getAttributeNames()) {
60 60
            if (this.element.getAttribute(attribute) != null) {
61 -
                parameters.add(new GenericParameter<Double>(attribute, this.element.getAttribute(attribute)));
61 +
                parameters.add(new GenericParameter<>(attribute, this.element.getAttribute(attribute)));
62 62
            }
63 63
        }
64 64
        return parameters;

@@ -69,8 +69,8 @@
Loading
69 69
70 70
    @Override
71 71
    public List<Parameter> getParameters() {
72 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
73 -
        parameters.add(new GenericParameter<String>("format", this.format, true));
72 +
        ArrayList<Parameter> parameters = new ArrayList<>();
73 +
        parameters.add(new GenericParameter<>("format", this.format, true));
74 74
        return parameters;
75 75
    }
76 76

@@ -54,9 +54,9 @@
Loading
54 54
55 55
    @Override
56 56
    public List<Parameter> getParameters() {
57 -
        List<Parameter> parameters = new ArrayList<Parameter>();
57 +
        List<Parameter> parameters = new ArrayList<>();
58 58
        if ((option != null) && (value != null)) {
59 -
            parameters.add(new GenericParameter<String>(option.getName(), value.toString()));
59 +
            parameters.add(new GenericParameter<>(option.getName(), value.toString()));
60 60
        }
61 61
        return parameters;
62 62
    }

@@ -45,7 +45,7 @@
Loading
45 45
46 46
    @Override
47 47
    public List<Parameter> getParameters() {
48 -
        return new ArrayList<Parameter>();
48 +
        return new ArrayList<>();
49 49
    }
50 50
51 51
}

@@ -53,15 +53,15 @@
Loading
53 53
54 54
    @Override
55 55
    public List<Parameter> getParameters() {
56 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
56 +
        ArrayList<Parameter> parameters = new ArrayList<>();
57 57
58 -
        parameters.add(new GenericParameter<Double>("deltap", this.trackInitialCondition.getDeltaP()));
59 -
        parameters.add(new GenericParameter<Boolean>("onepass", this.trackInitialCondition.isOnePass()));
60 -
        parameters.add(new GenericParameter<Boolean>("recloss", this.trackInitialCondition.isCreateLossParticleFile()));
61 -
        parameters.add(new GenericParameter<Boolean>("onetable", this.trackInitialCondition.isOneTable()));
62 -
        parameters.add(new GenericParameter<Boolean>("quantum", this.trackInitialCondition.isQuantumExcited()));
63 -
        parameters.add(new GenericParameter<Boolean>("damp", this.trackInitialCondition.isSynchrotronDamped()));
64 -
        parameters.add(new GenericParameter<Boolean>("dump", this.trackInitialCondition.isWriteAtEachTurn()));
58 +
        parameters.add(new GenericParameter<>("deltap", this.trackInitialCondition.getDeltaP()));
59 +
        parameters.add(new GenericParameter<>("onepass", this.trackInitialCondition.isOnePass()));
60 +
        parameters.add(new GenericParameter<>("recloss", this.trackInitialCondition.isCreateLossParticleFile()));
61 +
        parameters.add(new GenericParameter<>("onetable", this.trackInitialCondition.isOneTable()));
62 +
        parameters.add(new GenericParameter<>("quantum", this.trackInitialCondition.isQuantumExcited()));
63 +
        parameters.add(new GenericParameter<>("damp", this.trackInitialCondition.isSynchrotronDamped()));
64 +
        parameters.add(new GenericParameter<>("dump", this.trackInitialCondition.isWriteAtEachTurn()));
65 65
66 66
        return parameters;
67 67
    }

@@ -25,13 +25,12 @@
Loading
25 25
import java.util.ArrayList;
26 26
import java.util.List;
27 27
28 -
import org.slf4j.Logger;
29 -
import org.slf4j.LoggerFactory;
30 -
31 28
import cern.accsoft.steering.jmad.domain.result.track.DynapResultRequest;
32 29
import cern.accsoft.steering.jmad.kernel.cmd.AbstractCommand;
33 30
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
34 31
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
32 +
import org.slf4j.Logger;
33 +
import org.slf4j.LoggerFactory;
35 34
36 35
/**
37 36
 * Command DYNAP,TURNS=real, FASTUNE=logical,LYAPUNOV=real,MAXAPER:={..,..,..,..,..,..},ORBIT=logical;
@@ -58,12 +57,12 @@
Loading
58 57
59 58
    @Override
60 59
    public List<Parameter> getParameters() {
61 -
        List<Parameter> parameters = new ArrayList<Parameter>();
60 +
        List<Parameter> parameters = new ArrayList<>();
62 61
63 -
        parameters.add(new GenericParameter<Integer>("turns", this.getDynapResultRequest().getTurns()));
64 -
        parameters.add(new GenericParameter<Double>("lyapunov", this.getDynapResultRequest().getLyapunov()));
65 -
        parameters.add(new GenericParameter<Boolean>("fastune", this.getDynapResultRequest().isFastTune()));
66 -
        parameters.add(new GenericParameter<Boolean>("orbit", this.getDynapResultRequest().isOrbit()));
62 +
        parameters.add(new GenericParameter<>("turns", this.getDynapResultRequest().getTurns()));
63 +
        parameters.add(new GenericParameter<>("lyapunov", this.getDynapResultRequest().getLyapunov()));
64 +
        parameters.add(new GenericParameter<>("fastune", this.getDynapResultRequest().isFastTune()));
65 +
        parameters.add(new GenericParameter<>("orbit", this.getDynapResultRequest().isOrbit()));
67 66
        if (this.getDynapResultRequest().isApertureLimited()) {
68 67
            LOGGER.warn("Aperture limitation is not avilable yet, no aperture limitation set");
69 68
        }

@@ -53,8 +53,8 @@
Loading
53 53
        /*
54 54
         * XXX check if really necessary, that this implements a command
55 55
         */
56 -
        List<Parameter> retVal = new ArrayList<Parameter>();
57 -
        retVal.add(new GenericParameter<Double>(this.valueName, this.value));
56 +
        List<Parameter> retVal = new ArrayList<>();
57 +
        retVal.add(new GenericParameter<>(this.valueName, this.value));
58 58
        return retVal;
59 59
    }
60 60
}

@@ -68,7 +68,7 @@
Loading
68 68
69 69
    @Override
70 70
    public List<Parameter> getParameters() {
71 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
71 +
        ArrayList<Parameter> parameters = new ArrayList<>();
72 72
73 73
        /*
74 74
         * define the mapping of the member-vars to the parameter names
@@ -78,22 +78,20 @@
Loading
78 78
         * EALIGN, DX=real,DY=real,DS=real, DPHI=real,DTHETA=real,DPSI=real, MREX=real,MREY=real,
79 79
         * MSCALX=real,MSCALY=real, AREX=real,AREY=real;
80 80
         */
81 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DX.getName(), misalignment.getDeltaX()));
82 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DY.getName(), misalignment.getDeltaY()));
83 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DS.getName(), misalignment.getDeltaS()));
84 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DPHI.getName(), misalignment.getDeltaPhi()));
85 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DTHETA.getName(), misalignment.getDeltaTheta()));
86 -
        parameters.add(new GenericParameter<Double>(EalignVariables.DPSI.getName(), misalignment.getDeltaPsi()));
81 +
        parameters.add(new GenericParameter<>(EalignVariables.DX.getName(), misalignment.getDeltaX()));
82 +
        parameters.add(new GenericParameter<>(EalignVariables.DY.getName(), misalignment.getDeltaY()));
83 +
        parameters.add(new GenericParameter<>(EalignVariables.DS.getName(), misalignment.getDeltaS()));
84 +
        parameters.add(new GenericParameter<>(EalignVariables.DPHI.getName(), misalignment.getDeltaPhi()));
85 +
        parameters.add(new GenericParameter<>(EalignVariables.DTHETA.getName(), misalignment.getDeltaTheta()));
86 +
        parameters.add(new GenericParameter<>(EalignVariables.DPSI.getName(), misalignment.getDeltaPsi()));
87 87
        parameters
88 -
                .add(new GenericParameter<Double>(EalignVariables.MREX.getName(), misalignment.getMonitorReadErrorX()));
88 +
                .add(new GenericParameter<>(EalignVariables.MREX.getName(), misalignment.getMonitorReadErrorX()));
89 89
        parameters
90 -
                .add(new GenericParameter<Double>(EalignVariables.MREY.getName(), misalignment.getMonitorReadErrorY()));
91 -
        parameters.add(new GenericParameter<Double>(EalignVariables.MSCALX.getName(), misalignment
92 -
                .getMonitorScalingErrorX()));
93 -
        parameters.add(new GenericParameter<Double>(EalignVariables.MSCALY.getName(), misalignment
94 -
                .getMonitorScalingErrorY()));
95 -
        parameters.add(new GenericParameter<Double>(EalignVariables.AREX.getName(), misalignment.getApertureErrorX()));
96 -
        parameters.add(new GenericParameter<Double>(EalignVariables.AREY.getName(), misalignment.getApertureErrorY()));
90 +
                .add(new GenericParameter<>(EalignVariables.MREY.getName(), misalignment.getMonitorReadErrorY()));
91 +
        parameters.add(new GenericParameter<>(EalignVariables.MSCALX.getName(), misalignment.getMonitorScalingErrorX()));
92 +
        parameters.add(new GenericParameter<>(EalignVariables.MSCALY.getName(), misalignment.getMonitorScalingErrorY()));
93 +
        parameters.add(new GenericParameter<>(EalignVariables.AREX.getName(), misalignment.getApertureErrorX()));
94 +
        parameters.add(new GenericParameter<>(EalignVariables.AREY.getName(), misalignment.getApertureErrorY()));
97 95
98 96
        return parameters;
99 97
    }

@@ -49,8 +49,8 @@
Loading
49 49
50 50
    @Override
51 51
    public List<Parameter> getParameters() {
52 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
53 -
        parameters.add(new GenericParameter<String>("text", this.printText, true));
52 +
        ArrayList<Parameter> parameters = new ArrayList<>();
53 +
        parameters.add(new GenericParameter<>("text", this.printText, true));
54 54
55 55
        return parameters;
56 56
    }

@@ -26,8 +26,6 @@
Loading
26 26
import java.util.List;
27 27
28 28
import cern.accsoft.steering.jmad.domain.beam.Beam;
29 -
import cern.accsoft.steering.jmad.domain.beam.Beam.Direction;
30 -
import cern.accsoft.steering.jmad.domain.beam.Beam.Particle;
31 29
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
32 30
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
33 31
@@ -54,7 +52,7 @@
Loading
54 52
55 53
    @Override
56 54
    public List<Parameter> getParameters() {
57 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
55 +
        ArrayList<Parameter> parameters = new ArrayList<>();
58 56
59 57
        /*
60 58
         * define the mapping of the member-fields to the parameters.
@@ -63,28 +61,28 @@
Loading
63 61
         * for particle, there may be set throug enum or through a arbitrary string. DANGER: not checked, if boths are
64 62
         * set!
65 63
         */
66 -
        parameters.add(new GenericParameter<Particle>("particle", beam.getParticle()));
67 -
        parameters.add(new GenericParameter<String>("particle", beam.getParticleName()));
64 +
        parameters.add(new GenericParameter<>("particle", beam.getParticle()));
65 +
        parameters.add(new GenericParameter<>("particle", beam.getParticleName()));
68 66
69 -
        parameters.add(new GenericParameter<Double>("mass", beam.getMass()));
70 -
        parameters.add(new GenericParameter<Double>("charge", beam.getCharge()));
71 -
        parameters.add(new GenericParameter<Double>("energy", beam.getEnergy()));
72 -
        parameters.add(new GenericParameter<Double>("pc", beam.getMomentum()));
73 -
        parameters.add(new GenericParameter<Double>("gamma", beam.getGamma()));
74 -
        parameters.add(new GenericParameter<Double>("ex", beam.getHorizontalEmittance()));
75 -
        parameters.add(new GenericParameter<Double>("ey", beam.getVerticalEmittance()));
76 -
        parameters.add(new GenericParameter<Double>("et", beam.getLongitudinalEmittance()));
77 -
        parameters.add(new GenericParameter<Double>("exn", beam.getNormalisedHorizontalEmittance()));
78 -
        parameters.add(new GenericParameter<Double>("eyn", beam.getNormalisedVerticalEmittance()));
79 -
        parameters.add(new GenericParameter<Double>("sigt", beam.getBunchLength()));
80 -
        parameters.add(new GenericParameter<Double>("sige", beam.getRelativeEnergySpread()));
81 -
        parameters.add(new GenericParameter<Integer>("kbunch", beam.getBunchNumber()));
82 -
        parameters.add(new GenericParameter<Double>("npart", beam.getParticleNumber()));
83 -
        parameters.add(new GenericParameter<Double>("bcurrent", beam.getBunchCurrent()));
84 -
        parameters.add(new GenericParameter<Boolean>("bunched", beam.getBunched()));
85 -
        parameters.add(new GenericParameter<Boolean>("radiate", beam.getRadiate()));
86 -
        parameters.add(new GenericParameter<Direction>("bv", beam.getDirection()));
87 -
        parameters.add(new GenericParameter<String>("sequence", beam.getSequence()));
67 +
        parameters.add(new GenericParameter<>("mass", beam.getMass()));
68 +
        parameters.add(new GenericParameter<>("charge", beam.getCharge()));
69 +
        parameters.add(new GenericParameter<>("energy", beam.getEnergy()));
70 +
        parameters.add(new GenericParameter<>("pc", beam.getMomentum()));
71 +
        parameters.add(new GenericParameter<>("gamma", beam.getGamma()));
72 +
        parameters.add(new GenericParameter<>("ex", beam.getHorizontalEmittance()));
73 +
        parameters.add(new GenericParameter<>("ey", beam.getVerticalEmittance()));
74 +
        parameters.add(new GenericParameter<>("et", beam.getLongitudinalEmittance()));
75 +
        parameters.add(new GenericParameter<>("exn", beam.getNormalisedHorizontalEmittance()));
76 +
        parameters.add(new GenericParameter<>("eyn", beam.getNormalisedVerticalEmittance()));
77 +
        parameters.add(new GenericParameter<>("sigt", beam.getBunchLength()));
78 +
        parameters.add(new GenericParameter<>("sige", beam.getRelativeEnergySpread()));
79 +
        parameters.add(new GenericParameter<>("kbunch", beam.getBunchNumber()));
80 +
        parameters.add(new GenericParameter<>("npart", beam.getParticleNumber()));
81 +
        parameters.add(new GenericParameter<>("bcurrent", beam.getBunchCurrent()));
82 +
        parameters.add(new GenericParameter<>("bunched", beam.getBunched()));
83 +
        parameters.add(new GenericParameter<>("radiate", beam.getRadiate()));
84 +
        parameters.add(new GenericParameter<>("bv", beam.getDirection()));
85 +
        parameters.add(new GenericParameter<>("sequence", beam.getSequence()));
88 86
89 87
        return parameters;
90 88
    }

@@ -25,13 +25,12 @@
Loading
25 25
import java.util.ArrayList;
26 26
import java.util.List;
27 27
28 -
import org.slf4j.Logger;
29 -
import org.slf4j.LoggerFactory;
30 -
31 28
import cern.accsoft.steering.jmad.domain.result.track.TrackResultRequest;
32 29
import cern.accsoft.steering.jmad.kernel.cmd.AbstractCommand;
33 30
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
34 31
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
32 +
import org.slf4j.Logger;
33 +
import org.slf4j.LoggerFactory;
35 34
36 35
/**
37 36
 * command RUN, maxaper= double array, turns= integer, ffile= integer;
@@ -58,15 +57,15 @@
Loading
58 57
59 58
    @Override
60 59
    public List<Parameter> getParameters() {
61 -
        List<Parameter> parameters = new ArrayList<Parameter>();
60 +
        List<Parameter> parameters = new ArrayList<>();
62 61
63 62
        if (this.trackRequestResult.isApertureLimited()) {
64 63
            LOGGER.warn("maxaper not available yet, no aperture defined");
65 64
            // parameters.add(new
66 65
            // GenericParameter<Double[]>("maxaper",this.trackRequestResult.getApertureLimitation()));
67 66
        }
68 -
        parameters.add(new GenericParameter<Integer>("turns", this.trackRequestResult.getTurns()));
69 -
        parameters.add(new GenericParameter<Integer>("ffile", this.trackRequestResult.getPrintFrequency()));
67 +
        parameters.add(new GenericParameter<>("turns", this.trackRequestResult.getTurns()));
68 +
        parameters.add(new GenericParameter<>("ffile", this.trackRequestResult.getPrintFrequency()));
70 69
71 70
        return parameters;
72 71
    }

@@ -57,11 +57,11 @@
Loading
57 57
58 58
    @Override
59 59
    public List<Parameter> getParameters() {
60 -
        List<Parameter> parameters = new ArrayList<Parameter>();
61 -
        parameters.add(new GenericParameter<Integer>("sector_nmul_max", sectorNMulMax));
62 -
        parameters.add(new GenericParameter<Integer>("sector_nmul", sectorNMul));
63 -
        parameters.add(new GenericParameter<Boolean>("ntpsa", ntpsa));
64 -
        parameters.add(new GenericParameter<Boolean>("symprint", symPrint));
60 +
        List<Parameter> parameters = new ArrayList<>();
61 +
        parameters.add(new GenericParameter<>("sector_nmul_max", sectorNMulMax));
62 +
        parameters.add(new GenericParameter<>("sector_nmul", sectorNMul));
63 +
        parameters.add(new GenericParameter<>("ntpsa", ntpsa));
64 +
        parameters.add(new GenericParameter<>("symprint", symPrint));
65 65
        return parameters;
66 66
    }
67 67

@@ -57,11 +57,11 @@
Loading
57 57
58 58
    @Override
59 59
    public List<Parameter> getParameters() {
60 -
        List<Parameter> parameters = new ArrayList<Parameter>();
60 +
        List<Parameter> parameters = new ArrayList<>();
61 61
62 -
        parameters.add(new GenericParameter<String>("table", this.tableName, true));
62 +
        parameters.add(new GenericParameter<>("table", this.tableName, true));
63 63
        if (file != null) {
64 -
            parameters.add(new GenericParameter<String>("file", this.file, true));
64 +
            parameters.add(new GenericParameter<>("file", this.file, true));
65 65
        }
66 66
        return parameters;
67 67
    }

@@ -25,13 +25,13 @@
Loading
25 25
 */
26 26
package cern.accsoft.steering.jmad.kernel.cmd.ptc;
27 27
28 +
import java.util.ArrayList;
29 +
import java.util.List;
30 +
28 31
import cern.accsoft.steering.jmad.kernel.cmd.AbstractCommand;
29 32
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
30 33
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
31 34
32 -
import java.util.ArrayList;
33 -
import java.util.List;
34 -
35 35
/**
36 36
 * This class represents the madx-command to initialize the ptc-universe
37 37
 * 
@@ -59,18 +59,18 @@
Loading
59 59
60 60
    @Override
61 61
    public List<Parameter> getParameters() {
62 -
        List<Parameter> parameters = new ArrayList<Parameter>();
62 +
        List<Parameter> parameters = new ArrayList<>();
63 63
        if (time != null) {
64 -
            parameters.add(new GenericParameter<String>("time", time.toString()));
64 +
            parameters.add(new GenericParameter<>("time", time.toString()));
65 65
        }
66 -
        parameters.add(new GenericParameter<Boolean>("fringe", fringe));
67 -
        parameters.add(new GenericParameter<Boolean>("nocavity", nocavity));
68 -
        parameters.add(new GenericParameter<Boolean>("exactmis", exactmis));
69 -
        parameters.add(new GenericParameter<Boolean>("totalpath", totalpath));
70 -
        parameters.add(new GenericParameter<Boolean>("radiation", radiation));
71 -
        parameters.add(new GenericParameter<Boolean>("envelope", envelope));
72 -
        parameters.add(new GenericParameter<Boolean>("stochastic", stochastic));
73 -
        parameters.add(new GenericParameter<Boolean>("modulation", modulation));
66 +
        parameters.add(new GenericParameter<>("fringe", fringe));
67 +
        parameters.add(new GenericParameter<>("nocavity", nocavity));
68 +
        parameters.add(new GenericParameter<>("exactmis", exactmis));
69 +
        parameters.add(new GenericParameter<>("totalpath", totalpath));
70 +
        parameters.add(new GenericParameter<>("radiation", radiation));
71 +
        parameters.add(new GenericParameter<>("envelope", envelope));
72 +
        parameters.add(new GenericParameter<>("stochastic", stochastic));
73 +
        parameters.add(new GenericParameter<>("modulation", modulation));
74 74
75 75
        return parameters;
76 76
    }

@@ -49,7 +49,7 @@
Loading
49 49
    @Override
50 50
    public List<Parameter> getParameters() {
51 51
        /* this command has no parameters! */
52 -
        return new ArrayList<Parameter>();
52 +
        return new ArrayList<>();
53 53
    }
54 54
55 55
}

@@ -22,12 +22,12 @@
Loading
22 22
23 23
package cern.accsoft.steering.jmad.kernel.cmd;
24 24
25 -
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
26 -
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
27 -
28 25
import java.util.ArrayList;
29 26
import java.util.List;
30 27
28 +
import cern.accsoft.steering.jmad.kernel.cmd.param.GenericParameter;
29 +
import cern.accsoft.steering.jmad.kernel.cmd.param.Parameter;
30 +
31 31
public class SelectCommand extends AbstractCommand {
32 32
33 33
    /** the flag to use for the select command to select the twiss output */
@@ -52,15 +52,15 @@
Loading
52 52
53 53
    @Override
54 54
    public List<Parameter> getParameters() {
55 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
56 -
57 -
        parameters.add(new GenericParameter<String>("flag", flag));
58 -
        parameters.add(new GenericParameter<String>("range", range));
59 -
        parameters.add(new GenericParameter<String>("class", elementClass));
60 -
        parameters.add(new GenericParameter<String>("pattern", pattern, true));
61 -
        parameters.add(new GenericParameter<String>("column", column));
62 -
        parameters.add(new GenericParameter<Boolean>("full", full));
63 -
        parameters.add(new GenericParameter<Boolean>("clear", clear));
55 +
        ArrayList<Parameter> parameters = new ArrayList<>();
56 +
57 +
        parameters.add(new GenericParameter<>("flag", flag));
58 +
        parameters.add(new GenericParameter<>("range", range));
59 +
        parameters.add(new GenericParameter<>("class", elementClass));
60 +
        parameters.add(new GenericParameter<>("pattern", pattern, true));
61 +
        parameters.add(new GenericParameter<>("column", column));
62 +
        parameters.add(new GenericParameter<>("full", full));
63 +
        parameters.add(new GenericParameter<>("clear", clear));
64 64
65 65
        return parameters;
66 66
    }

@@ -50,9 +50,9 @@
Loading
50 50
51 51
    @Override
52 52
    public List<Parameter> getParameters() {
53 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
53 +
        ArrayList<Parameter> parameters = new ArrayList<>();
54 54
        for (String valueName : valueNames) {
55 -
            parameters.add(new GenericParameter<Boolean>(valueName, true));
55 +
            parameters.add(new GenericParameter<>(valueName, true));
56 56
        }
57 57
        return parameters;
58 58
    }

@@ -34,8 +34,8 @@
Loading
34 34
35 35
    @Override
36 36
    public List<Parameter> getParameters() {
37 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
38 -
        parameters.add(new GenericParameter<String>("file", outputFile.getAbsolutePath()));
37 +
        ArrayList<Parameter> parameters = new ArrayList<>();
38 +
        parameters.add(new GenericParameter<>("file", outputFile.getAbsolutePath()));
39 39
        return parameters;
40 40
    }
41 41

@@ -62,42 +62,42 @@
Loading
62 62
    /* TODO implement all options! */
63 63
    @Override
64 64
    public List<Parameter> getParameters() {
65 -
        List<Parameter> parameters = new ArrayList<Parameter>();
65 +
        List<Parameter> parameters = new ArrayList<>();
66 66
67 -
        parameters.add(new GenericParameter<Double>("deltap", twiss.getDeltap()));
67 +
        parameters.add(new GenericParameter<>("deltap", twiss.getDeltap()));
68 68
69 69
        /*
70 70
         * the initial conditions must not be set, if we want to calc the closed orbit solution
71 71
         */
72 72
        if (!twiss.isClosedOrbit()) {
73 -
            parameters.add(new GenericParameter<Double>("betx", twiss.getBetx()));
74 -
            parameters.add(new GenericParameter<Double>("alfx", twiss.getAlfx()));
75 -
            parameters.add(new GenericParameter<Double>("bety", twiss.getBety()));
76 -
            parameters.add(new GenericParameter<Double>("alfy", twiss.getAlfy()));
77 -
            parameters.add(new GenericParameter<Double>("dx", twiss.getDx()));
78 -
            parameters.add(new GenericParameter<Double>("dy", twiss.getDy()));
79 -
            parameters.add(new GenericParameter<Double>("dpx", twiss.getDpx()));
80 -
            parameters.add(new GenericParameter<Double>("dpy", twiss.getDpy()));
81 -
            parameters.add(new GenericParameter<Double>("x", twiss.getX()));
82 -
            parameters.add(new GenericParameter<Double>("px", twiss.getPx()));
83 -
            parameters.add(new GenericParameter<Double>("y", twiss.getY()));
84 -
            parameters.add(new GenericParameter<Double>("py", twiss.getPy()));
85 -
            parameters.add(new GenericParameter<Double>("t", twiss.getT()));
86 -
            parameters.add(new GenericParameter<Double>("pt", twiss.getPt()));
87 -
            parameters.add(new GenericParameter<Double>("mux", twiss.getMux()));
88 -
            parameters.add(new GenericParameter<Double>("muy", twiss.getMuy()));
73 +
            parameters.add(new GenericParameter<>("betx", twiss.getBetx()));
74 +
            parameters.add(new GenericParameter<>("alfx", twiss.getAlfx()));
75 +
            parameters.add(new GenericParameter<>("bety", twiss.getBety()));
76 +
            parameters.add(new GenericParameter<>("alfy", twiss.getAlfy()));
77 +
            parameters.add(new GenericParameter<>("dx", twiss.getDx()));
78 +
            parameters.add(new GenericParameter<>("dy", twiss.getDy()));
79 +
            parameters.add(new GenericParameter<>("dpx", twiss.getDpx()));
80 +
            parameters.add(new GenericParameter<>("dpy", twiss.getDpy()));
81 +
            parameters.add(new GenericParameter<>("x", twiss.getX()));
82 +
            parameters.add(new GenericParameter<>("px", twiss.getPx()));
83 +
            parameters.add(new GenericParameter<>("y", twiss.getY()));
84 +
            parameters.add(new GenericParameter<>("py", twiss.getPy()));
85 +
            parameters.add(new GenericParameter<>("t", twiss.getT()));
86 +
            parameters.add(new GenericParameter<>("pt", twiss.getPt()));
87 +
            parameters.add(new GenericParameter<>("mux", twiss.getMux()));
88 +
            parameters.add(new GenericParameter<>("muy", twiss.getMuy()));
89 89
        }
90 -
        parameters.add(new GenericParameter<Boolean>("closed_orbit", twiss.isClosedOrbit()));
91 -
        parameters.add(new GenericParameter<Integer>("icase", twiss.getPtcPhaseSpaceDimension()));
92 -
        parameters.add(new GenericParameter<Integer>("no", twiss.getPtcMapOrder()));
93 -
        parameters.add(new GenericParameter<Double>("betz", twiss.getPtcBetz()));
90 +
        parameters.add(new GenericParameter<>("closed_orbit", twiss.isClosedOrbit()));
91 +
        parameters.add(new GenericParameter<>("icase", twiss.getPtcPhaseSpaceDimension()));
92 +
        parameters.add(new GenericParameter<>("no", twiss.getPtcMapOrder()));
93 +
        parameters.add(new GenericParameter<>("betz", twiss.getPtcBetz()));
94 94
        if (twiss.isCalcAtCenter()) {
95 95
            LOGGER.warn("Calculating at the center is not supported by PTC_TWISS. Ignoring option. " +
96 96
                    "Calculating at the end of the elements.");
97 97
        }
98 98
99 99
        if (getOutputFile() != null) {
100 -
            parameters.add(new GenericParameter<String>("file", getOutputFile().getAbsolutePath(), true));
100 +
            parameters.add(new GenericParameter<>("file", getOutputFile().getAbsolutePath(), true));
101 101
        }
102 102
103 103
        return parameters;

@@ -72,7 +72,7 @@
Loading
72 72
73 73
    @Override
74 74
    public List<Parameter> getParameters() {
75 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
75 +
        ArrayList<Parameter> parameters = new ArrayList<>();
76 76
77 77
        /*
78 78
         * define the mapping of the member-vars to the parameter names
@@ -89,16 +89,16 @@
Loading
89 89
        parameters.add(new FunctionParameter("dy", "tgauss", misalignment.getDeltaY(), gaussDistribuition));
90 90
91 91
        // TODO add randomness into the rest of the parameters
92 -
        parameters.add(new GenericParameter<Double>("ds", misalignment.getDeltaS()));
93 -
        parameters.add(new GenericParameter<Double>("dphi", misalignment.getDeltaPhi()));
94 -
        parameters.add(new GenericParameter<Double>("dtheta", misalignment.getDeltaTheta()));
95 -
        parameters.add(new GenericParameter<Double>("dpsi", misalignment.getDeltaPsi()));
96 -
        parameters.add(new GenericParameter<Double>("mrex", misalignment.getMonitorReadErrorX()));
97 -
        parameters.add(new GenericParameter<Double>("mrey", misalignment.getMonitorReadErrorY()));
98 -
        parameters.add(new GenericParameter<Double>("mscalx", misalignment.getMonitorScalingErrorX()));
99 -
        parameters.add(new GenericParameter<Double>("mscaly", misalignment.getMonitorScalingErrorY()));
100 -
        parameters.add(new GenericParameter<Double>("arex", misalignment.getApertureErrorX()));
101 -
        parameters.add(new GenericParameter<Double>("arey", misalignment.getApertureErrorY()));
92 +
        parameters.add(new GenericParameter<>("ds", misalignment.getDeltaS()));
93 +
        parameters.add(new GenericParameter<>("dphi", misalignment.getDeltaPhi()));
94 +
        parameters.add(new GenericParameter<>("dtheta", misalignment.getDeltaTheta()));
95 +
        parameters.add(new GenericParameter<>("dpsi", misalignment.getDeltaPsi()));
96 +
        parameters.add(new GenericParameter<>("mrex", misalignment.getMonitorReadErrorX()));
97 +
        parameters.add(new GenericParameter<>("mrey", misalignment.getMonitorReadErrorY()));
98 +
        parameters.add(new GenericParameter<>("mscalx", misalignment.getMonitorScalingErrorX()));
99 +
        parameters.add(new GenericParameter<>("mscaly", misalignment.getMonitorScalingErrorY()));
100 +
        parameters.add(new GenericParameter<>("arex", misalignment.getApertureErrorX()));
101 +
        parameters.add(new GenericParameter<>("arey", misalignment.getApertureErrorY()));
102 102
103 103
        return parameters;
104 104
    }

@@ -61,10 +61,10 @@
Loading
61 61
62 62
    @Override
63 63
    public List<Parameter> getParameters() {
64 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
64 +
        ArrayList<Parameter> parameters = new ArrayList<>();
65 65
66 -
        parameters.add(new GenericParameter<String>(PARAM_NAME_PERIOD, period));
67 -
        parameters.add(new GenericParameter<String>(PARAM_NAME_RANGE, range));
66 +
        parameters.add(new GenericParameter<>(PARAM_NAME_PERIOD, period));
67 +
        parameters.add(new GenericParameter<>(PARAM_NAME_RANGE, range));
68 68
69 69
        return parameters;
70 70
    }

@@ -59,8 +59,8 @@
Loading
59 59
60 60
    @Override
61 61
    public List<Parameter> getParameters() {
62 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
63 -
        parameters.add(new GenericParameter<String>("sequence", sequence));
62 +
        ArrayList<Parameter> parameters = new ArrayList<>();
63 +
        parameters.add(new GenericParameter<>("sequence", sequence));
64 64
        return parameters;
65 65
    }
66 66

@@ -52,6 +52,6 @@
Loading
52 52
53 53
    @Override
54 54
    public List<Parameter> getParameters() {
55 -
        return new ArrayList<Parameter>(0);
55 +
        return new ArrayList<>(0);
56 56
    }
57 57
}

@@ -48,10 +48,10 @@
Loading
48 48
49 49
    @Override
50 50
    public List<Parameter> getParameters() {
51 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
52 -
        parameters.add(new GenericParameter<String>("label", this.label, true));
53 -
        parameters.add(new GenericParameter<String>("place", this.location));
54 -
        parameters.add(new GenericParameter<String>("sequence", this.sequName));
51 +
        ArrayList<Parameter> parameters = new ArrayList<>();
52 +
        parameters.add(new GenericParameter<>("label", this.label, true));
53 +
        parameters.add(new GenericParameter<>("place", this.location));
54 +
        parameters.add(new GenericParameter<>("sequence", this.sequName));
55 55
        return parameters;
56 56
    }
57 57
}

@@ -53,24 +53,24 @@
Loading
53 53
54 54
    @Override
55 55
    public List<Parameter> getParameters() {
56 -
        List<Parameter> parameters = new ArrayList<Parameter>();
56 +
        List<Parameter> parameters = new ArrayList<>();
57 57
        if(this.relatvieParticleCoordinate.isActionAngle())
58 58
        {
59 -
            parameters.add(new GenericParameter<Double>("fx", this.relatvieParticleCoordinate.getXRelatviePosition()));
60 -
            parameters.add(new GenericParameter<Double>("phix", this.relatvieParticleCoordinate.getXRelativeMomentum()));
61 -
            parameters.add(new GenericParameter<Double>("fy", this.relatvieParticleCoordinate.getYRelativePosition()));
62 -
            parameters.add(new GenericParameter<Double>("phiy", this.relatvieParticleCoordinate.getYRelatvieMomentum()));
63 -
            parameters.add(new GenericParameter<Double>("ft", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
64 -
            parameters.add(new GenericParameter<Double>("phit", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
59 +
            parameters.add(new GenericParameter<>("fx", this.relatvieParticleCoordinate.getXRelatviePosition()));
60 +
            parameters.add(new GenericParameter<>("phix", this.relatvieParticleCoordinate.getXRelativeMomentum()));
61 +
            parameters.add(new GenericParameter<>("fy", this.relatvieParticleCoordinate.getYRelativePosition()));
62 +
            parameters.add(new GenericParameter<>("phiy", this.relatvieParticleCoordinate.getYRelatvieMomentum()));
63 +
            parameters.add(new GenericParameter<>("ft", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
64 +
            parameters.add(new GenericParameter<>("phit", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
65 65
        }
66 66
        else
67 67
        {
68 -
            parameters.add(new GenericParameter<Double>("x", this.relatvieParticleCoordinate.getXRelatviePosition()));
69 -
            parameters.add(new GenericParameter<Double>("px", this.relatvieParticleCoordinate.getXRelativeMomentum()));
70 -
            parameters.add(new GenericParameter<Double>("y", this.relatvieParticleCoordinate.getYRelativePosition()));
71 -
            parameters.add(new GenericParameter<Double>("py", this.relatvieParticleCoordinate.getYRelatvieMomentum()));
72 -
            parameters.add(new GenericParameter<Double>("t", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
73 -
            parameters.add(new GenericParameter<Double>("pt", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
68 +
            parameters.add(new GenericParameter<>("x", this.relatvieParticleCoordinate.getXRelatviePosition()));
69 +
            parameters.add(new GenericParameter<>("px", this.relatvieParticleCoordinate.getXRelativeMomentum()));
70 +
            parameters.add(new GenericParameter<>("y", this.relatvieParticleCoordinate.getYRelativePosition()));
71 +
            parameters.add(new GenericParameter<>("py", this.relatvieParticleCoordinate.getYRelatvieMomentum()));
72 +
            parameters.add(new GenericParameter<>("t", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
73 +
            parameters.add(new GenericParameter<>("pt", this.relatvieParticleCoordinate.getRelativeTimeDifference()));
74 74
        }
75 75
76 76
        return parameters;

@@ -77,16 +77,16 @@
Loading
77 77
78 78
    @Override
79 79
    public List<Parameter> getParameters() {
80 -
        ArrayList<Parameter> parameters = new ArrayList<Parameter>();
80 +
        ArrayList<Parameter> parameters = new ArrayList<>();
81 81
82 -
        parameters.add(new GenericParameter<Double>("seed", seed));
82 +
        parameters.add(new GenericParameter<>("seed", seed));
83 83
84 84
        /*
85 85
         * this is kind of special boolean parameter: it does not follow the convention, that it is omitted, when it is
86 86
         * meant to be false! It has to be set explicitly to false. We therefore use a string-parameter.
87 87
         */
88 88
        if (add != null) {
89 -
            parameters.add(new GenericParameter<String>("add", add.toString()));
89 +
            parameters.add(new GenericParameter<>("add", add.toString()));
90 90
        }
91 91
        return parameters;
92 92
    }

@@ -52,8 +52,8 @@
Loading
52 52
53 53
    @Override
54 54
    public List<Parameter> getParameters() {
55 -
        List<Parameter> parameters = new ArrayList<Parameter>();
56 -
        parameters.add(new GenericParameter<String>("place", this.place));
55 +
        List<Parameter> parameters = new ArrayList<>();
56 +
        parameters.add(new GenericParameter<>("place", this.place));
57 57
        return parameters;
58 58
    }
59 59

@@ -85,30 +85,30 @@
Loading
85 85
86 86
    @Override
87 87
    public List<Parameter> getParameters() {
88 -
        List<Parameter> parameters = new ArrayList<Parameter>();
88 +
        List<Parameter> parameters = new ArrayList<>();
89 89
90 90
        /*
91 91
         * this is kind of special boolean parameter: it does not follow the convention, that it is omitted, when it is
92 92
         * meant to be false! It has to be set explicitly to false. We therefore use a string-parameter.
93 93
         */
94 94
        if (time != null) {
95 -
            parameters.add(new GenericParameter<String>("time", time.toString()));
95 +
            parameters.add(new GenericParameter<>("time", time.toString()));
96 96
        }
97 97
98 -
        parameters.add(new GenericParameter<Integer>("model", model));
99 -
        parameters.add(new GenericParameter<Integer>("method", method));
100 -
        parameters.add(new GenericParameter<Integer>("nst", nst));
101 -
        parameters.add(new GenericParameter<Boolean>("exact", exact));
102 -
        parameters.add(new GenericParameter<Double>("offset_deltap", offsetDeltaP));
103 -
        parameters.add(new GenericParameter<Boolean>("errors_in", errorsIn));
104 -
        parameters.add(new GenericParameter<Boolean>("errors_out", errorsOut));
105 -
        parameters.add(new GenericParameter<String>("magnet_name", magnetName));
106 -
        parameters.add(new GenericParameter<Boolean>("resplit", resplit));
107 -
        parameters.add(new GenericParameter<Double>("thin", thin));
108 -
        parameters.add(new GenericParameter<Double>("xbend", xbend));
98 +
        parameters.add(new GenericParameter<>("model", model));
99 +
        parameters.add(new GenericParameter<>("method", method));
100 +
        parameters.add(new GenericParameter<>("nst", nst));
101 +
        parameters.add(new GenericParameter<>("exact", exact));
102 +
        parameters.add(new GenericParameter<>("offset_deltap", offsetDeltaP));
103 +
        parameters.add(new GenericParameter<>("errors_in", errorsIn));
104 +
        parameters.add(new GenericParameter<>("errors_out", errorsOut));
105 +
        parameters.add(new GenericParameter<>("magnet_name", magnetName));
106 +
        parameters.add(new GenericParameter<>("resplit", resplit));
107 +
        parameters.add(new GenericParameter<>("thin", thin));
108 +
        parameters.add(new GenericParameter<>("xbend", xbend));
109 109
        /* same as for "time": default is true! */
110 110
        if (even != null) {
111 -
            parameters.add(new GenericParameter<String>("even", even.toString()));
111 +
            parameters.add(new GenericParameter<>("even", even.toString()));
112 112
        }
113 113
        return parameters;
114 114
    }
Files Complexity Coverage
src/java/cern/accsoft/steering/jmad 42.33% 47.42%
Project Totals (293 files) 42.33% 47.42%
207.2
openjdk11=
TRAVIS_OS_NAME=linux
207.1
TRAVIS_OS_NAME=linux
openjdk8=

No yaml found.

Create your codecov.yml to customize your Codecov experience

Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading