YngwieWang commented on a change in pull request #9299: [FLINK-13405][docs-zh] 
Translate "Basic API Concepts" page into Chinese
URL: https://github.com/apache/flink/pull/9299#discussion_r317598936
 
 

 ##########
 File path: docs/dev/api_concepts.zh.md
 ##########
 @@ -739,164 +646,125 @@ class WordWithCount(var word: String, var count: Int) {
 
 val input = env.fromElements(
     new WordWithCount("hello", 1),
-    new WordWithCount("world", 2)) // Case Class Data Set
+    new WordWithCount("world", 2)) // Case Class 数据集
 
-input.keyBy("word")// key by field expression "word"
+input.keyBy("word")// 以字段表达式“word”为键
 
 {% endhighlight %}
 </div>
 </div>
 
-#### Primitive Types
+#### 基本数据类型
 
-Flink supports all Java and Scala primitive types such as `Integer`, `String`, 
and `Double`.
+Flink 支持所有 Java 和 Scala 的基本数据类型如 `Integer`、 `String`、和 `Double`。
 
-#### General Class Types
+#### 常规的类
 
-Flink supports most Java and Scala classes (API and custom).
-Restrictions apply to classes containing fields that cannot be serialized, 
like file pointers, I/O streams, or other native
-resources. Classes that follow the Java Beans conventions work well in general.
+Flink 支持大部分 Java 和 Scala 的类(API 和自定义)。
+除了包含无法序列化的字段的类,如文件指针,I / O流或其他本地资源。遵循 Java Beans 约定的类通常可以很好地工作。
 
-All classes that are not identified as POJO types (see POJO requirements 
above) are handled by Flink as general class types.
-Flink treats these data types as black boxes and is not able to access their 
content (i.e., for efficient sorting). General types are de/serialized using 
the serialization framework [Kryo](https://github.com/EsotericSoftware/kryo).
+Flink 对于所有未识别为 POJO 类型的类(请参阅上面对于的 POJO 要求)都作为常规类处理。
+Flink 将这些数据类型视为黑盒,并且无法访问其内容(为了诸如高效排序等目的)。常规类使用 
[Kryo](https://github.com/EsotericSoftware/kryo) 序列化框架进行序列化和反序列化。
 
-#### Values
+#### 值
 
-*Value* types describe their serialization and deserialization manually. 
Instead of going through a
-general purpose serialization framework, they provide custom code for those 
operations by means of
-implementing the `org.apache.flinktypes.Value` interface with the methods 
`read` and `write`. Using
-a Value type is reasonable when general purpose serialization would be highly 
inefficient. An
-example would be a data type that implements a sparse vector of elements as an 
array. Knowing that
-the array is mostly zero, one can use a special encoding for the non-zero 
elements, while the
-general purpose serialization would simply write all array elements.
+*值* 类型手工描述其序列化和反序列化。它们不是通过通用序列化框架,而是通过使用 `read` 和 `write` 方法实现 
`org.apache.flinktypes.Value` 
接口来为这些操作提供自定义编码。当通用序列化效率非常低时,使用值类型是合理的。例如,用数组实现稀疏向量。已知数组大部分元素为零,就可以对非零元素使用特殊编码,而通用序列化只会简单地将所有数组元素都写入。
 
 Review comment:
   👍 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to