datatypes::types::cast

Function can_cast_type

Source
pub fn can_cast_type(src_value: &Value, dest_type: &ConcreteDataType) -> bool
Expand description

Return true if the src_value can be casted to dest_type, Otherwise, return false.

Notice: this function does not promise that the cast_with_opt will succeed, it only checks whether the src_value can be casted to dest_type.