The swords will do fine in a pot, but the java ferns shouldn't have their roots planted. They should be tied to a rock or piece of driftwood, something like that, so that they can attach to it.
For the swords, you can push a root tab fertilizer down into the pot.
I hope this helps and please feel free to ask questions