java Programming Glossary: shootable
Java - array of different objects that have the same method(s) http://stackoverflow.com/questions/12684528/java-array-of-different-objects-that-have-the-same-methods powerful and easy to use. You could call your interface Shootable . You can create an array of different objects that implement.. can create an array of different objects that implement Shootable and treat them all the same. Define a VERY simple interface.. Define a VERY simple interface with one method. interface Shootable public void beingShot Any class that implements this interface..
|