-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(collections): 🎸 diamond, translated
Refers: #10
- Loading branch information
1 parent
9b60c68
commit c7dd38c
Showing
2 changed files
with
18 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,28 @@ | ||
:java-package: src/org/j6toj8/collections | ||
:section-java-package: ../../../{java-package} | ||
|
||
=== Diamond Operator (Operador Diamante) | ||
=== Diamond Operator | ||
|
||
.Objetivo | ||
.Objective | ||
-------------------------------------------------- | ||
Develop code that uses diamond with generic declarations | ||
- | ||
Desenvolver código que usa o diamond (diamante) com declarações de generics | ||
-------------------------------------------------- | ||
|
||
O Diamond Operator (ou Operador Diamante) foi criado no Java 7 para remover código desnecessário ao declarar classes que usam `Generics` (ou tipos genéricos). Abaixo um exemplo que é possível omitir o tipo de algumas classes utilizando o _Diamond Operator_. | ||
Diamond Operator was created in Java 7 to remove unnecessary code when declaring classes that use `Generics` (or generic types). Below is an example that you can omit the type of some classes using _Diamond Operator_. | ||
|
||
[source,java,indent=0] | ||
.{java-package}/diamond/Collections_Diamond.java | ||
---- | ||
include::{section-java-package}/diamond/Collections_Diamond.java[tag=code] | ||
---- | ||
|
||
.References | ||
**** | ||
* Using the Diamond Operator | ||
+ | ||
Boyarsky, Jeanne; Selikoff, Scott. OCP: Oracle Certified Professional Java SE 8 Programmer II Study Guide (p. 596). Wiley. Edição do Kindle. | ||
Boyarsky, Jeanne; Selikoff, Scott. OCP: Oracle Certified Professional Java SE 8 Programmer II Study Guide (p. 596). Wiley. Kindle Edition. | ||
* https://www.baeldung.com/java-diamond-operator[Guide to the Diamond Operator in Java.] | ||
**** | ||
**** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters