MCPcopy Create free account
hub / github.com/apache/arrow / garrow_decimal_to_bytes

Function garrow_decimal_to_bytes

c_glib/arrow-glib/decimal.cpp:222–230  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

220
221template <typename Decimal>
222GBytes *
223garrow_decimal_to_bytes(typename DecimalConverter<Decimal>::GArrowType *decimal)
224{
225 DecimalConverter<Decimal> converter;
226 const auto arrow_decimal = converter.get_raw(decimal);
227 uint8_t data[DecimalConverter<Decimal>::ArrowType::kBitWidth / 8];
228 arrow_decimal->ToBytes(data);
229 return g_bytes_new(data, sizeof(data));
230}
231
232template <typename Decimal>
233void

Callers

nothing calls this directly

Calls 2

ToBytesMethod · 0.80
get_rawMethod · 0.45

Tested by

no test coverage detected