[SPARK-3713][SQL] Uses JSON to serialize DataType objects

This PR uses JSON instead of `toString` to serialize `DataType`s. The latter is not only hard to parse but also flaky in many cases.

Since we already write schema information to Parquet metadata in the old style, we have to reserve the old `DataType` parser and ensure downward compatibility. The old parser is now renamed to `CaseClassStringParser` and moved into `object DataType`.

@JoshRosen @davis Please help review PySpark related changes, thanks!
if json_value is {}, it's not hashable, you can not use 'in' for it.

I would like to use same type of json_value for all types, such as dict, with a key called type, such as:

```
{'type': 'int'}
``` 
for other types, it could have additional keys, based on the type, such as:

```
{'type':'array', 'element': {'type':'int'}, 'null': True}
```

In this ways, it will be easier to do the type switch.