Skip to main content

lengthIsMax

Short summary

This assertion method checks if the current string stringToCheck length is equal or less than to maxLength. Processed strings must be in UTF-8 encoding

Parameters

NameTypeCommentKind
stringToCheckTc2_System.T_MaxStringcurrent string to checkinput
maxLengthUSINTupper limit of the length of stringToCheckinput
messageAssertMessagemessage if the assertion is falseinput

Code

Declaration

METHOD lengthIsMax
VAR_INPUT
(* current string to check *)
stringToCheck :Tc2_System.T_MaxString;
(* upper limit of the length of ``stringToCheck`` *)
maxLength :USINT;
(* message if the assertion is false *)
message :AssertMessage;
END_VAR