title: How to add methods to manipulate an array of class objects?
body: <p>I didnt know how to word the question, so sorry if it doesnt really make sense, but it should start making sense here. Also, I am sorry if the solution is really, really simple. Google couldnt understand what I was asking (probs cause I was asking it wrong :P)</p>
  
  <p>So I wrote a class that I called <code>OrderSelection</code></p>
  
  <p>In my program I need to have an array of OrderSelection objects, and I need to perform actions on this array (re-ordering, sorting etc).</p>
  
  <p>What I am doing right now is keeping methods in the OrderSelection class that accept, among others, the array which you want to re-order, for example.</p>
  
  <p>something like: </p>
  
  <pre><code>public void reorder(OrderSelection[] ord, int switchX, int switchY){....}
  </code></pre>
  
  <p>But What I want to be able to do is this:</p>
  
  <pre><code>OrderSelection[] order = new OrderSelection[10];
  //do stuff
  order.reorder(1,2);//which is WAY better than order[0].reorder(order, 1,2) as a horrid example
  </code></pre>
  
  <p>So yeah...how can I add these functions which I want to apply to an array of objects of my class?</p>
  
  <p>thanks!</p>