implement JArray.swapItems function. close #20