Search in sources :

Example 6 with VariableType

use of com.opensimulationplatform.modeldescription.xml.model.VariableType in project osp-validator by open-simulation-platform.

the class AngularDisplacementTypeConverter method convert.

@Override
public AngularDisplacement convert(AngularDisplacementType angularDisplacementType) {
    AngularDisplacement angularDisplacement = new AngularDisplacement();
    angularDisplacement.setName(angularDisplacementType.getName());
    List<VariableType> variableTypes = angularDisplacementType.getVariable();
    List<Variable> variables = variableTypes.stream().map(context.variableTypeConverter::convert).collect(Collectors.toList());
    angularDisplacement.setVariables(variables);
    return angularDisplacement;
}
Also used : Variable(com.opensimulationplatform.core.model.modeldescription.Variable) VariableType(com.opensimulationplatform.modeldescription.xml.model.VariableType) AngularDisplacement(com.opensimulationplatform.core.model.modeldescription.variablegroup.angulardisplacement.AngularDisplacement)

Example 7 with VariableType

use of com.opensimulationplatform.modeldescription.xml.model.VariableType in project osp-validator by open-simulation-platform.

the class ChargeTypeConverter method convert.

@Override
public Charge convert(ChargeType chargeType) {
    Charge charge = new Charge();
    charge.setName(chargeType.getName());
    List<VariableType> variableTypes = chargeType.getVariable();
    List<Variable> variables = variableTypes.stream().map(context.variableTypeConverter::convert).collect(Collectors.toList());
    charge.setVariables(variables);
    return charge;
}
Also used : Variable(com.opensimulationplatform.core.model.modeldescription.Variable) VariableType(com.opensimulationplatform.modeldescription.xml.model.VariableType) Charge(com.opensimulationplatform.core.model.modeldescription.variablegroup.charge.Charge)

Example 8 with VariableType

use of com.opensimulationplatform.modeldescription.xml.model.VariableType in project osp-validator by open-simulation-platform.

the class LinearDisplacementTypeConverter method convert.

@Override
public LinearDisplacement convert(LinearDisplacementType linearDisplacementType) {
    LinearDisplacement linearDisplacement = new LinearDisplacement();
    linearDisplacement.setName(linearDisplacementType.getName());
    List<VariableType> variableTypes = linearDisplacementType.getVariable();
    List<Variable> variables = variableTypes.stream().map(context.variableTypeConverter::convert).collect(Collectors.toList());
    linearDisplacement.setVariables(variables);
    return linearDisplacement;
}
Also used : Variable(com.opensimulationplatform.core.model.modeldescription.Variable) VariableType(com.opensimulationplatform.modeldescription.xml.model.VariableType) LinearDisplacement(com.opensimulationplatform.core.model.modeldescription.variablegroup.lineardisplacement.LinearDisplacement)

Example 9 with VariableType

use of com.opensimulationplatform.modeldescription.xml.model.VariableType in project osp-validator by open-simulation-platform.

the class PressureTypeConverter method convert.

@Override
public Pressure convert(PressureType pressureType) {
    Pressure pressure = new Pressure();
    pressure.setName(pressureType.getName());
    List<VariableType> variableTypes = pressureType.getVariable();
    List<Variable> variables = variableTypes.stream().map(context.variableTypeConverter::convert).collect(Collectors.toList());
    pressure.setVariables(variables);
    return pressure;
}
Also used : Variable(com.opensimulationplatform.core.model.modeldescription.Variable) VariableType(com.opensimulationplatform.modeldescription.xml.model.VariableType) Pressure(com.opensimulationplatform.core.model.modeldescription.variablegroup.pressure.Pressure)

Example 10 with VariableType

use of com.opensimulationplatform.modeldescription.xml.model.VariableType in project osp-validator by open-simulation-platform.

the class VolumeFlowRateTypeConverter method convert.

@Override
public VolumeFlowRate convert(VolumeFlowRateType volumeFlowRateType) {
    VolumeFlowRate volumeFlowRate = new VolumeFlowRate();
    volumeFlowRate.setName(volumeFlowRateType.getName());
    List<VariableType> variableTypes = volumeFlowRateType.getVariable();
    List<Variable> variables = variableTypes.stream().map(context.variableTypeConverter::convert).collect(Collectors.toList());
    volumeFlowRate.setVariables(variables);
    return volumeFlowRate;
}
Also used : Variable(com.opensimulationplatform.core.model.modeldescription.Variable) VariableType(com.opensimulationplatform.modeldescription.xml.model.VariableType) VolumeFlowRate(com.opensimulationplatform.core.model.modeldescription.variablegroup.volumeflowrate.VolumeFlowRate)

Aggregations

Variable (com.opensimulationplatform.core.model.modeldescription.Variable)17 VariableType (com.opensimulationplatform.modeldescription.xml.model.VariableType)17 Unit (com.opensimulationplatform.core.model.modeldescription.Unit)1 AngularDisplacement (com.opensimulationplatform.core.model.modeldescription.variablegroup.angulardisplacement.AngularDisplacement)1 AngularVelocity (com.opensimulationplatform.core.model.modeldescription.variablegroup.angularvelocity.AngularVelocity)1 Charge (com.opensimulationplatform.core.model.modeldescription.variablegroup.charge.Charge)1 Current (com.opensimulationplatform.core.model.modeldescription.variablegroup.current.Current)1 Force (com.opensimulationplatform.core.model.modeldescription.variablegroup.force.Force)1 LinearDisplacement (com.opensimulationplatform.core.model.modeldescription.variablegroup.lineardisplacement.LinearDisplacement)1 LinearVelocity (com.opensimulationplatform.core.model.modeldescription.variablegroup.linearvelocity.LinearVelocity)1 NmeaGgaFix (com.opensimulationplatform.core.model.modeldescription.variablegroup.nmeaggafix.NmeaGgaFix)1 NmeaGgaLatitudeLongitude (com.opensimulationplatform.core.model.modeldescription.variablegroup.nmeaggalatitudelongitude.NmeaGgaLatitudeLongitude)1 NmeaGstEllipse (com.opensimulationplatform.core.model.modeldescription.variablegroup.nmeagstellipse.NmeaGstEllipse)1 NmeaGstPositionError (com.opensimulationplatform.core.model.modeldescription.variablegroup.nmeagstpositionerror.NmeaGstPositionError)1 Pressure (com.opensimulationplatform.core.model.modeldescription.variablegroup.pressure.Pressure)1 Torque (com.opensimulationplatform.core.model.modeldescription.variablegroup.torque.Torque)1 Voltage (com.opensimulationplatform.core.model.modeldescription.variablegroup.voltage.Voltage)1 Volume (com.opensimulationplatform.core.model.modeldescription.variablegroup.volume.Volume)1 VolumeFlowRate (com.opensimulationplatform.core.model.modeldescription.variablegroup.volumeflowrate.VolumeFlowRate)1 ConverterContext (com.opensimulationplatform.modeldescription.xml.converter.ConverterContext)1