Equals
From OxeyeWiki
WChar:equals(other) | ||
This method checks if this string object is identical to another WChar string object. | ||
Parameter | Expected Type | Description |
other | A WChar | The other WChar object to compare with. |
Returns | ||
Returns true if this object is equal to the other object, otherwise false. Will return false if the parameter is any other data type than WChar. |
Example
local printBoolean = function(value) if (value) then print("true") else print("false") end end local textA = WChar("A") local textB = WChar("a") printBoolean(textA:equals(textB)) -- false, case sensitive printBoolean(textA:equals("A")) -- false, the parameter is not a WChar printBoolean(textA:equals(WChar("A"))) -- true