diff --git a/javaguide.html b/javaguide.html index 5ef0dc8dc..5b11ee039 100644 --- a/javaguide.html +++ b/javaguide.html @@ -202,6 +202,11 @@

3.3.3 Ordering and spacing

+

3.3.4 No static import for classes

+ +

Static import is not used for static nested classes. They are imported with +normal imports.

+

3.4 Class declaration

@@ -370,12 +375,17 @@

4.5.1 Where to break

the symbol. (Note that this is not the same practice used in Google style for other languages, such as C++ and JavaScript.) @@ -392,6 +402,19 @@

4.5.1 Where to break

  • A comma (,) stays attached to the token that precedes it.
  • + +
  • A line is never broken adjacent to the arrow in a lambda, except that a + break may come immediately after the arrow if the body of the lambda consists + of a single unbraced expression. Examples: +
    MyLambda<String, Long, Object> lambda =
    +    (String label, Long value, Object obj) -> {
    +        ...
    +    };
    +
    +Predicate<String> predicate = str ->
    +    longExpressionInvolving(str);
    +
    +
  • Note: The primary goal for line wrapping is to have clear @@ -490,7 +513,7 @@

    4.6.2 Horizontal whitespace

  • the two colons (::) of a method reference, which is written like Object::toString
  • the dot separator (.), which is written like - object.toString()
  • + object.toString()