Github user twalthr commented on a diff in the pull request:
https://github.com/apache/flink/pull/4612#discussion_r140764696
--- Diff:
flink-libraries/flink-table/src/main/scala/org/apache/flink/table/api/Types.scala
---
@@ -20,60 +20,123 @@ package org.apache.flink.table.api
import org.apache.flink.api.common.typeinfo.{PrimitiveArrayTypeInfo,
TypeInformation, Types => JTypes}
import org.apache.flink.api.java.typeutils.{MapTypeInfo,
ObjectArrayTypeInfo}
import org.apache.flink.table.typeutils.TimeIntervalTypeInfo
-import org.apache.flink.types.Row
import _root_.scala.annotation.varargs
/**
- * This class enumerates all supported types of the Table API.
+ * This class enumerates all supported types of the Table API & SQL.
*/
object Types {
--- End diff --
We had this initially. The problem is that Scala creates method where as
Java fields. It would be a mixture of `STRING()`, `INTERVAL_MILLIS`.
Furthermore, not all types of the Java API are important for Table API users. I
think it is better to have specialized classes for each API. This also allows
to have custom Javadocs. Like the STRING <-> VARCHAR mapping comment.
---