Movatterモバイル変換


[0]ホーム

URL:


CFEngine documentation homepage

isgreaterthan

Suggest changes
Table of contents

Prototype:isgreaterthan(value1, value2)

Return type:boolean

Description: Returns whethervalue1 is greater thanvalue2.

The comparison is made numerically if possible. If the values arestrings, the comparison is lexical (based on C's strcmp()).

Arguments:

  • value1:string - Larger string or value - in the range:.*
  • value2:string - Smaller string or value - in the range:.*

Example:

code
bodycommoncontrol{bundlesequence=>{"example"};}bundleagentexample{classes:"ok"expression=>isgreaterthan("1","0");reports:ok::"Assertion is true";!ok::"Assertion is false";}

Output:

code
R: Assertion is true

Still need help?

Chat Ask a question on Github Mailing list
Version 
master3.24 (LTS)3.21 (LTS)view all versions

[8]ページ先頭

©2009-2025 Movatter.jp