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

Function garrow_decimal_new_string

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

Source from the content-addressed store, hash-verified

98
99template <typename Decimal>
100typename DecimalConverter<Decimal>::GArrowType *
101garrow_decimal_new_string(const gchar *data, GError **error, const gchar *tag)
102{
103 auto arrow_decimal_result = Decimal::FromString(data);
104 if (garrow::check(error, arrow_decimal_result, tag)) {
105 auto arrow_decimal = std::make_shared<Decimal>(*arrow_decimal_result);
106 DecimalConverter<Decimal> converter;
107 return converter.new_raw(&arrow_decimal);
108 } else {
109 return NULL;
110 }
111}
112
113template <typename Decimal>
114typename DecimalConverter<Decimal>::GArrowType *

Callers

nothing calls this directly

Calls 3

FromStringFunction · 0.85
checkFunction · 0.70
new_rawMethod · 0.45

Tested by

no test coverage detected