| 40 | struct ParseBooleanString { |
| 41 | template <typename OutValue, typename Arg0Value> |
| 42 | static OutValue Call(KernelContext*, Arg0Value val, Status* st) { |
| 43 | bool result = false; |
| 44 | if (ARROW_PREDICT_FALSE(!ParseValue<BooleanType>(val.data(), val.size(), &result))) { |
| 45 | *st = Status::Invalid("Failed to parse value: ", val); |
| 46 | } |
| 47 | return result; |
| 48 | } |
| 49 | }; |
| 50 | |
| 51 | std::vector<std::shared_ptr<CastFunction>> GetBooleanCasts() { |