Skip to content

Commit eeeee81

Browse files
committed
Rename TimeType components
1 parent 94c088f commit eeeee81

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

Modelica/Utilities/Time.mo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ package Time "Functions to work with date and time"
66
extends Modelica.Icons.Function;
77
output Types.TimeType now "Current time";
88
algorithm
9-
(now.ms, now.sec, now.min, now.hour, now.day, now.mon, now.year) := Internal.Time.getTime();
9+
(now.millisecond, now.second, now.minute, now.hour, now.day, now.month, now.year) := Internal.Time.getTime();
1010
annotation (__ModelicaAssociation_Impure=true,
1111
Documentation(info="<html>
1212
<h4>Syntax</h4>

Modelica/Utilities/Types.mo

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,12 @@ package Types "Type definitions used in package Modelica.Utilities"
3838

3939
record TimeType "Record containing date and time components"
4040
extends Modelica.Icons.Record;
41-
Integer ms(min=0, max=999) "Millisecond" annotation(absoluteValue=true);
42-
Integer sec(min=0, max=61) "Second" annotation(absoluteValue=true);
43-
Integer min(min=0, max=59) "Minute" annotation(absoluteValue=true);
41+
Integer millisecond(min=0, max=999) "Millisecond" annotation(absoluteValue=true);
42+
Integer second(min=0, max=61) "Second" annotation(absoluteValue=true);
43+
Integer minute(min=0, max=59) "Minute" annotation(absoluteValue=true);
4444
Integer hour(min=0, max=23) "Hour" annotation(absoluteValue=true);
4545
Integer day(min=1, max=31) "Day" annotation(absoluteValue=true);
46-
Integer mon(min=1, max=12) "Month" annotation(absoluteValue=true);
46+
Integer month(min=1, max=12) "Month" annotation(absoluteValue=true);
4747
Integer year "Year" annotation(absoluteValue=true);
4848
annotation (Documentation(info="<html>
4949
<blockquote>

ModelicaTest/Utilities.mo

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -389,12 +389,12 @@ extends Modelica.Icons.ExamplesPackage;
389389
Streams.print("... Test of Modelica.Utilities.Time", logFile);
390390

391391
now := Modelica.Utilities.Time.getTime();
392-
Streams.print(" ms = " + String(now.ms));
393-
Streams.print(" sec = " + String(now.sec));
394-
Streams.print(" min = " + String(now.min));
392+
Streams.print(" ms = " + String(now.millisecond));
393+
Streams.print(" sec = " + String(now.second));
394+
Streams.print(" min = " + String(now.minute));
395395
Streams.print(" hour = " + String(now.hour));
396396
Streams.print(" day = " + String(now.day));
397-
Streams.print(" mon = " + String(now.mon));
397+
Streams.print(" mon = " + String(now.month));
398398
Streams.print(" year = " + String(now.year));
399399

400400
assert(not Modelica.Utilities.Time.isLeapYear(1900), "Time.isLeapYear failed");

0 commit comments

Comments
 (0)