summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--java.html.markdown30
1 files changed, 26 insertions, 4 deletions
diff --git a/java.html.markdown b/java.html.markdown
index ba602d2e..bb0b0d38 100644
--- a/java.html.markdown
+++ b/java.html.markdown
@@ -348,7 +348,7 @@ public class LearnJava {
validCodes.add("FINLAND");
}
- // But there's a nifty way to achive the same thing in an
+ // But there's a nifty way to achieve the same thing in an
// easier way, by using something that is called Double Brace
// Initialization.
@@ -358,9 +358,9 @@ public class LearnJava {
add("FINLAND");
}}
- // The first brace is creating an new AnonymousInnerClass and the
- // second one declares and instance initializer block. This block
- // is called with the anonymous inner class is created.
+ // The first brace is creating a new AnonymousInnerClass and the
+ // second one declares an instance initializer block. This block
+ // is called when the anonymous inner class is created.
// This does not only work for Collections, it works for all
// non-final classes.
@@ -490,6 +490,16 @@ public interface Digestible {
// We can now create a class that implements both of these interfaces.
public class Fruit implements Edible, Digestible {
@Override
+<<<<<<< HEAD
+ public void eat() {
+ // awesome code goes here
+ }
+
+ @Override
+ public void digest() {
+ // awesome code goes here
+ }
+=======
public void eat() {
// ...
}
@@ -498,6 +508,7 @@ public class Fruit implements Edible, Digestible {
public void digest() {
// ...
}
+>>>>>>> adambard/master
}
// In Java, you can extend only one class, but you can implement many
@@ -505,12 +516,23 @@ public class Fruit implements Edible, Digestible {
public class ExampleClass extends ExampleClassParent implements InterfaceOne,
InterfaceTwo {
@Override
+<<<<<<< HEAD
+ public void InterfaceOneMethod() {
+ // awesome code goes here
+ }
+
+ @Override
+ public void InterfaceTwoMethod() {
+ // awesome code goes here
+ }
+=======
public void InterfaceOneMethod() {
}
@Override
public void InterfaceTwoMethod() {
}
+>>>>>>> adambard/master
}
// Abstract Classes