java moss is pretty tough, ive had driftwood out of my tanks for a couple days, as long as it stay somewhat moist. It can actually live out of water if the humidity level is high enough.
Ya the java moss can survive as long as it stays moist. People use it with dart frog and have it grow as a carpet to cover the bottom of the vivarium and even grow up backgrounds and drift wood. I used it in an old crested gecko setup I had.