Skip to content

Adds Chinese translation (Subsumes #280) #450

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 44 commits into from
Aug 24, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
0a2e533
Chinese Translation
Jan 2, 2014
16081ba
Update index.md
imsingo Jan 2, 2014
433e0e3
Update index.md
imsingo Jan 2, 2014
3b777f9
Update index.md
imsingo Jan 2, 2014
581f88d
Update String_Interpolation.md
imsingo Jan 2, 2014
5dacd4d
Update Implicit-Classes.md
imsingo Jan 2, 2014
032e090
Update Futures-and-Promises.md
imsingo Jan 2, 2014
69435a2
Update Concrete_Parallel_Collection_Classes.md
imsingo Jan 2, 2014
0b5ac16
Update index.md
imsingo Jan 2, 2014
4668022
Update Migrating_from_Scala_2_7.md
imsingo Jan 2, 2014
12c8822
Update Conversions_Between_Java_and_Scala_Collections.md
imsingo Jan 2, 2014
980f7e2
Update Creating_Collections_From_Scratch.md
imsingo Jan 2, 2014
cc9f32e
Update Iterators.md
imsingo Jan 2, 2014
3e907f0
Update Views.md
imsingo Jan 2, 2014
b1b7614
Update Equality.md
imsingo Jan 2, 2014
b9e235c
Update Performance_Characteristics.md
imsingo Jan 2, 2014
30fe9df
Update Strings.md
imsingo Jan 2, 2014
8192fae
Update Arrays.md
imsingo Jan 2, 2014
9a87b53
Update Concrete_Mutable_Collection_Classes.md
imsingo Jan 2, 2014
bdf5d5b
Update Concrete_Immutable_Collection_Classes.md
imsingo Jan 2, 2014
a6ef46d
Update Maps.md
imsingo Jan 2, 2014
90ad663
Update Sets.md
imsingo Jan 2, 2014
a531a82
Update The_sequence_traits.md
imsingo Jan 2, 2014
7ad6d6a
Update Trait_Iterable.md
imsingo Jan 2, 2014
28c92e4
Update Trait_Traversable.md
imsingo Jan 2, 2014
aed6c7b
Update Mutable_and_Immutable_Collections.md
imsingo Jan 2, 2014
ea4d5e3
Update Introduction.md
imsingo Jan 2, 2014
2234334
Update The_Scala_Actors_API.md
imsingo Jan 2, 2014
48575a9
Update The_Architecture_of_Scala_Collections.md
imsingo Jan 2, 2014
51280dc
Update Measuring_Performance.md
imsingo Jan 2, 2014
b0a274d
Update Configuring_Parallel_Collections.md
imsingo Jan 2, 2014
b9909b5
Update Creating_Custom_Parallel_Collections.md
imsingo Jan 2, 2014
f991c8d
Update Architecture_of_the_Parallel_Collections_Library.md
imsingo Jan 2, 2014
401150e
Update Concurrent_Tries.md
imsingo Jan 2, 2014
14e123c
Update Parallel_Collection_Conversions.md
imsingo Jan 2, 2014
0e93fa7
Update Overview.md
imsingo Jan 2, 2014
e4ae704
Update Value-Classes-and-Universal-Traits.md
imsingo Jan 2, 2014
9dab6f6
Update The-Scala-Actors-Migration-Guide.md
imsingo Jan 2, 2014
1a29ebf
Rename files names back to the original. Fix misbehaving language hea…
eed3si9n Aug 24, 2015
cbb9448
Add zn-cn to the collection overview's languages header
eed3si9n Aug 24, 2015
843cc8c
Add languages header to parallel-collections overview
eed3si9n Aug 24, 2015
1059fdf
Add languages header to core articles
eed3si9n Aug 24, 2015
d322e2b
Fix overview index page
eed3si9n Aug 24, 2015
89de7d6
Fix image
eed3si9n Aug 24, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions _layouts/guides-thanks.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
layout: index
---

<div class="container">
<div class="row">
<div class="span10">
{{ content }}
</div>

</div>
</div>
2 changes: 1 addition & 1 deletion overviews/collections/arrays.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 10
languages: [ja]
languages: [ja, zh-cn]
---

[Array](http://www.scala-lang.org/api/{{ site.scala-version }}/scala/Array.html) is a special kind of collection in Scala. On the one hand, Scala arrays correspond one-to-one to Java arrays. That is, a Scala array `Array[Int]` is represented as a Java `int[]`, an `Array[Double]` is represented as a Java `double[]` and a `Array[String]` is represented as a Java `String[]`. But at the same time, Scala arrays offer much more than their Java analogues. First, Scala arrays can be _generic_. That is, you can have an `Array[T]`, where `T` is a type parameter or abstract type. Second, Scala arrays are compatible with Scala sequences - you can pass an `Array[T]` where a `Seq[T]` is required. Finally, Scala arrays also support all sequence operations. Here's an example of this in action:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 8
languages: [ja]
languages: [ja, zh-cn]
---

Scala provides many concrete immutable collection classes for you to choose from. They differ in the traits they implement (maps, sets, sequences), whether they can be infinite, and the speed of various operations. Here are some of the most common immutable collection types used in Scala.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 9
languages: [ja]
languages: [ja, zh-cn]
---

You've now seen the most commonly used immutable collection classes that Scala provides in its standard library. Take a look now at the mutable collection classes.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 17
languages: [ja]
languages: [ja, zh-cn]
---

Like Scala, Java also has a rich collections library. There are many similarities between the two. For instance, both libraries know iterators, iterables, sets, maps, and sequences. But there are also important differences. In particular, the Scala libraries put much more emphasis on immutable collections, and provide many more operations that transform a collection into a new one.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/creating-collections-from-scratch.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 16
languages: [ja]
languages: [ja, zh-cn]
---

You have syntax `List(1, 2, 3)` to create a list of three integers and `Map('A' -> 1, 'C' -> 2)` to create a map with two bindings. This is actually a universal feature of Scala collections. You can take any collection name and follow it by a list of elements in parentheses. The result will be a new collection with the given elements. Here are some more examples:
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/equality.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 13
languages: [ja]
languages: [ja, zh-cn]
---

The collection libraries have a uniform approach to equality and hashing. The idea is, first, to divide collections into sets, maps, and sequences. Collections in different categories are always unequal. For instance, `Set(1, 2, 3)` is unequal to `List(1, 2, 3)` even though they contain the same elements. On the other hand, within the same category, collections are equal if and only if they have the same elements (for sequences: the same elements in the same order). For example, `List(1, 2, 3) == Vector(1, 2, 3)`, and `HashSet(1, 2) == TreeSet(2, 1)`.
Expand Down
4 changes: 2 additions & 2 deletions overviews/collections/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ disqus: true

partof: collections
num: 1
languages: [ja, pt-br]
languages: [ja, zh-cn, pt-br]
---

**Martin Odersky, and Lex Spoon**

In the eyes of many, the new collections framework is the most significant
change in the Scala 2.8 release. Scala had collections before (and in fact the new
framework is largely compatible with them). But it's only 2.8 that
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/iterators.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 15
languages: [ja]
languages: [ja, zh-cn]
---

An iterator is not a collection, but rather a way to access the elements of a collection one by one. The two basic operations on an iterator `it` are `next` and `hasNext`. A call to `it.next()` will return the next element of the iterator and advance the state of the iterator. Calling `next` again on the same iterator will then yield the element one beyond the one returned previously. If there are no more elements to return, a call to `next` will throw a `NoSuchElementException`. You can find out whether there are more elements to return using [Iterator](http://www.scala-lang.org/api/{{ site.scala-version }}/scala/collection/Iterator.html)'s `hasNext` method.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/maps.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 7
languages: [ja]
languages: [ja, zh-cn]
---

A [Map](http://www.scala-lang.org/api/current/scala/collection/Map.html) is an [Iterable](http://www.scala-lang.org/api/current/scala/collection/Iterable.html) consisting of pairs of keys and values (also named _mappings_ or _associations_). Scala's [Predef](http://www.scala-lang.org/api/current/scala/Predef$.html) class offers an implicit conversion that lets you write `key -> value` as an alternate syntax for the pair `(key, value)`. For instance `Map("x" -> 24, "y" -> 25, "z" -> 26)` means exactly the same as `Map(("x", 24), ("y", 25), ("z", 26))`, but reads better.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/migrating-from-scala-27.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ disqus: true
partof: collections
num: 18
outof: 18
languages: [ja]
languages: [ja, zh-cn]
---

Porting your existing Scala applications to use the new collections should be almost automatic. There are only a couple of possible issues to take care of.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 2
languages: [ja]
languages: [ja, zh-cn]
---

Scala collections systematically distinguish between mutable and
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/performance-characteristics.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 12
languages: [ja]
languages: [ja, zh-cn]
---

The previous explanations have made it clear that different collection types have different performance characteristics. That's often the primary reason for picking one collection type over another. You can see the performance characteristics of some common operations on collections summarized in the following two tables.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/seqs.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 5
languages: [ja]
languages: [ja, zh-cn]
---

The [Seq](http://www.scala-lang.org/api/current/scala/collection/Seq.html) trait represents sequences. A sequence is a kind of iterable that has a `length` and whose elements have fixed index positions, starting from `0`.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/sets.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 6
languages: [ja]
languages: [ja, zh-cn]
---

`Set`s are `Iterable`s that contain no duplicate elements. The operations on sets are summarized in the following table for general sets and in the table after that for mutable sets. They fall into the following categories:
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/strings.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 11
languages: [ja]
languages: [ja, zh-cn]
---

Like arrays, strings are not directly sequences, but they can be converted to them, and they also support all sequence operations on strings. Here are some examples of operations you can invoke on strings.
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/trait-iterable.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 4
languages: [ja]
languages: [ja, zh-cn]
---

The next trait from the top in the collections hierarchy is `Iterable`. All methods in this trait are defined in terms of an an abstract method, `iterator`, which yields the collection's elements one by one. The `foreach` method from trait `Traversable` is implemented in `Iterable` in terms of `iterator`. Here is the actual implementation:
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/trait-traversable.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 3
languages: [ja]
languages: [ja, zh-cn]
---

At the top of the collection hierarchy is trait `Traversable`. Its only abstract operation is `foreach`:
Expand Down
2 changes: 1 addition & 1 deletion overviews/collections/views.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ disqus: true

partof: collections
num: 14
languages: [ja]
languages: [ja, zh-cn]
---

Collections have quite a few methods that construct new collections. Examples are `map`, `filter` or `++`. We call such methods transformers because they take at least one collection as their receiver object and produce another collection as their result.
Expand Down
2 changes: 1 addition & 1 deletion overviews/core/_posts/2010-11-30-actors.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
layout: overview
title: The Scala Actors API
overview: actors
languages: [es]
languages: [zh-cn, es]
---

**Philipp Haller and Stephen Tu**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
layout: overview
title: The Architecture of Scala Collections
overview: architecture-of-scala-collections
languages: [zh-cn]
---

**Martin Odersky and Lex Spoon**
Expand Down
2 changes: 1 addition & 1 deletion overviews/core/_posts/2012-09-20-futures.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: Futures and Promises
label-color: success
label-text: New in 2.10
overview: futures
languages: [ja]
languages: [ja, zh-cn]
---

**By: Philipp Haller, Aleksandar Prokopec, Heather Miller, Viktor Klang, Roland Kuhn, and Vojin Jovanovic**
Expand Down
2 changes: 2 additions & 0 deletions overviews/core/_posts/2012-09-20-implicit-classes.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
---
layout: overview
title: Implicit Classes
overview: implicit-classes
label-color: success
label-text: Available
languages: [zh-cn]
---

**Josh Suereth**
Expand Down
2 changes: 1 addition & 1 deletion overviews/core/_posts/2012-09-21-string-interpolation.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ disqus: true
label-color: success
label-text: New in 2.10
overview: string-interpolation
languages: [es, ja]
languages: [es, ja, zh-cn]
---

**Josh Suereth**
Expand Down
2 changes: 1 addition & 1 deletion overviews/core/_posts/2012-11-03-value-classes.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ title: Value Classes and Universal Traits
label-color: success
label-text: New in 2.10
overview: value-classes
languages: [ja]
languages: [ja, zh-cn]
---

**Mark Harrah**
Expand Down
2 changes: 2 additions & 0 deletions overviews/core/_posts/2012-11-08-actors-migration-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ layout: overview
title: The Scala Actors Migration Guide
label-color: success
label-text: New in 2.10
overview: actors-migration-guide
languages: [zh-cn]
---

**Vojin Jovanovic and Philipp Haller**
Expand Down
2 changes: 1 addition & 1 deletion overviews/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: guides-index
title: Guides and Overviews
languages: [es, ja]
languages: [ja, zh-cn, es]
---

<div class="page-header-index">
Expand Down
1 change: 1 addition & 0 deletions overviews/parallel-collections/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Architecture of the Parallel Collections Library
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 5
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Concrete Parallel Collection Classes
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 2
---

Expand Down
1 change: 1 addition & 0 deletions overviews/parallel-collections/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Configuring Parallel Collections
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 7
---

Expand Down
1 change: 1 addition & 0 deletions overviews/parallel-collections/conversions.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Parallel Collection Conversions
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 3
---

Expand Down
1 change: 1 addition & 0 deletions overviews/parallel-collections/ctries.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Concurrent Tries
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 4
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Creating Custom Parallel Collections
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 6
---

Expand Down
1 change: 1 addition & 0 deletions overviews/parallel-collections/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ title: Overview
disqus: true

partof: parallel-collections
languages: [ja, zh-cn, es]
num: 1
---

Expand Down
2 changes: 1 addition & 1 deletion overviews/parallel-collections/performance.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ disqus: true
partof: parallel-collections
num: 8
outof: 8
languages: [ja, es]
languages: [ja, zh-cn, es]
---

## Performance on the JVM
Expand Down
2 changes: 1 addition & 1 deletion pt-br/overviews/collections/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ partof: collections
num: 1

about: Este documento foi traduzido por <a href="http://douglasjose.com">Douglas José</a>. Licensed by Douglas José under a CC-BY-SA 3.0 license.
languages: [ja, pt-br]
language: pt-br
---

**Martin Odersky, and Lex Spoon**
Expand Down
Loading