endsWith

Returns whether this array ends with the given suffix.

An empty suffix always matches, including against an empty array. A suffix longer than the array never matches. This function never throws.

Return

true if the last suffix.size bytes equal suffix.

Parameters

suffix

the byte sequence expected at the end of the array.