* garrow_input_stream_read_tensor: * @input_stream: A #GArrowInputStream. * @error: (nullable): Return location for a #GError or %NULL. * * Returns: (transfer full) (nullable): * #GArrowTensor on success, %NULL on error. * * Since: 0.11.0 */
| 281 | * Since: 0.11.0 |
| 282 | */ |
| 283 | GArrowTensor * |
| 284 | garrow_input_stream_read_tensor(GArrowInputStream *input_stream, GError **error) |
| 285 | { |
| 286 | auto arrow_input_stream = garrow_input_stream_get_raw(input_stream); |
| 287 | |
| 288 | auto arrow_tensor = arrow::ipc::ReadTensor(arrow_input_stream.get()); |
| 289 | if (garrow::check(error, arrow_tensor, "[input-stream][read-tensor]")) { |
| 290 | return garrow_tensor_new_raw(&(arrow_tensor.ValueOrDie())); |
| 291 | } else { |
| 292 | return NULL; |
| 293 | } |
| 294 | } |
| 295 | |
| 296 | /** |
| 297 | * garrow_input_stream_read_record_batch: |
nothing calls this directly
no test coverage detected