So I have a class in which I defined this method (append). 

You of course use your own template. 

Here's my code with the relevant part missing: 

-bash-4.1$ cat Utilities.java
import java.util.*;

public class Utilities
{
   public static void main(String[] args)
   {
      int[] a = new int[] { 0, 1, 2, 3 };
      ArrayList<Integer> b = new ArrayList<Integer>();
      for(int intValue : a) {
         b.add(intValue);
      }

      int[] c = new int[] { 4, 5, 6, 7, 8 };
      ArrayList<Integer> d = new ArrayList<Integer>();
      for(int intValue : c) {
         d.add(intValue);
      }

      ArrayList<Integer> e = Utilities.append( b, d );
      System.out.println( e );
   }

   public static ArrayList<Integer> append(ArrayList<Integer> a, ArrayList<Integer> b)
   {
      // my code comes here (yours should be the same, in your template) 
   }
}

Then when I run it it goes like this: 

-bash-4.1$ pico -w Utilities.java
-bash-4.1$ javac Utilities.java
-bash-4.1$ java Utilities
[0, 1, 2, 3, 4, 5, 6, 7, 8]
-bash-4.1$

--