Refactor MeshMS Java API