Converts this MultiRegion to a String which can be converted back to a MultiRegion using MultiRegion#fromString(String) Please use this to persist MultiRegions, as most of the operations for manipulating a MultiRegion are far more expensive than the same operations would be for a Region. If
()
| 723 | * @return The String representation of this MultiRegion |
| 724 | */ |
| 725 | @Override |
| 726 | public String toString() { |
| 727 | StringBuilder builder = new StringBuilder(getWorld().getName()).append(" "); |
| 728 | for (Region region : regions) { |
| 729 | String str = region.toString(); |
| 730 | str = str.substring(str.indexOf(' ') + 1); |
| 731 | builder.append(str).append(","); |
| 732 | } |
| 733 | return builder.substring(0, builder.length() - 1); |
| 734 | } |
| 735 | |
| 736 | /** |
| 737 | * Turns a String generated by {@link MultiRegion#toString()} back into a MultiRegion |