Validates that `&self.values[start_offset..]` is a valid UTF-8 sequence This MUST be combined with validating that the offsets start on a character boundary, otherwise it would be possible for the values array to be a valid UTF-8 sequence, but not the individual string slices it contains [`Self::try_push`] can perform this validation check on insertion
(&self, start_offset: usize)
| 126 | /// |
| 127 | /// [`Self::try_push`] can perform this validation check on insertion |
| 128 | pub fn check_valid_utf8(&self, start_offset: usize) -> Result<()> { |
| 129 | check_valid_utf8(&self.values.as_slice()[start_offset..]) |
| 130 | } |
| 131 | |
| 132 | /// Converts this into an [`ArrayRef`] with the provided `data_type` and `null_buffer` |
| 133 | pub fn into_array(self, null_buffer: Option<Buffer>, data_type: ArrowType) -> ArrayRef { |