isEqualTo(const OSString *)
Tests the equality of an OSData object to an OSString.
Declaration
virtual bool isEqualTo(
const OSString *aString) const;Parameters
- aString:
The string object to be compared against the receiver.
Return Value
true if the two objects are equivalent, false otherwise.
Overview
This function compares the bytes of the OSData object against those of the OSString, accounting for the possibility that an OSData might explicitly include a nul character as part of its total length. Thus, for example, an OSData object containing either the bytes <'u', 's', 'b', '\0'> or <'u', 's', 'b'> will compare as equal to the OSString containing "usb".
See Also
Miscellaneous
appendByteappendBytes(const OSData *)appendBytes(const void *, unsigned int)ensureCapacityfreegetBytesNoCopy()getBytesNoCopy(unsigned int, unsigned int)getCapacitygetCapacityIncrementgetLengthinitWithBytesinitWithBytesNoCopyinitWithCapacityinitWithData(const OSData *)initWithData(const OSData *, unsigned int, unsigned int)isEqualTo(const OSData *)isEqualTo(const OSMetaClassBase *)isEqualTo(const void *, unsigned int)serializesetCapacityIncrementwithByteswithBytesNoCopywithCapacitywithData(const OSData *)withData(const OSData *, unsigned int, unsigned int)