Created
February 18, 2016 19:10
-
-
Save swalberg/bf8b741abaa09f3f4e68 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
$ java Test | |
v2 |
This file contains hidden or 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
public class Test { | |
public static void main(String[] args) { | |
VisTest v1 = new VisTest("v1"); | |
VisTest v2 = new VisTest("v2"); | |
v1.doIt(v2); | |
} | |
} |
This file contains hidden or 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
public class VisTest { | |
private String foo; | |
public VisTest(String foo) { | |
this.foo = foo; | |
} | |
public void doIt(VisTest other) { | |
System.out.println(other.foo); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment