You can't really swap the tiles, but you can "Simulate" that you swapped the tiles.
First, you'd mainly use the function doRelocate(fromPos, toPos). But, there is a problem with this.
If you Relocate Tile 1, to Tile 2, then EVERYTHING is on Tile 2, So you'd have to have what I call a "Utility...