.Modelica_Requirements.LogicalFunctions.BooleanToProperty

Convert Boolean (false,true) to Property (Violated, Satisfied)

Information

Syntax

BooleanToProperty(check);

Description

The function returns Satisfied if check=true and returns Violated, if check=false. Satisfied and Violated are elements of enumeration Property

Example

The property is demonstrated with the following example calling the function as:

property = BooleanToProperty(check)

results in

simulation result

Interface

function BooleanToProperty
  import Modelica_Requirements.Types.Property;
  extends Modelica_Requirements.Interfaces.PropertyFunction;
  input Boolean u "Boolean to be mapped to Property";
  output Modelica_Requirements.Types.Property y "Boolean as Property";
end BooleanToProperty;

Generated at 2025-03-09T19:25:01Z by OpenModelicaOpenModelica 1.24.5 using GenerateDoc.mos