Oop L9
Oop L9
Programming
BITS Pilani
CS F213
Dubai Campus
Contents
• Processing Array
• Example
• Array of objects
• Example
• Passing array to method
• Example
• Returning array from method
• Example
• Class objects for arrays
• Example
Sources:
• Copying a java array 1. Chapter 1, Cay Horstmann, Object Oriented Design & Patterns, John Wiley & Sons, 2006, 2nd Edition
2. Chapter 3, 13, Herbert Schildt, The complete Reference Java 2, 5th Edition, Tata McGraw Hill.
3. https://www.geeksforgeeks.org/arrays-in-java/
4. https://www.javatpoint.com/array-in-java
• Example 5. https://docs.oracle.com/javase/tutorial/java/nutsandbolts/arrays.html
6. https://www.tutorialspoint.com/java/java_arrays.htm
• The string “[I” is the run-time type signature for the class object “array
with component type int“.
• The only direct superclass of any array type is java.lang.Object.
• The string “[B” is the run-time type signature for the class object “array
with component type byte“.
• The string “[S” is the run-time type signature for the class object “array
with component type short“.
• The string “[L” is the run-time type signature for the class object “array
with component type of a Class”. The Class name is then followed.
Thank You!