I have a basic understanding of OOP concepts, but here is a question I currently have.
Say I create this object:
Test test1 = new Test();
I then call a function within this Object
test1.toString();
And when overriding that toString() method I want to get the 'test1' object name from the main class file, so I can print it out like so...
System.out.println( "This is a test " + test1.toString() );
Prints:
This is a test test1
Thank you
Test test1 = new Test(); Test test2 = test1;?