Skip to content

Commit 6ffff54

Browse files
committed
fix(lambda): 🐛 general translation
Refers: #6
1 parent b46764e commit 6ffff54

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

book/04-lambda/sections/01-functional-interfaces.asc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ include::{section-java-package}/functionalinterfaces/FunctionalInterfaces_Extend
5959
include::{section-java-package}/functionalinterfaces/FunctionalInterfaces_ExtendsNewMethod.java[tag=code]
6060
----
6161

62-
. Utilizar a anotação `@FunctionalInterface` em interfaces que possuem mais de um método abstrato causa um erro de compilação.
62+
. Using the `@FunctionalInterface` annotation on interfaces that have more than one abstract method causes a compilation error.
6363
+
6464
[source,java,indent=0]
6565
.{java-package}/functionalinterfaces/FunctionalInterfaces_InterfaceCompilationError.java

book/04-lambda/sections/03-built-in-interfaces.asc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ public interface BiFunction<T, U, R> {
186186
}
187187
----
188188

189-
. Possible implementations for `Function` or` BiFunction` are functions that multiply the given values:
189+
. Possible implementations for `Function` or `BiFunction` are functions that multiply the given values:
190190
+
191191
[source,java,indent=0]
192192
.{java-package}/builtininterfaces/BuiltInInterfaces_FunctionExample.java
@@ -244,7 +244,7 @@ public interface BinaryOperator<T> extends BiFunction<T,T,T> {
244244
+
245245
Note that there is no declared abstract method as it only extends the existing `BiFunction` interface.
246246

247-
. Possible implementations for `UnaryOperator` or` BinaryOperator` are functions that add a fixed number or add one number to another:
247+
. Possible implementations for `UnaryOperator` or `BinaryOperator` are functions that add a fixed number or add one number to another:
248248
+
249249
[source,java,indent=0]
250250
.{java-package}/builtininterfaces/BuiltInInterfaces_OperatorExample.java

src/org/j6toj8/lambda/functionalinterfaces/FunctionalInterfaces_InterfaceCompilationError.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@ public class FunctionalInterfaces_InterfaceCompilationError {
44

55
// tag::code[]
66
@FunctionalInterface
7-
interface Executavel { // interface funcional
8-
void execute(); // método funcional
7+
interface Executable { // function interface
8+
void execute(); // functional method
99
}
1010

1111
@FunctionalInterface
12-
interface Aplicacao extends Executavel { // NÃO COMPILA!
13-
// não pode ser anotada como funcional, pois possui 2 métodos abstratos
14-
void inicie();
12+
interface Application extends Executable { // NOT COMPILING!
13+
// cannot be annotated as functional as it has 2 abstract methods
14+
void init();
1515
}
1616
// end::code[]
1717
}

0 commit comments

Comments
 (0)