bool.xml 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="bool" category="Built-In Types" version="3.1.2">
  3. <brief_description>
  4. Boolean built-in type
  5. </brief_description>
  6. <description>
  7. Boolean built-in type.
  8. </description>
  9. <tutorials>
  10. </tutorials>
  11. <methods>
  12. <method name="bool">
  13. <return type="bool">
  14. </return>
  15. <argument index="0" name="from" type="int">
  16. </argument>
  17. <description>
  18. Cast an [int] value to a boolean value, this method will return [code]true[/code] if called with an integer value different to 0 and [code]false[/code] in other case.
  19. </description>
  20. </method>
  21. <method name="bool">
  22. <return type="bool">
  23. </return>
  24. <argument index="0" name="from" type="float">
  25. </argument>
  26. <description>
  27. Cast a [float] value to a boolean value, this method will return [code]true[/code] if called with a floating point value different to 0 and [code]false[/code] in other case.
  28. </description>
  29. </method>
  30. <method name="bool">
  31. <return type="bool">
  32. </return>
  33. <argument index="0" name="from" type="String">
  34. </argument>
  35. <description>
  36. Cast a [String] value to a boolean value, this method will return [code]true[/code] if called with a non empty string and [code]false[/code] in other case. Examples: [code]bool('False')[/code] returns [code]true[/code], [code]bool('')[/code] returns [code]false[/code].
  37. </description>
  38. </method>
  39. </methods>
  40. <constants>
  41. </constants>
  42. </class>